missed database update script
authorgmc <gmc@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 5 Nov 2010 17:50:28 +0000 (17:50 +0000)
committergmc <gmc@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 5 Nov 2010 17:50:28 +0000 (17:50 +0000)
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
git-svn-id: svn://svn.open-ils.org/ILS/trunk@18633 dcc99617-32d9-48b4-a31d-7c20da2025e4

13 files changed:
Open-ILS/src/sql/Pg/950.data.seed-values.sql
Open-ILS/src/sql/Pg/upgrade/0459.schema.password-reset-request-time.sql [new file with mode: 0644]
Open-ILS/web/js/dojo/openils/acq/Lineitem.js
Open-ILS/web/js/dojo/openils/acq/Picklist.js
Open-ILS/web/js/ui/default/acq/common/li_table.js
Open-ILS/web/js/ui/default/acq/invoice/view.js
Open-ILS/web/js/ui/default/acq/lineitem/related.js
Open-ILS/web/js/ui/default/acq/picklist/brief_record.js
Open-ILS/web/js/ui/default/acq/picklist/user_request.js
Open-ILS/web/js/ui/default/acq/picklist/view.js
Open-ILS/web/js/ui/default/acq/picklist/view_list.js
Open-ILS/web/js/ui/default/acq/search/picklist.js
Open-ILS/xul/staff_client/server/circ/util.js

index f6d4090..39abb01 100644 (file)
@@ -4963,9 +4963,15 @@ $$[%- USE date -%]
   # BT      - vendcode goes to NAD/BY *suffix*  w/ 91 qualifier
   # INGRAM  - vendcode goes to NAD/BY *segment* w/ 91 qualifier (separately)
   # BRODART - vendcode goes to FTX segment (lineitem level)
+  # In the logic below, vendors are identified by their SANs, as that
+  # is the identifier most likely to be the same from library to library.
+  # Baker & Taylor = 1556150
+  # Brodart        = 1697684
+  # Ingram         = 1697978
+  # Midwest Tapes  = 2549913
 -%]
 [%- 
-IF target.provider.edi_default.vendcode && target.provider.code == 'BRODART';
+IF target.provider.edi_default.vendcode && target.provider.san == '1697684';
     xtra_ftx = target.provider.edi_default.vendcode;
 END;
 -%]
@@ -4978,9 +4984,9 @@ END;
         "po_number":[% target.id %],
         "date":"[% date.format(date.now, '%Y%m%d') %]",
         "buyer":[
-            [%   IF   target.provider.edi_default.vendcode && (target.provider.code == 'BT' || target.provider.name.match('(?i)^BAKER & TAYLOR'))  -%]
+            [%   IF   target.provider.edi_default.vendcode && (target.provider.san == '1556150')  -%]
                 {"id-qualifier": 91, "id":"[% target.ordering_agency.mailing_address.san _ ' ' _ target.provider.edi_default.vendcode %]"}
-            [%- ELSIF target.provider.edi_default.vendcode && target.provider.code == 'INGRAM' -%]
+            [%- ELSIF target.provider.edi_default.vendcode && target.provider.san == '1697978' -%]
                 {"id":"[% target.ordering_agency.mailing_address.san %]"},
                 {"id-qualifier": 91, "id":"[% target.provider.edi_default.vendcode %]"}
             [%- ELSE -%]
@@ -5006,6 +5012,9 @@ END;
                 {"id-qualifier":"IB","id":"[% isbn %]"},
                 [%- END %]
             [% END %]
+            [% IF helpers.get_li_attr('upc', '', li.attributes) %]
+                {"id-qualifier":"UP","id":"[% helpers.get_li_attr('upc', '', li.attributes) %]"}
+            [% END %]
                 {"id-qualifier":"IN","id":"[% li.id %]"}
             ],
             "price":[% li.estimated_unit_price || '0.00' %],
