The staff client search results table doesn't show actual authorized value descriptions for items with a lost, damaged, or withdrawn status. Instead it shows "Lost," "Damaged," or "Withdrawn" for any values of those statuses.
Created attachment 48385 [details] [review] Bug 15922 - Show authorized value description in staff client search results for lost, withdrawn, and damaged If an item in the staff client search results list is lost, withdrawn, or damaged, the actual authorized value description for each of those statuses should be displayed rather than the generic term. This patch adds use of the AuthorisedValues template plugin to output the correct description. To test, apply the patch and perform a catalog search in the staff client which will return results with various values for lost, damaged, and withdrawn. Confirm that the correct lost, damaged, or withdrawn status appears for each item rather than the generic term.
Created attachment 48402 [details] [review] Bug 15922 - Show authorized value description in staff client search results for lost, withdrawn, and damaged If an item in the staff client search results list is lost, withdrawn, or damaged, the actual authorized value description for each of those statuses should be displayed rather than the generic term. This patch adds use of the AuthorisedValues template plugin to output the correct description. To test, apply the patch and perform a catalog search in the staff client which will return results with various values for lost, damaged, and withdrawn. Confirm that the correct lost, damaged, or withdrawn status appears for each item rather than the generic term. Followed test plan, statuses appear as expected. Signed-off-by: Marc Véron <veron@veron.ch>
I am not sure about this patch: There are some other places where the string is hardcoded, at least: catalogue/moredetail.tt 77 [% IF ( ITEM_DAT.itemlost ) %]Lost[% END %] 78 [% IF ( ITEM_DAT.damaged ) %]Damaged[% END %] 79 [% IF ( ITEM_DAT.withdrawn ) %]Withdrawn[% END %] catalogue/detail.tt 662 [% IF ( item.withdrawn ) %] 663 <span class="wdn">Withdrawn</span> 664 [% END %] And using the AV, the string is no longer translatable.
(In reply to Jonathan Druart from comment #3) > There are some other places where the string is hardcoded, at least: Those sound like issues which could be addressed in other bug reports. > And using the AV, the string is no longer translatable. True, but isn't that what we live with every time we use an authorized value?
(In reply to Owen Leonard from comment #4) > (In reply to Jonathan Druart from comment #3) > > > There are some other places where the string is hardcoded, at least: > > Those sound like issues which could be addressed in other bug reports. I personally think we should fix all of them at the same time. > > And using the AV, the string is no longer translatable. > > True, but isn't that what we live with every time we use an authorized value? Yes, but for these 3 ones I am pretty sure everybody keeps the default value.
(In reply to Jonathan Druart from comment #5) > I personally think we should fix all of them at the same time. I'd be happy to submit a follow-up for moredetail.tt and detail.tt. > Yes, but for these 3 ones I am pretty sure everybody keeps the default value. This bug exists because we use more than just the default value for lost, and damaged and we want to see those locally-defined values. Bug 11280 shows that there was a need for withdrawn to be the same. > catalogue/detail.tt > 662 [% IF ( item.withdrawn ) %] > 663 <span class="wdn">Withdrawn</span> > 664 [% END %] catalogue/detail.tt already shows the authorized value description for lost and damaged. That it doesn't do so for withdrawn is a bug which should have been fixed by Bug 11280.
*** Bug 14235 has been marked as a duplicate of this bug. ***
We have a library asking for the exact status in the result lists as well - is there a way to get this moving again?
I'm happy to pick this up again if there are no objections to my initial approach.
In my opinion dealing with the other pages in separate bugs sounds ok, but we should file them now so the missing behaviour is better documented. As we got libraries differentiating between lost and missing and sometimes using the different status for 'odd' things they need, I can't say they are always left unchanged :)
(In reply to Owen Leonard from comment #6) > (In reply to Jonathan Druart from comment #5) > > I personally think we should fix all of them at the same time. > > I'd be happy to submit a follow-up for moredetail.tt and detail.tt. > > > Yes, but for these 3 ones I am pretty sure everybody keeps the default value. > > This bug exists because we use more than just the default value for lost, > and damaged and we want to see those locally-defined values. Bug 11280 shows > that there was a need for withdrawn to be the same. > > > catalogue/detail.tt > > 662 [% IF ( item.withdrawn ) %] > > 663 <span class="wdn">Withdrawn</span> > > 664 [% END %] > > catalogue/detail.tt already shows the authorized value description for lost > and damaged. That it doesn't do so for withdrawn is a bug which should have > been fixed by Bug 11280. I propose Bug 20341 for that. The idea is to just implement for withdrawn the same behavior as lost and damaged.
Fridolin, what's missing here?
(In reply to Katrin Fischer from comment #12) > Fridolin, what's missing here? I'm OK with it. Jonathan has set in discussion, depends on him.
Sending to QA
Created attachment 74616 [details] [review] Bug 15922 - Show authorized value description in staff client search results for lost, withdrawn, and damaged If an item in the staff client search results list is lost, withdrawn, or damaged, the actual authorized value description for each of those statuses should be displayed rather than the generic term. This patch adds use of the AuthorisedValues template plugin to output the correct description. To test, apply the patch and perform a catalog search in the staff client which will return results with various values for lost, damaged, and withdrawn. Confirm that the correct lost, damaged, or withdrawn status appears for each item rather than the generic term. Followed test plan, statuses appear as expected. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Created attachment 74617 [details] [review] Bug 15922: Show authorized value description in staff client search results for lost, withdrawn, and damaged If an item in the staff client search results list is lost, withdrawn, or damaged, the actual authorized value description for each of those statuses should be displayed rather than the generic term. This patch adds use of the AuthorisedValues template plugin to output the correct description. To test, apply the patch and perform a catalog search in the staff client which will return results with various values for lost, damaged, and withdrawn. Confirm that the correct lost, damaged, or withdrawn status appears for each item rather than the generic term. Followed test plan, statuses appear as expected. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Pushed to master for 18.05, thanks to everybody involved!