Related to issue 26722:On P&E system does not check the mandatory fields
authorGuillermo Gil <guillermo.gil@openbravo.com>
Mon, 02 Jun 2014 10:39:51 +0200
changeset 23521 4070edaaab75
parent 23520 36f45babccfc
child 23522 668f36bc5e77
Related to issue 26722:On P&E system does not check the mandatory fields

Fixes Q2 issue, fields were looking for null values but there were empty string values
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-parameter-window-view.js
--- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-parameter-window-view.js	Fri May 30 11:21:25 2014 +0200
+++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-parameter-window-view.js	Mon Jun 02 10:39:51 2014 +0200
@@ -69,7 +69,7 @@
           record = grid.getEditedRecord(grid.getRecordIndex(selection[i]));
           for (j = 0; j < fields.length; j++) {
             if (fields[j].required) {
-              if (record[fields[j].name] === null || record[fields[j] === undef]) {
+              if (record[fields[j].name] === null || record[fields[j].name] === "" || record[fields[j] === undef]) {
                 hasErrors = true;
                 if (lineNumbers === undef) {
                   lineNumbers = grid.getRecordIndex(selection[i]).toString();