From: Josh Stompro Date: Fri, 16 Jul 2021 23:53:23 +0000 (-0500) Subject: LP#1642000 - Bootstrap Opac - Add CN Prefix, Suffix and Parts to opac checked out... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=96c72fc975e66494819960ee2ac83e3fffa4c077;p=Evergreen.git LP#1642000 - Bootstrap Opac - Add CN Prefix, Suffix and Parts to opac checked out item display Add Call Number Prefix, Call Number Suffix and Part to the call number column of checked out items display. Also sort based on the label_sortkey value of those fields. Signed-off-by: Josh Stompro Signed-off-by: Elaine Hardy Signed-off-by: Chris Sharp --- diff --git a/Open-ILS/src/templates-bootstrap/opac/myopac/circs.tt2 b/Open-ILS/src/templates-bootstrap/opac/myopac/circs.tt2 index a636cdabe5..2997c38807 100755 --- a/Open-ILS/src/templates-bootstrap/opac/myopac/circs.tt2 +++ b/Open-ILS/src/templates-bootstrap/opac/myopac/circs.tt2 @@ -91,8 +91,19 @@ circ.SORTING = circ.circ.target_copy.barcode; CASE "callnum"; - circ.SORTING = circ.circ.target_copy.call_number.label; - CASE "lib"; + sortlist = []; + + FOREACH element IN [circ.circ.target_copy.call_number.prefix.label_sortkey + circ.circ.target_copy.call_number.label_sortkey + circ.circ.target_copy.call_number.suffix.label_sortkey + circ.circ.target_copy.parts.0.label_sortkey]; + IF (element); + sortlist.push(element); + END; + END; + circ.SORTING = sortlist.join(""); + + CASE "lib"; circ.SORTING = circ.circ.target_copy.call_number.owning_lib.name; CASE; @@ -178,7 +189,21 @@ Call Number - [% circ.circ.target_copy.call_number.label | html %] + [%- + cnlist = []; + FOREACH element IN [circ.circ.target_copy.call_number.prefix.label + circ.circ.target_copy.call_number.label + circ.circ.target_copy.call_number.suffix.label]; + IF (element); + cnlist.push(element); + END; + END; + cn = cnlist.join(' '); + %] + [% cn | html %] + [%- IF circ.circ.target_copy.parts.0.label %] +
[% circ.circ.target_copy.parts.0.label | html -%] + [%- END %] [% IF ctx.get_org_setting(ctx.user.home_ou, 'opac.show_owning_lib_column'); %]