Fixed issue 26702:Create a record while a filter is applied the focus get lost
authorGuillermo Gil <guillermo.gil@openbravo.com>
Wed, 28 May 2014 08:51:05 +0200
changeset 23392 dfda65fa925f
parent 23391 159979b5db65
child 23393 fc1e0b6f0a4b
child 23395 ede645e45d60
Fixed issue 26702:Create a record while a filter is applied the focus get lost
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/grid/ob-view-grid.js
--- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/grid/ob-view-grid.js	Tue May 27 21:08:30 2014 +0000
+++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/grid/ob-view-grid.js	Wed May 28 08:51:05 2014 +0200
@@ -2872,7 +2872,7 @@
     this.view.standardWindow.autoSaveDone(this.view, true);
 
     // if nothing else got selected, select ourselves then
-    if (!this.getSelectedRecord()) {
+    if (!this.getSelectedRecord() || (this.getSelectedRecord().id === record._originalId)) {
       this.selectRecord(record);
       keepSelection = true;
       this.view.refreshChildViews(keepSelection);