[open-ils-commits] r15241 - in trunk/Open-ILS/xul/staff_client: chrome/content/main server/locale/en-US server/patron (phasefx)
svn at svn.open-ils.org
svn at svn.open-ils.org
Tue Dec 29 12:30:52 EST 2009
Author: phasefx
Date: 2009-12-29 12:30:48 -0500 (Tue, 29 Dec 2009)
New Revision: 15241
Modified:
trunk/Open-ILS/xul/staff_client/chrome/content/main/constants.js
trunk/Open-ILS/xul/staff_client/server/locale/en-US/patron.properties
trunk/Open-ILS/xul/staff_client/server/patron/bills.js
Log:
display resource and resource type information for reservations in the original billing interface
Modified: trunk/Open-ILS/xul/staff_client/chrome/content/main/constants.js
===================================================================
--- trunk/Open-ILS/xul/staff_client/chrome/content/main/constants.js 2009-12-29 16:28:44 UTC (rev 15240)
+++ trunk/Open-ILS/xul/staff_client/chrome/content/main/constants.js 2009-12-29 17:30:48 UTC (rev 15241)
@@ -178,6 +178,9 @@
'FM_AUSP_PCRUD_UPDATE' : { 'app' : 'open-ils.pcrud', 'method' : 'open-ils.pcrud.update.ausp', 'secure' : false },
'FM_AUSP_UPDATE_NOTE' : { 'app' : 'open-ils.actor', 'method' : 'open-ils.actor.user.penalty.note.update' },
'FM_BOOKING_CREATE_BRT_AND_BRSRC' : { 'app' : 'open-ils.booking', 'method' : 'open-ils.booking.create_brt_and_brsrc_from_copies' },
+ 'FM_BRESV_RETRIEVE_VIA_PCRUD' : { 'app' : 'open-ils.pcrud', 'method' : 'open-ils.pcrud.search.bresv.atomic' },
+ 'FM_BRSRC_RETRIEVE_VIA_PCRUD' : { 'app' : 'open-ils.pcrud', 'method' : 'open-ils.pcrud.search.brsrc.atomic' },
+ 'FM_BRT_RETRIEVE_VIA_PCRUD' : { 'app' : 'open-ils.pcrud', 'method' : 'open-ils.pcrud.search.brt.atomic' },
'FM_BRE_RETRIEVE_VIA_ID' : { 'app' : 'open-ils.cat', 'method' : 'open-ils.cat.biblio.record.metadata.retrieve', 'secure' : false },
'FM_BRE_RETRIEVE_VIA_ID.authoritative' : { 'app' : 'open-ils.cat', 'method' : 'open-ils.cat.biblio.record.metadata.retrieve.authoritative', 'secure' : false },
'FM_BRE_ID_VIA_BARCODE' : { 'app' : 'open-ils.search', 'method' : 'open-ils.search.bib_id.by_barcode', 'secure' : false },
Modified: trunk/Open-ILS/xul/staff_client/server/locale/en-US/patron.properties
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/locale/en-US/patron.properties 2009-12-29 16:28:44 UTC (rev 15240)
+++ trunk/Open-ILS/xul/staff_client/server/locale/en-US/patron.properties 2009-12-29 17:30:48 UTC (rev 15241)
@@ -55,6 +55,9 @@
staff.patron.bills.pay.annotate_payment.title=Annotate Payment
staff.patron.bills.pay.refund_exceeds_desk_payment=%1$s\n\nAnother way to "zero" this transaction is to use Add Billing and add a miscellaneous bill to counter the negative balance.
staff.patron.bills.pay.payment_failed=Bill payment likely failed
+staff.patron.bills.info_box.label_value.reservation=Reservation
+# 1 - Resource Barcode 2 - Resource Type Name
+staff.patron.bills.info_box.value_format.reservation=%1$s : %2$s
staff.patron.bills.info_box.label_value.title=Title
staff.patron.bills.info_box.label_value.type=Type
staff.patron.bills.info_box.label_value.last_billing=Last Billing:
Modified: trunk/Open-ILS/xul/staff_client/server/patron/bills.js
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/patron/bills.js 2009-12-29 16:28:44 UTC (rev 15240)
+++ trunk/Open-ILS/xul/staff_client/server/patron/bills.js 2009-12-29 17:30:48 UTC (rev 15241)
@@ -905,6 +905,50 @@
}
);
break;
+ case 'reservation':
+ xt_label.setAttribute( 'value', $("patronStrings").getString('staff.patron.bills.info_box.label_value.reservation') );
+ obj.network.simple_request(
+ 'FM_BRESV_RETRIEVE_VIA_PCRUD',
+ [ ses(), { 'id' : { '=' : my.mobts.id() } } ],
+ function (req) {
+ try {
+ var reservation = req.getResultObject()[0];
+ if (typeof reservation.ilsevent != 'undefined') { return; }
+ obj.network.simple_request(
+ 'FM_BRSRC_RETRIEVE_VIA_PCRUD',
+ [ ses(), { 'id' : { '=' : reservation.target_resource() } } ],
+ function (rreq) {
+ try {
+ var resource = rreq.getResultObject()[0];
+ if (typeof resource.ilsevent != 'undefined') { return; }
+ obj.network.simple_request(
+ 'FM_BRT_RETRIEVE_VIA_PCRUD',
+ [ ses(), { 'id' : { '=' : resource.type() } } ],
+ function (rrreq) {
+ try {
+ var resource_type = rrreq.getResultObject()[0];
+ if (typeof resource_type.ilsevent != 'undefined') { return; }
+ xt_value.appendChild(
+ document.createTextNode(
+ $("patronStrings").getFormattedString('staff.patron.bills.info_box.value_format.reservation', [resource.barcode(), resource_type.name()])
+ )
+ );
+ } catch(E) {
+ alert(E);
+ }
+ }
+ );
+ } catch(E) {
+ alert(E);
+ }
+ }
+ );
+ } catch(E) {
+ alert(E);
+ }
+ }
+ );
+ break;
default:
xt_label.setAttribute( 'value',
my.mvr ? $("patronStrings").getString('staff.patron.bills.info_box.label_value.title') : $("patronStrings").getString('staff.patron.bills.info_box.label_value.type') );
More information about the open-ils-commits
mailing list