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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0035669
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POSmajorrandom2017-03-31 13:542018-07-24 17:41
ReporteraaroncaleroView Statuspublic 
Assigned Tomarvintm 
PrioritynormalResolutionfixedFixed in VersionRR17Q3
StatusclosedFix in branchFixed in SCM revision4d1e69ce0acd
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Toguilleaer
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0035669: It is possible to load tickets in web pos with wrongly sorted lines

DescriptionWhen using remote mode for products, when a ticket is loaded in web pos several requests are done to the server to load product data for each line.
These requests are executed in parallel and might or might not return results on the same order they are executed.
After each request have finished, the corresponding line is added to the orderline list of the receipt.
Depending on the return order of the server calls, order lines might be added to the orderline list at the wrong index.
Steps To ReproduceIn a development environment (to be able to set breakpoints)
Login in backend, go to the preference window and enable the remote mode for products.
Login in web pos and create a new layaway (Menu > Layaway this receipt).
Add 3 lines (any product):
First line with qty 1
Second line with qty 2
Third line with qty 3.
Click on the Total Amount button and then on Layaway.
In Eclipse, set a breakpoint on the Product.java file (product master data query).
In web pos, try to load the previously created layaway.
Return to eclise; there will be 3 paused threads on the Product.java file.
Identify the thread corresponding to the third line and continue its execution.
Identify the thread corresponding to the second line and continue its execution.
Identify the thread corresponding to the first line and continue its execution.
Continue the execution of anything that might be remaining.
Go back to web pos and verify the receipt lines:
The fist line will be the one with qty 1
The second line will be the one with qty 3
The third line will be the one with qty 2.
Proposed Solution2 possible solutions
1. Refactor the loading of receipt lines and create a new recursive function to load product data and add lines to the receipt.
2. Sort the collection of lines by the lineNo after loading them.
TagsNo tags attached.
Attached Filesdiff file icon issue35669.diff [^] (777 bytes) 2017-03-31 19:08 [Show Content]

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0095816)
hgbot (developer)
2017-04-03 16:59

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 4d1e69ce0acda5556e331ba5d74fad7ecf88fb20
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Fri Mar 31 17:23:09 2017 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/4d1e69ce0acda5556e331ba5d74fad7ecf88fb20 [^]

Fixed issue 35669. Sort the lines collection after having added all of them, to ensure that the final order is correct.

---
M web/org.openbravo.retail.posterminal/js/model/order.js
---
(0105931)
hgbot (developer)
2018-07-24 17:41

Repository: tools/automation/pi-mobile
Changeset: ea36c68ab29ba114863b1d074bc86f2283d6df4f
Author: Alejandro <alekosmp86 <at> gmail.com>
Date: Fri Jul 20 15:16:40 2018 -0400
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/ea36c68ab29ba114863b1d074bc86f2283d6df4f [^]

Related to issue 35669: added automated test

---
A src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/receipts/I35669_VerifyTicketLinesOrder.java
---

- Issue History
Date Modified Username Field Change
2017-03-31 13:54 aaroncalero New Issue
2017-03-31 13:54 aaroncalero Assigned To => Retail
2017-03-31 13:54 aaroncalero Resolution time => 1492120800
2017-03-31 13:54 aaroncalero Triggers an Emergency Pack => No
2017-03-31 16:36 mario_castello Assigned To Retail => mario_castello
2017-03-31 19:08 marvintm File Added: issue35669.diff
2017-04-03 16:59 hgbot Checkin
2017-04-03 16:59 hgbot Note Added: 0095816
2017-04-03 16:59 hgbot Status new => resolved
2017-04-03 16:59 hgbot Resolution open => fixed
2017-04-03 16:59 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/4d1e69ce0acda5556e331ba5d74fad7ecf88fb20 [^]
2017-04-05 17:52 marvintm Assigned To mario_castello => marvintm
2017-04-10 10:47 guilleaer Review Assigned To => guilleaer
2017-04-10 10:47 guilleaer Status resolved => closed
2017-04-10 10:47 guilleaer Fixed in Version => RR17Q3
2018-07-24 17:41 hgbot Checkin
2018-07-24 17:41 hgbot Note Added: 0105931


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker