Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0028391
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POSminorhave not tried2014-12-11 18:062015-04-16 15:15
ReporteraaroncaleroView Statuspublic 
Assigned Toaaroncalero 
PrioritylowResolutionfixedFixed in VersionRR15Q2
StatusclosedFix in branchFixed in SCM revisionbc6741e58642
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionpiSCM revision 
Review Assigned Toadrianromero
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0028391: Changing main window before callbacks are executed causes javascript errors

DescriptionChanging the main window of the WebPOS (e.g. from #retail.pointofsale to #retail.cashup) before the initial window has finished loading (all callbacks have finished executing) causes javascript errors because the initial window is destroyed upon navigation. If there are pending callbacks that access window components (which have already been destroyed), errors similar to the following will be logged to the console:
posterminal.main.js: Uncaught TypeError: Cannot read property 'createComponent' of undefined;
Steps To ReproduceGo to https://livebuilds.openbravo.com/retail_pi_pgsql/web/org.openbravo.retail.posterminal/?terminal=VBS-1 [^]
Log in with demouser/openbravo
As soon as the menu is available, switch to Cash Management or Cash Up windows.
Error messages will appear on the upper right corner of the screen and they will also be logged to the browser console.
Proposed SolutionCallbacks that execute asynchronously should check that the elements they are referencing still exist (objects that have been destroyed have a 'destroyed' attribute set to true).
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
depends on backport 0029328RR15Q1.3 closedaaroncalero Changing main window before callbacks are executed causes javascript errors 
depends on feature request 0028933RR16Q1 closedRetail QA: RR15Q2: Add tests for Mobile applications 
related to defect 0029575 newmarvintm Changing main window just after login causes a double navigation 

-  Notes
(0072512)
hgbot (developer)
2014-12-15 14:54

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 56c064f962a430657d343bb749c73a816f0875a2
Author: Aaron Calero <aaron.calero <at> openbravo.com>
Date: Mon Dec 15 13:42:20 2014 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/56c064f962a430657d343bb749c73a816f0875a2 [^]

Fixed issue 28391: Changing main window before callbacks are executed causes javascript errors

Fixed code in posterminal module. Added a check to the callback of the function that loads return reasons, in order to return inmediately if the component has already been destroyed.

---
M web/org.openbravo.retail.posterminal/js/pointofsale/view/editline.js
---
(0072513)
hgbot (developer)
2014-12-15 14:55

Repository: erp/pmods/org.openbravo.mobile.core
Changeset: 04113fd64d2f7c5716099f9de761afa7294ab241
Author: Aaron Calero <aaron.calero <at> openbravo.com>
Date: Mon Dec 15 13:51:22 2014 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/04113fd64d2f7c5716099f9de761afa7294ab241 [^]

Fixed issue 28391: Changing main window before callbacks are executed causes javascript errors

Fixed code in mobile core module. Added several checks to return inmediately if components have already been destroyed.

---
M web/org.openbravo.mobile.core/source/component/ob-keyboard.js
M web/org.openbravo.mobile.core/source/retail/component/ob-retail-product-browser.js
M web/org.openbravo.mobile.core/source/retail/component/ob-retail-searchproductcharacteristic.js
M web/org.openbravo.mobile.core/source/retail/component/ob-retail-searchproducts.js
---
(0073321)
hgbot (developer)
2015-01-07 10:19

Repository: erp/pmods/org.openbravo.mobile.core
Changeset: 0a062145cfd9da1d0845c08cc0ce4f9b4210e125
Author: Aaron Calero <aaron.calero <at> openbravo.com>
Date: Wed Jan 07 10:01:29 2015 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/0a062145cfd9da1d0845c08cc0ce4f9b4210e125 [^]

Fixed issue 28391: Changing main window before callbacks are executed causes javascript errors

Added check to the callback that loads products to return inmediately if the component has already been destroyed.

---
M web/org.openbravo.mobile.core/source/retail/component/ob-retail-product-browser.js
---
(0073322)
hgbot (developer)
2015-01-07 10:19

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: d7d844ee8a819805d1c870289b1d36ac2205cbe9
Author: Aaron Calero <aaron.calero <at> openbravo.com>
Date: Wed Jan 07 10:17:57 2015 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/d7d844ee8a819805d1c870289b1d36ac2205cbe9 [^]

Fixed issue 28391: Changing main window before callbacks are executed causes javascript errors

Added check to the callback that loads sales representatives to return inmediately if the component has been destroyed

---
M web/org.openbravo.retail.posterminal/js/components/modalreceiptproperties.js
---
(0075724)
malsasua (developer)
2015-03-18 10:29

reopened to add a new changeset related with this issue, and to do the backport to PR15Q1
(0075725)
hgbot (developer)
2015-03-18 10:39

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 541c0fca5e89784ea3ebf47ada89cd3f0e343de5
Author: Miguel A. Alsasua <miguel.alsasua <at> openbravo.com>
Date: Wed Mar 18 10:37:48 2015 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/541c0fca5e89784ea3ebf47ada89cd3f0e343de5 [^]

fixed issue 28391: added a line to check if the object has been destroyed when the callback is executed

---
M web/org.openbravo.retail.posterminal/js/pointofsale/view/subwindows/customers/components/sharedcomponents.js
---
(0076082)
malsasua (developer)
2015-03-27 13:18

verified
(0076453)
hgbot (developer)
2015-04-10 15:03

Repository: retail/backports/3.0RR15Q1.3/org.openbravo.mobile.core
Changeset: 4ae99dca0602336b10972fdd654a9931560292e1
Author: Aaron Calero <aaron.calero <at> openbravo.com>
Date: Wed Jan 07 10:01:29 2015 +0100
URL: http://code.openbravo.com/retail/backports/3.0RR15Q1.3/org.openbravo.mobile.core/rev/4ae99dca0602336b10972fdd654a9931560292e1 [^]

Fixed issue 28391: Changing main window before callbacks are executed causes javascript errors

Added check to the callback that loads products to return inmediately if the component has already been destroyed.

---
M web/org.openbravo.mobile.core/source/retail/component/ob-retail-product-browser.js
---
(0076456)
hgbot (developer)
2015-04-10 15:03

Repository: retail/backports/3.0RR15Q1.3/org.openbravo.retail.posterminal
Changeset: 4c5e04e84b70af3d4446424761a65674093ff322
Author: Aaron Calero <aaron.calero <at> openbravo.com>
Date: Wed Jan 07 10:17:57 2015 +0100
URL: http://code.openbravo.com/retail/backports/3.0RR15Q1.3/org.openbravo.retail.posterminal/rev/4c5e04e84b70af3d4446424761a65674093ff322 [^]

Fixed issue 28391: Changing main window before callbacks are executed causes javascript errors

Added check to the callback that loads sales representatives to return inmediately if the component has been destroyed

---
M web/org.openbravo.retail.posterminal/js/components/modalreceiptproperties.js
---
(0076457)
hgbot (developer)
2015-04-10 15:03

Repository: retail/backports/3.0RR15Q1.3/org.openbravo.retail.posterminal
Changeset: bc6741e586427eaef63e022cc753b789ec9f9e83
Author: Miguel A. Alsasua <miguel.alsasua <at> openbravo.com>
Date: Wed Mar 18 10:37:48 2015 +0100
URL: http://code.openbravo.com/retail/backports/3.0RR15Q1.3/org.openbravo.retail.posterminal/rev/bc6741e586427eaef63e022cc753b789ec9f9e83 [^]

fixed issue 28391: added a line to check if the object has been destroyed when the callback is executed

---

---
(0076491)
hgbot (developer)
2015-04-13 17:06

Repository: retail/backports/3.0RR15Q1.3/org.openbravo.retail.posterminal
Changeset: b71c669fc94bf4adb1e24e8934397a47bca6c0b2
Author: Miguel A. Alsasua <miguel.alsasua <at> openbravo.com>
Date: Wed Mar 18 10:37:48 2015 +0100
URL: http://code.openbravo.com/retail/backports/3.0RR15Q1.3/org.openbravo.retail.posterminal/rev/b71c669fc94bf4adb1e24e8934397a47bca6c0b2 [^]

Related to issue 28391, fixes issue 29328: Added a line to check if the object has been destroyed when the callback is executed

---
M web/org.openbravo.retail.posterminal/js/pointofsale/view/subwindows/customers/components/sharedcomponents.js
---
(0076590)
adrianromero (manager)
2015-04-16 15:15

Verified. But still exists a new issue related with the same action. See https://issues.openbravo.com/view.php?id=29575 [^]

- Issue History
Date Modified Username Field Change
2014-12-11 18:06 aaroncalero New Issue
2014-12-11 18:06 aaroncalero Assigned To => marvintm
2014-12-11 18:06 aaroncalero Triggers an Emergency Pack => No
2014-12-15 13:25 aaroncalero Assigned To marvintm => aaroncalero
2014-12-15 14:54 hgbot Checkin
2014-12-15 14:54 hgbot Note Added: 0072512
2014-12-15 14:54 hgbot Status new => resolved
2014-12-15 14:54 hgbot Resolution open => fixed
2014-12-15 14:54 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/56c064f962a430657d343bb749c73a816f0875a2 [^]
2014-12-15 14:55 hgbot Checkin
2014-12-15 14:55 hgbot Note Added: 0072513
2014-12-15 14:55 hgbot Fixed in SCM revision http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/56c064f962a430657d343bb749c73a816f0875a2 [^] => http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/04113fd64d2f7c5716099f9de761afa7294ab241 [^]
2014-12-22 16:05 aaroncalero Status resolved => new
2014-12-22 16:05 aaroncalero Resolution fixed => open
2015-01-07 10:19 hgbot Checkin
2015-01-07 10:19 hgbot Note Added: 0073321
2015-01-07 10:19 hgbot Status new => resolved
2015-01-07 10:19 hgbot Resolution open => fixed
2015-01-07 10:19 hgbot Fixed in SCM revision http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/04113fd64d2f7c5716099f9de761afa7294ab241 [^] => http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/0a062145cfd9da1d0845c08cc0ce4f9b4210e125 [^]
2015-01-07 10:19 hgbot Checkin
2015-01-07 10:19 hgbot Note Added: 0073322
2015-01-07 10:19 hgbot Fixed in SCM revision http://code.openbravo.com/erp/pmods/org.openbravo.mobile.core/rev/0a062145cfd9da1d0845c08cc0ce4f9b4210e125 [^] => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/d7d844ee8a819805d1c870289b1d36ac2205cbe9 [^]
2015-01-09 14:49 Orekaria Review Assigned To => Orekaria
2015-01-09 14:49 Orekaria Status resolved => closed
2015-01-09 14:49 Orekaria Fixed in Version => pi
2015-03-18 10:29 malsasua Note Added: 0075724
2015-03-18 10:29 malsasua Status closed => new
2015-03-18 10:29 malsasua Resolution fixed => open
2015-03-18 10:29 malsasua Fixed in Version pi =>
2015-03-18 10:29 malsasua Status new => scheduled
2015-03-18 10:39 hgbot Checkin
2015-03-18 10:39 hgbot Note Added: 0075725
2015-03-18 10:39 hgbot Status scheduled => resolved
2015-03-18 10:39 hgbot Resolution open => fixed
2015-03-18 10:39 hgbot Fixed in SCM revision http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/d7d844ee8a819805d1c870289b1d36ac2205cbe9 [^] => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/541c0fca5e89784ea3ebf47ada89cd3f0e343de5 [^]
2015-03-18 11:12 Orekaria Relationship added depends on 0028933
2015-03-27 13:18 malsasua Review Assigned To Orekaria => malsasua
2015-03-27 13:18 malsasua Note Added: 0076082
2015-03-27 13:18 malsasua Status resolved => closed
2015-03-27 13:18 malsasua Fixed in Version => RR15Q2
2015-04-10 15:03 hgbot Checkin
2015-04-10 15:03 hgbot Note Added: 0076453
2015-04-10 15:03 hgbot Status closed => resolved
2015-04-10 15:03 hgbot Fixed in SCM revision http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/541c0fca5e89784ea3ebf47ada89cd3f0e343de5 [^] => http://code.openbravo.com/retail/backports/3.0RR15Q1.3/org.openbravo.mobile.core/rev/4ae99dca0602336b10972fdd654a9931560292e1 [^]
2015-04-10 15:03 hgbot Checkin
2015-04-10 15:03 hgbot Note Added: 0076456
2015-04-10 15:03 hgbot Fixed in SCM revision http://code.openbravo.com/retail/backports/3.0RR15Q1.3/org.openbravo.mobile.core/rev/4ae99dca0602336b10972fdd654a9931560292e1 [^] => http://code.openbravo.com/retail/backports/3.0RR15Q1.3/org.openbravo.retail.posterminal/rev/4c5e04e84b70af3d4446424761a65674093ff322 [^]
2015-04-10 15:03 hgbot Checkin
2015-04-10 15:03 hgbot Note Added: 0076457
2015-04-10 15:03 hgbot Fixed in SCM revision http://code.openbravo.com/retail/backports/3.0RR15Q1.3/org.openbravo.retail.posterminal/rev/4c5e04e84b70af3d4446424761a65674093ff322 [^] => http://code.openbravo.com/retail/backports/3.0RR15Q1.3/org.openbravo.retail.posterminal/rev/bc6741e586427eaef63e022cc753b789ec9f9e83 [^]
2015-04-13 17:06 hgbot Checkin
2015-04-13 17:06 hgbot Note Added: 0076491
2015-04-13 18:37 adrianromero Relationship added related to 0029575
2015-04-16 15:15 adrianromero Review Assigned To malsasua => adrianromero
2015-04-16 15:15 adrianromero Note Added: 0076590
2015-04-16 15:15 adrianromero Status resolved => closed


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker