LP#1659006: Treat the Cost field like the other money fields in the copy editor,
authorMichele Morgan <mmorgan@noblenet.org>
Tue, 24 Jan 2017 14:17:58 +0000 (09:17 -0500)
committerKathy Lussier <klussier@masslnc.org>
Wed, 25 Jan 2017 16:09:46 +0000 (11:09 -0500)
reverting to null if blanked.

Signed-off-by: Kathy Lussier <klussier@masslnc.org>

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

index f4537a2..3d7a189 100644 (file)
@@ -567,7 +567,7 @@ g.apply = function(field,value) {
         value = null;
     }
     if (field == 'alert_message') { value = value.replace(/^\W+$/g,''); }
-    if (field == 'price' || field == 'deposit_amount') {
+    if (field == 'price' || field == 'deposit_amount' || field == 'cost'){
         if (value == '') {
             value = null;
         } else {