Openbravo Issue Tracking System - Retail Modules
View Issue Details
0039872Retail ModulesWeb POSpublic2019-01-03 12:562019-01-17 11:34
gorka_gil 
ranjith_qualiantech_com 
urgentmajoralways
closedfixed 
5
 
RR19Q2 
jorge-garcia
Packaging and release
2018-12-18
pi
https://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/7c3c0cb548f6 [^]
No
0039872: Javascript error is displayed when trying to close pending documents when opening store from a terminal - Cannot read 'models'
This commit (from issue 39816):
 https://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/7c3c0cb548f6 [^]

Makes that this issue happens again:
  https://issues.openbravo.com/view.php?id=39488 [^]

With a new error message:
  TypeError: Cannot read property 'models' of undefined at removeReceiptFromDatabase.


Details of error:
In function removeReceiptFromDatabase,
OB.MobileApp.model.orderList is undefined, previously it checks if undefined before use it, now try to get the models from it without check.

Run test: I39488_VerifyNoErrorWhenClosingPendingDocs

or follow steps to reproduce of issue 39488
No tags attached.
related to defect 0039488 closed rqueralta Javascript error is displayed when trying to close pending documents when opening store from a terminal. 
depends on backport 0039884RR19Q1 closed ranjith_qualiantech_com Javascript error is displayed when trying to close pending documents when opening store from a terminal - Cannot read 'models' 
caused by defect 0039816 closed ranjith_qualiantech_com Sales order are missing using press Generate invoice for order 
png 39872.png (173,121) 2019-01-03 13:04
https://issues.openbravo.com/file_download.php?file_id=12485&type=bug
png
Issue History
2019-01-03 12:56gorka_gilNew Issue
2019-01-03 12:56gorka_gilAssigned To => Retail
2019-01-03 12:56gorka_gilTriggers an Emergency Pack => No
2019-01-03 12:57gorka_gilRelationship addedcaused by 0039816
2019-01-03 12:58gorka_gilRelationship addedrelated to 0039488
2019-01-03 13:01gorka_gilRegression level => Automated tests
2019-01-03 13:01gorka_gilRegression date => 2018-12-18
2019-01-03 13:01gorka_gilRegression introduced in release => pi
2019-01-03 13:01gorka_gilRegression introduced by commit => https://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/7c3c0cb548f6 [^]
2019-01-03 13:04gorka_gilFile Added: 39872.png
2019-01-03 13:18hgbotCheckin
2019-01-03 13:18hgbotNote Added: 0108813
2019-01-03 14:35ranjith_qualiantech_comAssigned ToRetail => ranjith_qualiantech_com
2019-01-03 14:35ranjith_qualiantech_comStatusnew => scheduled
2019-01-07 16:11hgbotCheckin
2019-01-07 16:11hgbotNote Added: 0108843
2019-01-07 16:11hgbotStatusscheduled => resolved
2019-01-07 16:11hgbotResolutionopen => fixed
2019-01-07 16:11hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/7b1a591c616a4292262cc235a8306bb47c2aa73a [^]
2019-01-08 13:51ranjith_qualiantech_comNote Added: 0108854
2019-01-08 13:51ranjith_qualiantech_comStatusresolved => new
2019-01-08 13:51ranjith_qualiantech_comResolutionfixed => open
2019-01-08 13:51ranjith_qualiantech_comStatusnew => scheduled
2019-01-08 14:40ranjith_qualiantech_comStatusscheduled => resolved
2019-01-08 14:40ranjith_qualiantech_comResolutionopen => fixed
2019-01-09 13:42gorka_gilRegression levelAutomated tests => Packaging and release
2019-01-15 17:11jorge-garciaReview Assigned To => jorge-garcia
2019-01-16 10:44jorge-garciaNote Added: 0108973
2019-01-16 10:44jorge-garciaStatusresolved => closed
2019-01-16 10:44jorge-garciaFixed in Version => RR19Q2
2019-01-17 11:34hgbotCheckin
2019-01-17 11:34hgbotNote Added: 0108993

Notes
(0108813)
hgbot   
2019-01-03 13:18   
Repository: tools/automation/pi-mobile
Changeset: 2ec436d244d8a2520fa921e5f4b8256f75005d04
Author: Gorka Gil <gorka.gil <at> openbravo.com>
Date: Thu Jan 03 13:18:02 2019 +0100
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/2ec436d244d8a2520fa921e5f4b8256f75005d04 [^]

Related to issue 39872: disable test till issue is fixed

---
M src-test/org/openbravo/test/mobile/retail/extmodules/selenium/tests/sessions/openstoretill/I39488_VerifyNoErrorWhenClosingPendingDocs.java
---
(0108843)
hgbot   
2019-01-07 16:11   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 7b1a591c616a4292262cc235a8306bb47c2aa73a
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Mon Jan 07 20:40:47 2019 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/7b1a591c616a4292262cc235a8306bb47c2aa73a [^]

Fixed issue 39872 : Receipt should be removed from database even if orderList is empty

* With Sessions module, Cashup window will be loaded before rendering the pointofsale window whem sessions closed in backoffice.
In that case, if receipt is saved in database and not completed, It will shown in cashup window to delete it.
OB.MobileApp.model.orderList will not be initiated while deleting the receipt.
So if orderList is present, receipt to be removed will be deleted from database and orderlist
else receipt will be removed from database only

---
M web/org.openbravo.retail.posterminal/js/model/order.js
---
(0108854)
ranjith_qualiantech_com   
2019-01-08 13:51   
Reopening to create backports
(0108973)
jorge-garcia   
2019-01-16 10:44   
Code reviewed and tested
(0108993)
hgbot   
2019-01-17 11:34   
Repository: tools/automation/pi-mobile
Changeset: 2eba00ac6d5c528eb878c7cfeb9722588d358fdf
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Thu Jan 17 16:04:21 2019 +0530
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/2eba00ac6d5c528eb878c7cfeb9722588d358fdf [^]

Related to issue 39872 : Modified Test 'I39488_VerifyNoErrorWhenClosingPendingDocs'

* Removed TestAnnotations waitFixOf

---
M src-test/org/openbravo/test/mobile/retail/extmodules/selenium/tests/sessions/openstoretill/I39488_VerifyNoErrorWhenClosingPendingDocs.java
---