Related to issue 20278: Reverted previous changeset since it has been already fixed
authorDavid Baz Fayos <david.baz@openbravo.com>
Mon, 30 Apr 2012 14:51:50 +0200
changeset 16353 3c048f3d7822
parent 16352 9ec680a713db
child 16354 67e1b330d065
Related to issue 20278: Reverted previous changeset since it has been already fixed
with the 2012-04-29 Smartclient 8.3d upgrade
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-datetime.js
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/ob-view-form.js
--- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-datetime.js	Sun Apr 29 14:44:02 2012 +0200
+++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-datetime.js	Mon Apr 30 14:51:50 2012 +0200
@@ -133,19 +133,6 @@
     return value;
   },
 
-  // compare on seconds, ignoring less than
-  // 1 sec difference
-  // related to https://issues.openbravo.com/view.php?id=20278  
-  compareValues: function (a, b) {
-    if (a === b) {
-      return 0; // same date instance
-    }
-    var aval = (isc.isA.Date(a) ? a.getTime() : 0),
-        bval = (isc.isA.Date(b) ? b.getTime() : 0),
-        diff = aval - bval;
-    return diff > 1000 ? -1 : (diff < -1000 ? 1 : 0);
-  },
-
   parseValue: function () {
     return this.dateTextField.getElementValue();
   },
--- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/ob-view-form.js	Sun Apr 29 14:44:02 2012 +0200
+++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/ob-view-form.js	Mon Apr 30 14:51:50 2012 +0200
@@ -1492,10 +1492,6 @@
       form.isSaving = false;
       view.toolBar.updateButtonState(true);
 
-      // needed until save refreshes form items in the 
-      // correct way
-      // https://issues.openbravo.com/view.php?id=20278
-      form.markForRedraw();
       return false;
     };
 
@@ -1528,16 +1524,6 @@
     return true;
   },
 
-  // overridden as the super does not compare all values
-  // correctly:
-  // https://issues.openbravo.com/view.php?id=20278
-  fieldValuesAreEqual: function (field, value1, value2) {
-    if (field && field.compareValues) {
-      return 0 === field.compareValues(value1, value2);
-    }
-    return this.Super('fieldValuesAreEqual', arguments);
-  },
-
   // called when someone picks something from a picklist, the focus should go to the next
   // item
   focusInNextItem: function (currentItemName) {