details:   https://code.openbravo.com/erp/devel/pi/rev/2ecc34ec6e7d
changeset: 27907:2ecc34ec6e7d
user:      Carlos Aristu <carlos.aristu <at> openbravo.com>
date:      Tue Nov 17 08:49:16 2015 +0100
summary:   fixes issue 29746: unneded FIC request on record selection in some 
windows

This problem happens on those windows which do not have buttons on the right 
side of the toolbar. The EDIT request was introduced to solve issue #18711 in 
order to set the session variables in grid mode. This called was done through 
this.view.setContextInfo();. Then after fixing issue #20522 the second call in 
SETSESSION mode was introduced.

To avoid the call in EDIT mode we have just removed the call to 
this.view.setContextInfo();. This way just the call in SETSESSION mode is 
performed.

diffstat:

 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-toolbar.js
 |  6 +-----
 1 files changed, 1 insertions(+), 5 deletions(-)

diffs (16 lines):

diff -r 75603f5172e6 -r 2ecc34ec6e7d 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-toolbar.js
--- 
a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-toolbar.js
    Sat Nov 14 14:34:45 2015 +0100
+++ 
b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/toolbar/ob-toolbar.js
    Tue Nov 17 08:49:16 2015 +0100
@@ -1234,11 +1234,7 @@
       }
     }
 
-    if (buttons.length === 0) {
-      if (!noSetSession && this.view.viewGrid && 
this.view.viewGrid.getSelectedRecord()) {
-        this.view.setContextInfo();
-      }
-    } else {
+    if (buttons.length !== 0) {
       length = buttons.length;
       for (i = 0; i < length; i++) {
         if (!currentContext || currentContext !== buttons[i].contextView) {

------------------------------------------------------------------------------
_______________________________________________
Openbravo-commits mailing list
Openbravo-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to