modify the copies
authorpines <pines@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 18 Jan 2006 19:36:42 +0000 (19:36 +0000)
committerpines <pines@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 18 Jan 2006 19:36:42 +0000 (19:36 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@2745 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/xul/staff_client/server/cat/copy_editor.xul

index 3ea6a8b..1efa42b 100644 (file)
 
                g.apply = function(field,value) {
                        dump('field = ' + field + '  value = ' + value + '\n');
+                       for (var i = 0; i < g.copies.length; i++) {
+                               var copy = g.copies[i];
+                               try {
+                                       var cmd = 'copy.' + field + '( ' + value + "); copy.ischanged('1');";
+                                       dump('copy.id() = ' + copy.id() + ' -> ' + cmd + '\n'); 
+                                       eval( cmd );
+                               } catch(E) {
+                                       alert(E);
+                               }
+                       }
                }
 
                g.special_exception = {
 
        <groupbox flex="1" style="overflow: auto">
                <caption id="caption" label="Copy Viewer"/>
-               <hbox id="nav" hidden="true"><spacer flex="1"/><button id="save" label="Modify these Copies"/></hbox>
+               <hbox id="nav" hidden="true">
+                       <spacer flex="1"/>
+                       <button id="save" label="Modify these Copies" 
+                               oncommand="alert('push these: ' + js2JSON(g.copies) );"/>
+               </hbox>
                <hbox flex="1">
                        <vbox style="overflow: scroll"> <!-- left pane -->
                                <groupbox id="gb_callnumbers">