diff --git a/Open-ILS/src/sql/Pg/upgrade/0459.schema.password-reset-request-time.sql b/Open-ILS/src/sql/Pg/upgrade/0459.schema.password-reset-request-time.sql
new file mode 100644 (file)
index 0000000..fef1ad2
--- /dev/null
@@ -0,0 +1,7 @@
+BEGIN;
+
+INSERT INTO config.upgrade_log (version) VALUES ('0459'); -- gmc
+
+ALTER TABLE actor.usr_password_reset ALTER COLUMN request_time TYPE TIMESTAMP WITH TIME ZONE;
+
+COMMIT;
index 27ed9e3..7c08653 100644 (file)
@@ -119,7 +119,7 @@ openils.acq.Lineitem.fetchAndRender = function(liId, args, callback) {
     });
 
     fieldmapper.standardRequest(
-        ['open-ils.acq', 'open-ils.acq.lineitem.retrieve'],
+        ['open-ils.acq', 'open-ils.acq.lineitem.retrieve.authoritative'],
         {
             params : [ openils.User.authtoken, liId, args ],
 
index 504b969..d80eeb5 100644 (file)
@@ -57,7 +57,7 @@ dojo.declare('openils.acq.Picklist', null, {
         //
         // Fetch the picklist information
         fieldmapper.standardRequest(
-            ['open-ils.acq', 'open-ils.acq.picklist.retrieve'],
+            ['open-ils.acq', 'open-ils.acq.picklist.retrieve.authoritative'],
             {   async: false,
                 params: [openils.User.authtoken, pl_id, {flesh_lineitem_count:1}],
                 oncomplete: function(r) {
index d12d09f..dc8e56a 100644 (file)
@@ -323,7 +323,7 @@ function AcqLiTable() {
                 this.plCache[li.picklist()] = 
                 this.plCache[li.picklist()] || 
                 fieldmapper.standardRequest(
-                    ['open-ils.acq', 'open-ils.acq.picklist.retrieve'],
+                    ['open-ils.acq', 'open-ils.acq.picklist.retrieve.authoritative'],
                     {params: [this.authtoken, li.picklist()]});
             if (pl) {
                 if (pl.name() == "") {
index 102294e..281189f 100644 (file)
@@ -52,7 +52,7 @@ function init() {
 
     } else {
         fieldmapper.standardRequest(
-            ['open-ils.acq', 'open-ils.acq.invoice.retrieve'],
+            ['open-ils.acq', 'open-ils.acq.invoice.retrieve.authoritative'],
             {
                 params : [openils.User.authtoken, invoiceId],
                 oncomplete : function(r) {
index e06a716..e90874d 100644 (file)
@@ -14,7 +14,7 @@ var paramPO;
 
 function fetchLi() {
     fieldmapper.standardRequest(
-        ["open-ils.acq", "open-ils.acq.lineitem.retrieve"], {
+        ["open-ils.acq", "open-ils.acq.lineitem.retrieve.authoritative"], {
             "async": true,
             "params": [openils.User.authtoken, targetId, {
                 "flesh_attrs": true,
index 17be135..9653aa5 100644 (file)
@@ -30,7 +30,7 @@ function drawBriefRecordForm(fields) {
         openils.Util.hide('acq-brief-record-po-row');
 
         fieldmapper.standardRequest(
-            ['open-ils.acq', 'open-ils.acq.picklist.retrieve'],
+            ['open-ils.acq', 'open-ils.acq.picklist.retrieve.authoritative'],
             {   async: true,
                 params: [openils.User.authtoken, paramPL], 
                 oncomplete : function(r) {
index 392273b..cf75f52 100644 (file)
@@ -90,7 +90,7 @@ function fooPicklist() {
 
 function viewPicklist() {
     var lineitem = fieldmapper.standardRequest(
-        [ 'open-ils.acq', 'open-ils.acq.lineitem.retrieve' ],
+        [ 'open-ils.acq', 'open-ils.acq.lineitem.retrieve.authoritative' ],
         {
             params: [openils.User.authtoken, aur_obj.lineitem()]
         }
index cfd6cb9..7cbc0c5 100644 (file)
@@ -14,7 +14,7 @@ function load() {
     liTable = new AcqLiTable();
     liTable.isPL = plId;
     fieldmapper.standardRequest(
-        ['open-ils.acq', 'open-ils.acq.picklist.retrieve'],
+        ['open-ils.acq', 'open-ils.acq.picklist.retrieve.authoritative'],
         {   async: true,
             params: [openils.User.authtoken, plId, 
                 {flesh_lineitem_count:true, flesh_owner:true}],
index fb245a8..17b2e92 100644 (file)
@@ -68,7 +68,7 @@ function createPL(fields) {
         function(plId) {
             fieldmapper.standardRequest(
 
-                ['open-ils.acq', 'open-ils.acq.picklist.retrieve'],
+                ['open-ils.acq', 'open-ils.acq.picklist.retrieve.authoritative'],
                 {   async: true,
                     params: [openils.User.authtoken, plId,
                         {flesh_lineitem_count:1, flesh_owner:1}],
index b21bc37..61da13f 100644 (file)
@@ -165,7 +165,7 @@ function createPl(fields) {
     openils.acq.Picklist.create(fields,
         function(plId) {
             fieldmapper.standardRequest(
-                ["open-ils.acq", "open-ils.acq.picklist.retrieve"], {
+                ["open-ils.acq", "open-ils.acq.picklist.retrieve.authoritative"], {
                     "async": true,
                     "params": [
                         openils.User.authtoken, plId,
index 8cd554a..2405182 100644 (file)
@@ -3402,7 +3402,7 @@ circ.util.batch_hold_update = function ( hold_ids, field_changes, params ) {
 circ.util.find_acq_po = function(session, copy_id) {
     dojo.require("openils.Util");
     fieldmapper.standardRequest(
-        ["open-ils.acq", "open-ils.acq.lineitem.retrieve.by_copy_id"], {
+        ["open-ils.acq", "open-ils.acq.lineitem.retrieve.by_copy_id.authoritative"], {
             "params": [session, copy_id, {"clear_marc": true}],
             "onresponse": function(r) {
                 if (r = openils.Util.readResponse(r)) {