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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0038573
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POSmajorhave not tried2018-05-17 17:572018-06-21 09:32
ReporterasiermartirenaView Statuspublic 
Assigned Toasiermartirena 
PrioritynormalResolutionfixedFixed in VersionRR18Q3
StatusclosedFix in branchFixed in SCM revision69f7c826e004
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Merge Request Status
Review Assigned Tomarvintm
OBNetwork customerNo
Support ticket
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0038573: The save action of the ticket is being executed more times that should

DescriptionThe save action of the order model is being executed locally in Web POS more times that it should, causing performance problems.

When updating a line quantity, a save action is done and then the calculateReceipt process is executed, which also finishes with a save action. The second save is the only necessary (and correct) one.

When introducing many lines at a time, or when doing several changes in the ticket that launches many calculateReceipt processes, the save action is also executed 2 times, when it should be executed only after the last calculate receipt.

Also, when the deleting lines process finishes, a save action is executed in addition to the calculateReceipt action. In this case, the last save action is correct, but the calculateReceipt save action must be avoided.

In the other hand, when loading receipts to the Web POS, the order is not being saved locally at the end of the process, which is an error, because if the user presses the F5 having that order, the ticket status is incorrect.
Steps To ReproduceLoad the Web POS. Introduce multiple lines -> Multiple save actions

Change the quantity of some line -> Multiple save actions

Delete a line -> Multiple save actions

Load a ticket -> The ticket is not save fully, so if the user presses F5, is visible that the ticket is corrupted
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
causes defect 0038825 closedjorge-garcia Order not saved in WebSQL if the customer is changed while the first product is being added. 

-  Notes
(0104595)
hgbot (developer)
2018-05-21 09:06

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 69f7c826e00458e543be9280089778be37479ac2
Author: Asier Martirena <asier.martirena <at> openbravo.com>
Date: Fri May 18 10:10:38 2018 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/69f7c826e00458e543be9280089778be37479ac2 [^]

Fixed issue 38573: The save action of the ticket is being executed more times that should

When doing the save action in a calculateReceipt function, now the save is only done if there are no pending calculateReceipt processes.
When modifying the line quantity, the save action is no directly called now, is called from the calculateReceipt action that is executed when setting a new quantity.
In the delete lines process, now the save action is not executed when doing the calculateReceipt, because is called after that. In this flow, is necessary to call it later. Also, to finish the delete lines process the Web POS was waiting for the save action, now the action is launched but the user can continue without waiting for the response.
The calculateGrossAndSave funtion is sent with the true parameter when loading a receipt, otherwise the ticket is not correctly stored in the Web SQL, causing problems if an user presses the F5 having the ticket loaded.

---
M web/org.openbravo.retail.posterminal/js/model/order.js
M web/org.openbravo.retail.posterminal/js/utils/orderSelectorUtils.js
---

- Issue History
Date Modified Username Field Change
2018-05-17 17:57 asiermartirena New Issue
2018-05-17 17:57 asiermartirena Assigned To => asiermartirena
2018-05-17 17:57 asiermartirena OBNetwork customer => No
2018-05-17 17:57 asiermartirena Triggers an Emergency Pack => No
2018-05-21 09:06 hgbot Checkin
2018-05-21 09:06 hgbot Note Added: 0104595
2018-05-21 09:06 hgbot Status new => resolved
2018-05-21 09:06 hgbot Resolution open => fixed
2018-05-21 09:06 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/69f7c826e00458e543be9280089778be37479ac2 [^]
2018-05-21 15:34 asiermartirena Description Updated View Revisions
2018-06-21 09:32 marvintm Review Assigned To => marvintm
2018-06-21 09:32 marvintm Status resolved => closed
2018-06-21 09:32 marvintm Fixed in Version => RR18Q3
2018-06-25 15:36 aaroncalero Relationship added causes 0038825


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker