Fixed issue 29133: Avoid JS error in 'Add Details' process
authorDavid Baz Fayos <david.baz@openbravo.com>
Wed, 04 Mar 2015 18:51:22 +0100
changeset 26125 86a6b64eb747
parent 26124 268b0e438f83
child 26126 e9d73be9949d
Fixed issue 29133: Avoid JS error in 'Add Details' process
while moving between fields in new record in 'G/L Items' grid
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-pick-and-execute-grid.js
--- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-pick-and-execute-grid.js	Wed Mar 04 18:22:34 2015 +0100
+++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-pick-and-execute-grid.js	Wed Mar 04 18:51:22 2015 +0100
@@ -375,7 +375,7 @@
     if (newValue === null || newValue === undefined) {
       newValue = this.getEditValue(rowNum, colNum);
     }
-    if (newValue === null || newValue === undefined) {
+    if ((newValue === null || newValue === undefined) && this.getRecord(rowNum)) {
       newValue = this.getRecord(rowNum)[editField.name];
     }
     // Execute onChangeFunctions if they exist