[open-ils-commits] r16335 - in trunk/Open-ILS/web/js/dojo/openils/acq: . nls (erickson)

svn at svn.open-ils.org svn at svn.open-ils.org
Wed Apr 28 11:39:53 EDT 2010


Author: erickson
Date: 2010-04-28 11:39:50 -0400 (Wed, 28 Apr 2010)
New Revision: 16335

Modified:
   trunk/Open-ILS/web/js/dojo/openils/acq/Lineitem.js
   trunk/Open-ILS/web/js/dojo/openils/acq/nls/acq.js
Log:
when a LI points to a PO, show the LI as a link in the lineitem summary blob

Modified: trunk/Open-ILS/web/js/dojo/openils/acq/Lineitem.js
===================================================================
--- trunk/Open-ILS/web/js/dojo/openils/acq/Lineitem.js	2010-04-28 15:31:46 UTC (rev 16334)
+++ trunk/Open-ILS/web/js/dojo/openils/acq/Lineitem.js	2010-04-28 15:39:50 UTC (rev 16335)
@@ -140,9 +140,12 @@
                 );
 
                 var po = lineitem.purchase_order();
-                var li = lineitem.picklist();
+                var pl = lineitem.picklist();
                 var orderDate = '';
+                var liLink = '';
+
                 if(po) {
+                    liLink = oilsBasePath + '/acq/po/view/' + po.id() + '/' + lineitem.id();
                     var date = dojo.date.stamp.fromISOString(po.order_date());
                     if(date) {
                         orderDate = dojo.date.locale.format(date, {selector:'date'});
@@ -165,11 +168,12 @@
                         oilsBasePath,
                         (po) ? po.id() : '',
                         (po) ? po.name() : '',
-                        (li) ? li.id() : '',
-                        (li) ? li.name() : '',
+                        (pl) ? pl.id() : '',
+                        (pl) ? pl.name() : '',
                         lineitem.order_summary().encumbrance_amount() || '0.00',
                         lineitem.order_summary().paid_amount() || '0.00',
-                        orderDate
+                        orderDate,
+                        liLink
                     ]
                 );
 

Modified: trunk/Open-ILS/web/js/dojo/openils/acq/nls/acq.js
===================================================================
--- trunk/Open-ILS/web/js/dojo/openils/acq/nls/acq.js	2010-04-28 15:31:46 UTC (rev 16334)
+++ trunk/Open-ILS/web/js/dojo/openils/acq/nls/acq.js	2010-04-28 15:39:50 UTC (rev 16335)
@@ -59,7 +59,7 @@
     'INVOICE_ITEM_DETAILS' : "${0} <br/> ${1} <br/> ${2}. <br/> Estimated Price: $${3}. <br/> Lineitem ID: ${4} <br/> PO: ${5} <br/> Order Date: ${6}",
     'INVOICE_CONFIRM_ITEM_DELETE' : "Remove this $${0} '${1}' charge from the invoice?",
     'INVOICE_CONFIRM_ENTRY_DETACH' : "Remove $${0} charge for item '${1}, ${2} [${3}] from the invoice?",
-    'LINEITEM_SUMMARY' : "<div class='acq-lineitem-summary'>${0}, by ${1} (${2})</div>" +
+    'LINEITEM_SUMMARY' : "<div class='acq-lineitem-summary'><a href='${19}'>${0}</a>, by ${1} (${2})</div>" +
         "<div class='acq-lineitem-summary-extra'>" +
             "${3} Ordered, ${4} Received, ${7} Invoiced, ${8} Claimed, ${9} Cancelled</div>" +
         "<div class='acq-lineitem-summary-extra'>Estimated $${6}, Encumbered $${16}, Paid $${17}</div>" +



More information about the open-ils-commits mailing list