From 47ccf0191e1517fceaa84a1499e6780e499ff97b Mon Sep 17 00:00:00 2001 From: Christopher Brannon Date: Sat, 29 Sep 2018 18:09:03 +0000 Subject: [PATCH] Bug 21446: Correct perm location and enhance TO TEST: 1) Set ReturnToShelvingCart on. 2) Create a Course Reserve and make inactive. 3) Add an item, changing Item type, Collection code, Shelving location, and Holding library. 4) Note these four fields in the item list. 5) Activate course reserve. 6) Note subtle/no difference in these fiels in the list. 7) Check in the item. 8) Go back to course reserves and note that the cart is listed in the field instead of permanent location. 9) Deactivate course reserve. 10) Reset permanent location on item manually. 11) Apply patch. 12) Repeat steps 4-9 noting that the permanent location is showing instead of current location. Also, if a change is assigned to the item, the change AND the regular state always show. The active state will be in bold. --- .../en/modules/course_reserves/course-details.tt | 41 +++++++++++++++++----- 1 file changed, 33 insertions(+), 8 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-details.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-details.tt index f43eb90..5350c37 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-details.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-details.tt @@ -86,9 +86,15 @@ [% IF cr.course_item.itype %] [% IF cr.course_item.enabled == 'yes' %] - [% ItemTypes.GetDescription( cr.item.itype ) | html %] + [% ItemTypes.GetDescription( cr.item.itype) | html %] + [% IF cr.item.itype %] + ([% ItemTypes.GetDescription( cr.course_item.itype ) | html %]) + [% END %] [% ELSE %] [% ItemTypes.GetDescription( cr.course_item.itype ) | html %] + [% IF cr.item.itype %] + ([% ItemTypes.GetDescription( cr.item.itype) | html %] + [% END %] [% END %] [% ELSE %] Unchanged @@ -101,9 +107,15 @@ [% IF cr.course_item.ccode %] [% IF cr.course_item.enabled == 'yes' %] - [% AuthorisedValues.GetByCode( 'CCODE', cr.item.ccode ) | html %] + [% AuthorisedValues.GetByCode( 'CCODE', cr.item.ccode ) | html %] + [% IF cr.item.ccode %] + ([% AuthorisedValues.GetByCode( 'CCODE', cr.course_item.ccode ) | html %]) + [% END %] [% ELSE %] - [% AuthorisedValues.GetByCode( 'CCODE', cr.course_item.ccode ) | html %] + [% AuthorisedValues.GetByCode( 'CCODE', cr.course_item.ccode ) | html %] + [% IF cr.item.ccode %] + ([% AuthorisedValues.GetByCode( 'CCODE', cr.item.ccode ) | html %]) + [% END %] [% END %] [% ELSE %] Unchanged @@ -114,24 +126,36 @@ [% IF cr.course_item.location %] - [% IF cr.course_item.enabled == 'yes' %] - [% AuthorisedValues.GetByCode( 'LOC', cr.item.location ) | html %] + [% IF cr.course_item.enabled == 'yes' %] + [% AuthorisedValues.GetByCode( 'LOC', cr.item.permanent_location ) | html %] + [% IF cr.item.permanent_location %] + ([% AuthorisedValues.GetByCode( 'LOC', cr.course_item.location ) | html %]) + [% END %] [% ELSE %] [% AuthorisedValues.GetByCode( 'LOC', cr.course_item.location ) | html %] + [% IF cr.item.permanent_location %] + ([% AuthorisedValues.GetByCode( 'LOC', cr.item.permanent_location ) | html %]) + [% END %] [% END %] [% ELSE %] Unchanged - [% IF cr.item.location %] - ([% AuthorisedValues.GetByCode( 'LOC', cr.item.location ) | html %]) + [% IF cr.item.permanent_location %] + ([% AuthorisedValues.GetByCode( 'LOC', cr.item.permanent_location ) | html %]) [% END %] [% END %] [% IF cr.course_item.holdingbranch %] [% IF cr.course_item.enabled == 'yes' %] - [% Branches.GetName( cr.item.holdingbranch ) | html %] + [% Branches.GetName( cr.item.holdingbranch ) | html %] + [% IF cr.item.holdingbranch %] + ([% Branches.GetName( cr.course_item.holdingbranch ) | html %]) + [% END %] [% ELSE %] [% Branches.GetName( cr.course_item.holdingbranch ) | html %] + [% IF cr.item.holdingbranch %] + ([% Branches.GetName( cr.item.holdingbranch ) | html %]) + [% END %] [% END %] [% ELSE %] Unchanged @@ -140,6 +164,7 @@ [% END %] [% END %] + [% IF (cr.staff_note) %] [% cr.staff_note | html %] [% ELSIF (cr.item.itemnotes_nonpublic) %] -- 2.1.4