Anonymous | Login
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POSmajoralways2019-04-11 18:152019-05-24 13:07
ReporterasiermartirenaView Statuspublic 
Assigned Toasiermartirena 
PrioritynormalResolutionfixedFixed in VersionRR19Q3
StatusclosedFix in branchFixed in SCM revisiona3c01b29e42f
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Tomarvintm
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo

0040601: The calculateReceipt function is called to much times when changing prices

DescriptionThe calculateReceipt function is called to many times when changing prices in the Web POS.
If a line is selected to change the price, the calculateReceipt function is automatically launched on a backbone event when the price is updated, and is launched again after that. That second call mustn't be called.
If multiple lines are selected and their price is changed, one calculate receipt is launched for each line, and a final one is also called. This is visible for the user, because the first line is updated in the first calculateReceipt and the other ones in the final one. The middle executions are not done because of the logic that the calculate receipt has to avoid multiple (more than two, cause a final call is always launched) calls.
Steps To ReproduceAdd a breakpoint in the calculateReceipt function.
Add a line to the ticket.
Change the price --> The calculateReceipt is executed twice
Add a new line.
Select both lines and change the price --> The calculateReceipt is executed four times, even if the middle calls are not executed. The fourth call is the final call the calculateReceipt has to ensure that the process is executed with all the data updated.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
hgbot (developer)
2019-04-13 19:45

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: a3c01b29e42f495e3c7fbf987df550d6bc8ec253
Author: Asier Martirena <asier.martirena <at>>
Date: Fri Apr 12 21:33:04 2019 +0200
URL: [^]

Fixed issue 40601: The calculateReceipt function is called to much times when changing prices

New API to set prices to lines. It should be always called, even if the call is only for a single line.
Removed the call of the calculate receipt done after the price is modified. Now, when updating a single line's price it is only called from the event launched when updating the price of the order line.
For multi selection, the calculateReceipt is disabled until the last price is updated. After that, it is enabled and launched.
Same modifications for the undo action.

M web/org.openbravo.retail.posterminal/js/model/order.js
M web/org.openbravo.retail.posterminal/js/pointofsale/view/keyboardorder.js
gorka_gil (administrator)
2019-04-24 18:45

Reopen issue because fail a test of quarantine:
hgbot (developer)
2019-04-24 18:54

Repository: tools/automation/pi-mobile
Changeset: 29c125d8abda46dee5430f63b48420fea2a23d22
Author: Gorka Gil <gorka.gil <at>>
Date: Wed Apr 24 18:53:39 2019 +0200
URL: [^]

Related to issue 40601: disable test I38724_AllowPriceModificationVerifiedReturns till issue is resolved

M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/receipts/
hgbot (developer)
2019-04-29 17:00

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 557f917bedfd2ff7e66f51742062675c996c1121
Author: Asier Martirena <asier.martirena <at>>
Date: Mon Apr 29 12:13:20 2019 +0200
URL: [^]

Related to issue 40601: Call the calculateReceipt even if discounts are skipped

M web/org.openbravo.retail.posterminal/js/pointofsale/model/pointofsale-model.js
hgbot (developer)
2019-04-30 13:43

Repository: tools/automation/pi-mobile
Changeset: 5c840bf841fadad7a29e2a2e2123f8ba0f60834b
Author: Gorka Gil <gorka.gil <at>>
Date: Tue Apr 30 13:42:36 2019 +0200
URL: [^]

Related to issue 40601: Remove anotation waitFixOf that is no longer needed

M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/receipts/

- Issue History
Date Modified Username Field Change
2019-04-11 18:15 asiermartirena New Issue
2019-04-11 18:15 asiermartirena Assigned To => asiermartirena
2019-04-11 18:15 asiermartirena Triggers an Emergency Pack => No
2019-04-13 19:45 hgbot Checkin
2019-04-13 19:45 hgbot Note Added: 0111118
2019-04-13 19:45 hgbot Status new => resolved
2019-04-13 19:45 hgbot Resolution open => fixed
2019-04-13 19:45 hgbot Fixed in SCM revision => [^]
2019-04-24 18:45 gorka_gil Note Added: 0111293
2019-04-24 18:45 gorka_gil Status resolved => new
2019-04-24 18:45 gorka_gil Resolution fixed => open
2019-04-24 18:54 hgbot Checkin
2019-04-24 18:54 hgbot Note Added: 0111294
2019-04-29 17:00 hgbot Checkin
2019-04-29 17:00 hgbot Note Added: 0111372
2019-04-30 10:07 asiermartirena Status new => scheduled
2019-04-30 10:07 asiermartirena Status scheduled => resolved
2019-04-30 10:07 asiermartirena Resolution open => fixed
2019-04-30 13:43 hgbot Checkin
2019-04-30 13:43 hgbot Note Added: 0111387
2019-05-24 13:07 marvintm Review Assigned To => marvintm
2019-05-24 13:07 marvintm Status resolved => closed
2019-05-24 13:07 marvintm Fixed in Version => RR19Q3

Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker