ISBN Picker enhancements to show picked and add "Apply All" (cherry picked from commi...
authorBill Erickson <berickxx@gmail.com>
Wed, 29 Oct 2014 21:09:03 +0000 (17:09 -0400)
committerBill Erickson <berickxx@gmail.com>
Thu, 21 Mar 2019 19:46:23 +0000 (15:46 -0400)
    Cross-port: b19ece3

KCLS/openils/var/templates_kcls/acq/common/li_table.tt2
Open-ILS/web/js/ui/kcls/acq/common/li_table.js

index 3e213f6..ea6f1ce 100644 (file)
                     <td><span><a id='acq-lit-select-toggle' href='javascript:void(0);'>&#x2713</a></span></td>
                     <td>
                         [% l('Line Items') %]
+                                                <span style='padding-left: 10px;'>
+                            <a href='javascript:;' 
+                                id='acq-lit-apply-idents'>
+                                [% l('Apply ISBN Picker to All Items') %]
+                            </a>
+                        </span>
                     </td>
                     <td style='white-space:nowrap;'>
                         <a id='acq-inline-copies-toggle' 
                                                 </select>
                                             </td>
                                             <td name='order_ident_value'></td>
+                                                                                       <td name="order_ident_picked">Picked:  </td>
                                         </tr></table>
                                     </td>
                                 </tr>
index e795a68..28acf89 100644 (file)
@@ -639,7 +639,7 @@ function AcqLiTable() {
                 "src", "/opac/extras/ac/jacket/small/" + identifier
             );
         }
-
+        
         nodeByName("liid", row).innerHTML += li.id();
 
         if(li.eg_bib_id()) {
@@ -929,8 +929,10 @@ function AcqLiTable() {
         );
 
         var identAttr = this.getLiOrderIdent(li);
-
-
+        
+               
+                       
+                
         // collect the values for each type of identifier
         // find a reasonable default identifier type to render
         
@@ -1003,8 +1005,14 @@ function AcqLiTable() {
 
             // set the value for the cbox
             if (values[name].length) {
-                var orderIdent = self.getLiOrderIdent(li);
-
+                  var orderIdent = self.getLiOrderIdent(li);
+                if (orderIdent && orderIdent.attr_name() == name) {
+                var link = nodeByName('order_ident_picked', row);
+                link.innerHTML += orderIdent.attr_value();
+                } else {
+                var link = nodeByName('order_ident_picked', row);
+                link.innerHTML += "None";
+                }
                 if (orderIdent && orderIdent.attr_name() == name) {
                     cbox.attr('value', orderIdent.attr_value());
                 } else  {