LP1822836 Some print receipt fields for the renew receipt were not printing.
authorDan Pearl <dpearl@cwmars.org>
Tue, 2 Apr 2019 18:30:11 +0000 (14:30 -0400)
committerDan Pearl <dpearl@cwmars.org>
Fri, 17 May 2019 16:54:38 +0000 (12:54 -0400)
Open-ILS/src/templates/staff/share/print_templates/t_renew.tt2
Open-ILS/web/js/ui/default/staff/admin/workstation/app.js
Open-ILS/web/js/ui/default/staff/circ/renew/app.js

index 9d4510f..c7587e7 100644 (file)
@@ -2,10 +2,19 @@
 Template for printing a renewal receipt. Fields include:
 
 * circulations - list of renewals made during the session, including
+  for each renewal:
 
-  * title
-  * copy.barcode
-  * circ.due_date
+  * renewal.title
+  * renewal.author
+  * renewal.circ.due_date
+  * renewal.circ.renewal_remaining
+  * renewal.circ.circ_lib
+  * renewal.circ.duration
+  * renewal.copy.barcode
+  * renewal.copy.circ_modifier
+  * renewal.copy.call_number.label
+  * renewal.copy.call_number.owning_lib.name
+  * renewal.copy.call_number.owning_lib.shortname
 
 -->
 <div>
index 04684bc..37a815a 100644 (file)
@@ -436,16 +436,28 @@ function($scope , $q , egCore , ngToast) {
                 simple_record : {
                     'title' : 'Test Title'
                 }
+            },
+            owning_lib : {
+                name : 'Ankers Memorial Library',
+                shortname : 'Ankers'
             }
         },
+        circ_modifier : {
+          name : 'Book'
+                },
         location : {
             name : 'General Collection'
         },
+        status : {
+            name : 'In Transit'
+        },
         // flattened versions for item status template
         // TODO - make this go away
         'call_number.label' : '636.8 JON',
         'call_number.record.simple_record.title' : 'Test Title',
-        'location.name' : 'General Colleciton'
+        'location.name' : 'General Collection',
+        'call_number.owning_lib.name' : 'Ankers Memorial Library',
+        'call_number.owning_lib.shortname' : 'Ankers'
     }
 
     var one_hold = {
@@ -545,12 +557,13 @@ function($scope , $q , egCore , ngToast) {
                 circ : {
                     due_date : new Date().toISOString(),
                     circ_lib : 1,
-                    duration : '7 days'
+                    duration : '7 days',
+                    renewal_remaining : 2
                 },
                 copy : seed_copy,
                 title : seed_record.title,
                 author : seed_record.author
-            },
+            }
         ],
 
         patron_money : {
index 2c6ba63..dc75dbc 100644 (file)
@@ -234,6 +234,11 @@ function($scope , $window , $location , egCore , egGridDataProvider , egCirc) {
                     title : egCore.idl.toHash(renewal.title),
                     author : egCore.idl.toHash(renewal.author)
                 });
+                // Flesh selected fields of this circulation
+                print_data.circulations[0].copy.call_number =
+                   egCore.idl.toHash(renewal.acn);
+                print_data.circulations[0].copy.owning_lib = 
+                   egCore.idl.toHash(renewal.aou);
             }
         });