blank for barcode not allowed
authorpines <pines@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 14 Sep 2006 19:44:23 +0000 (19:44 +0000)
committerpines <pines@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 14 Sep 2006 19:44:23 +0000 (19:44 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@6108 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/xul/staff_client/server/cat/util.js

index 2901bf6..3241683 100644 (file)
@@ -27,6 +27,10 @@ cat.util.replace_barcode = function(old_bc) {
                if (!copy) throw(copy);
 
                var new_bc = window.prompt('Enter the replacement barcode for the copy with barcode ' + old_bc + ':','','Replace Barcode');
+               if (!new_bc) {
+                       alert('Rename aborted.  Blank for barcode not allowed.');
+                       return;
+               }
 
                var test = network.simple_request('FM_ACP_RETRIEVE_VIA_BARCODE',[ ses(), new_bc ]);
                if (typeof test.ilsevent == 'undefined') {