Openbravo Issue Tracking System - Retail Modules
View Issue Details
0036980Retail ModulesWeb POSpublic2017-09-08 09:112017-10-31 09:40
adrianromero 
jorge-garcia 
urgentmajorhave not tried
closedfixed 
5
 
RR17Q3.1RR17Q3.1 
marvintm
No
0036980: When refreshing (F5) in all windows but Web POS, the window appears before finishing loading all models
In any other window different than main Web POS window, for example Cashup, Cash Managemement, ... If the user press F5 to reload the page, the loading message appears but when the progress bar is around 25% the window is displayed. it does not wait for all models to be loaded. Also it can be observed that in the console window of the web browser, the models continue loading.

The same is happening with Open till. The window gets opened before the models get loaded even if it is a Full Refresh.
* Log in Web POS as Vallblanca in live builds
* Navigate to Cash Up
* Open Developer tools and go to Console tab.
* Refresh the web browser. Press F5
* Observe that when the loading bar is around 25% while loading Tax Rate Model the cashup window appears.
* Observe in the console the log traces showing that models continue loading while the user can operate the Cashup window.
No window should be opened if the models are not properly loaded
No tags attached.
blocks defect 0036809 closed jorge-garcia When refreshing (F5) in all windows but Web POS, the window appears before finishing loading all models 
Issue History
2017-10-02 10:57marvintmTypedefect => backport
2017-10-02 10:57marvintmTarget Version => RR17Q3.1
2017-10-27 12:44hgbotCheckin
2017-10-27 12:44hgbotNote Added: 0100116
2017-10-27 12:45hgbotCheckin
2017-10-27 12:45hgbotNote Added: 0100119
2017-10-27 12:45hgbotStatusscheduled => resolved
2017-10-27 12:45hgbotResolutionopen => fixed
2017-10-27 12:45hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/bee387376275f82b0da54f8dbf69206d24d73632 [^] => http://code.openbravo.com/retail/backports/3.0RR17Q3.1/org.openbravo.mobile.core/rev/602e337d4806e21ad980926d6bab6b882ec802a9 [^]
2017-10-31 09:40marvintmReview Assigned To => marvintm
2017-10-31 09:40marvintmStatusresolved => closed
2017-10-31 09:40marvintmFixed in Version => RR17Q3.1

Notes
(0100116)
hgbot   
2017-10-27 12:44   
Repository: retail/backports/3.0RR17Q3.1/org.openbravo.retail.posterminal
Changeset: 7cb7b54135f322518117f65d81cf51262d65edad
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Fri Oct 27 12:22:49 2017 +0200
URL: http://code.openbravo.com/retail/backports/3.0RR17Q3.1/org.openbravo.retail.posterminal/rev/7cb7b54135f322518117f65d81cf51262d65edad [^]

Related to issue 36980: When refreshing in all windows but Web POS the window
appears before finishing loading all models

Change the listener to indicate the models has changed.

---
M web/org.openbravo.retail.posterminal/js/data/windowmodel.js
---
(0100119)
hgbot   
2017-10-27 12:45   
Repository: retail/backports/3.0RR17Q3.1/org.openbravo.mobile.core
Changeset: 602e337d4806e21ad980926d6bab6b882ec802a9
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Fri Oct 27 12:30:23 2017 +0200
URL: http://code.openbravo.com/retail/backports/3.0RR17Q3.1/org.openbravo.mobile.core/rev/602e337d4806e21ad980926d6bab6b882ec802a9 [^]

Fixed issue 36980: When refreshing in all windows but Web POS the window
appears before finishing loading all models

The solution is to wait until all models are loaded.

Fix some problems when navigating to other windows such as Cashup,
CashManagement and CashUpPartial.

Also fixed some problems if the user refresh the webPOS in a different
windows apart from pointofsale.

Check if model to be loaded has modelName defined. If not, the model will
not be loaded and used in the aplication.

---
M web/org.openbravo.mobile.core/source/data/ob-dal.js
M web/org.openbravo.mobile.core/source/data/ob-windowmodel.js
M web/org.openbravo.mobile.core/source/model/ob-terminal-model.js
---