@@ -, +, @@ like damaged and lost --- catalogue/detail.pl | 4 ++++ koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt | 10 +++++++++- koha-tmpl/opac-tmpl/bootstrap/en/includes/item-status.inc | 7 ++++++- 3 files changed, 19 insertions(+), 2 deletions(-) --- a/catalogue/detail.pl +++ a/catalogue/detail.pl @@ -211,6 +211,10 @@ $mss = Koha::MarcSubfieldStructures->search({ frameworkcode => $fw, kohafield => if ( $mss->count ) { $template->param( itemdamagedloop => GetAuthorisedValues( $mss->next->authorised_value ) ); } +$mss = Koha::MarcSubfieldStructures->search({ frameworkcode => $fw, kohafield => 'items.withdrawn', authorised_value => { not => undef } }); +if ( $mss->count ) { + $template->param( itemwithdrawnloop => GetAuthorisedValues( $mss->next->authorised_value) ); +} $mss = Koha::MarcSubfieldStructures->search({ frameworkcode => $fw, kohafield => 'items.materials', authorised_value => { not => undef } }); my %materials_map; --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt @@ -406,7 +406,15 @@ [% END %] [% IF ( item.withdrawn ) %] - Withdrawn + [% IF itemwithdrawnloop %] + [% FOREACH itemwithdrawnloo IN itemwithdrawnloop %] + [% IF itemwithdrawnloo.authorised_value == item.withdrawn %] + [% itemwithdrawnloo.lib %] + [% END %] + [% END %] + [% ELSE %] + Withdrawn + [% END %] [% END %] [% IF ( item.damaged ) %] --- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/item-status.inc +++ a/koha-tmpl/opac-tmpl/bootstrap/en/includes/item-status.inc @@ -53,7 +53,12 @@ [% IF ( item.withdrawn ) %] [% SET itemavailable = 0 %] - Item withdrawn + [% av_lib_include = AuthorisedValues.GetByCode( 'WITHDRAWN', item.withdrawn, 1 ) %] + [% IF av_lib_include %] + [% av_lib_include %] + [% ELSE %] + Item withdrawn + [% END %] [% END %] --