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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0030771
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POSmajoralways2015-09-04 21:432015-12-24 04:55
ReporterOrekariaView Statuspublic 
Assigned Tojorge-garcia 
PriorityurgentResolutionfixedFixed in VersionRR16Q1
StatusclosedFix in branchFixed in SCM revision5beee319e358
ProjectionnoneETAnoneTarget VersionRR16Q1
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned ToOrekaria
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0030771: CalculateTaxes should not be executed when the receipt is being closed

DescriptionCalculateTaxes should not be executed when the receipt is being closed

Taxes calculation should be executed before the receipt is being closed
Steps To ReproduceOpen the pointofsale-model.js
Verify that receipt.prepareToSend, executes the calculateTaxes flow
Proposed SolutionCreate a RecalculateReceipt method that wraps applydiscounts, calculateGross and calculateTaxes
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0030809 closedjorge-garcia CalculateGross functionality may be called several times in parallel 
related to defect 0034600 closedranjith_qualiantech_com in Error While Importing, some properties in the JSON order are empty: taxlines/tax 
blocks defect 0030856 closedRetail Some null fileds json order causes an error. Line net is null, ObposAppCashup is null, Line Taxes are null, Taxes are null 
blocks defect 0030857 closedRetail Differents orders from web POS with same document No 
blocks defect 0030501 closedmarvintm Wrong tax calculation the pricelist does not include taxes. 
blocks defect 0030904 closedjorge-garcia Taxes and total not updated when a line is removed with the old discount flow 
causes defect 0032699 closedshivum039 Firm quotation doesn't work when creating a order from a quotation 

-  Notes
(0080315)
Orekaria (administrator)
2015-09-10 12:43

Tests failing in first refactor:

ret-test:

I26806_CashupTotalNotShown
CashUpWithTotalPaidCredit
CashUpWithPartialPaidCredit
CashUpWithTotalPaidCredit
SALa020_CreateReturn
SALa020_CreateReturn
I28322_WrongInvoiceWhenPayingLayawayWithCreditII
I28322_WrongInvoiceWhenPayingLayawayWithCreditI
I28272_HookPreOrderSaveNotCancelling.test1

ret-modules:

CreateSaleTrainingMode
(0080407)
Orekaria (administrator)
2015-09-15 16:03
edited on: 2015-09-15 16:03

2nd

DiscPromByPrice.class, //
 I25515_ReceiptAfterRemovedLineFailsToBeSaved.class, //
 I28100_DiscountsNotAppliedToReturnLinesII.class, //
 I28164_DiscountsRemovedWhenReturnPresentII.class, //
 I28322_WrongInvoiceWhenPayingLayawayWithCreditI.class, //
 I28322_WrongInvoiceWhenPayingLayawayWithCreditII.class, //
 I28728_UndoButtonRemovesInformation.class, //
 I30658_VerifyUserCashpUp.class, //
 QuotationnoAfterQuotationLogoutLogin.class, //

(0080510)
hgbot (developer)
2015-09-19 13:05

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 736fc10bcdceaac80b8dc3964f32c83dfdc685be
Author: Rafa Alonso <ral <at> openbravo.com>
Date: Sat Sep 12 18:18:43 2015 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/736fc10bcdceaac80b8dc3964f32c83dfdc685be [^]

Related to issue 30771: Add a new verifycation for the 'net' line amounts before the receipt is closed

---
M web/org.openbravo.retail.posterminal/js/data/dataordersave.js
---
(0082736)
hgbot (developer)
2015-12-14 18:18

Repository: tools/automation/pi-mobile
Changeset: 2f76c35026f6586e1aeba0721db588e3738afc7d
Author: Christian Goni <christian.goni <at> openbravo.com>
Date: Fri Dec 11 09:42:40 2015 +0100
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/2f76c35026f6586e1aeba0721db588e3738afc7d [^]

Related to Issue 30904, issue 30771: Taxes and total not updated when a line is removed with the old discount flow

This test is expected to pass when the 30771 is finished

---
A src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/discountsandpromotions/I30904_TaxesAndTotalNotUpdated.java
---
(0082769)
hgbot (developer)
2015-12-15 15:15

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: ed7f8734ef3bb2cd7eb6b310facea36835c6d9cb
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Tue Dec 15 13:23:54 2015 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/ed7f8734ef3bb2cd7eb6b310facea36835c6d9cb [^]

Fixed issue 30771: CalculateTaxes should not be executed when the receipt
is being closed

The problem was that, while the recipt is being closed, the recipt could change
in the process.

The proposed solution is to change the places and the way the POS calculates
the promotions, taxes and the gross of the receipt.

With these objective, it's created the function calculateReceipt. The extra
calculateTaxes, applyPromotions and calculateGross functions have been deleted
from some files.

---
M web/org.openbravo.retail.posterminal/js/components/modalmultiorders.js
M web/org.openbravo.retail.posterminal/js/components/modalpaidreceipts.js
M web/org.openbravo.retail.posterminal/js/data/dataordersave.js
M web/org.openbravo.retail.posterminal/js/model/discounts.js
M web/org.openbravo.retail.posterminal/js/model/executor.js
M web/org.openbravo.retail.posterminal/js/model/order.js
M web/org.openbravo.retail.posterminal/js/pointofsale/model/pointofsale-model.js
M web/org.openbravo.retail.posterminal/js/pointofsale/view/editline.js
M web/org.openbravo.retail.posterminal/js/pointofsale/view/modals/modalcreditsales.js
M web/org.openbravo.retail.posterminal/js/pointofsale/view/pointofsale.js
---
(0082770)
hgbot (developer)
2015-12-15 15:15

Repository: erp/pmods/org.openbravo.retail.discounts
Changeset: 6568ad45001abbb8a123691b6315c62f577f56d4
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Thu Dec 10 15:47:36 2015 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts/rev/6568ad45001abbb8a123691b6315c62f577f56d4 [^]

Related to issue 30771: CalculateTaxes should not be executed when the receipt
is being closed

ApplyDiscounts has been replaced by a calculateReceipt function

---
M web/org.openbravo.retail.discounts/js/promotion-pack.js
---
(0082771)
hgbot (developer)
2015-12-15 15:15

Repository: erp/pmods/org.openbravo.retail.returns
Changeset: d1b1ad873e30ee3e90c4b99f9a190dad5d47186a
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Thu Nov 26 18:00:48 2015 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.returns/rev/d1b1ad873e30ee3e90c4b99f9a190dad5d47186a [^]

Related to issue 30771: CalculateTaxes should not be executed when the receipt
is being closed

CalculateGross has been replaced by a calculateReceipt function

---
M web/org.openbravo.retail.returns/js/modalReturnLines.js
---
(0082772)
hgbot (developer)
2015-12-15 15:16

Repository: tools/automation/pi-mobile
Changeset: c9181f298bb3f5cd1ecea5f6f7b0a4a1b1aba72e
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Tue Dec 15 11:06:45 2015 +0100
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/c9181f298bb3f5cd1ecea5f6f7b0a4a1b1aba72e [^]

Related to issue 30771: CalculateTaxes should not be executed when the receipt
is being closed

Some changes are necessary to have the same ticket in the client and the order
from the backend

---
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/returns/I31326_VerifyCorrectPaidReturnValues.java
---
(0082833)
Orekaria (administrator)
2015-12-17 15:29

The SPMSaleAndReloadSharedPayments test is failing

Error:
deaa604bd23a43b5d3c897d9a290ea9a_WebPOS.js 2522:19 toNumber: Argument cannot be converted toNumber; {"ind":1,"form":0,"mant":[1,4,5],"exp":-1}; line: toNumber (http://192.168.1.33:8080/openbravo/web/js/gen/deaa604bd23a43b5d3c897d9a290ea9a_WebPOS.js:10292:14 [^]) (*,+)

When in the order.js
  455: pricenet: OB.DEC.toNumber(line.get('discountedNetPrice')),

If this line is set to
  pricenet: line.get('discountedNetPrice'),

the registers are not saved in the database
(0082960)
hgbot (developer)
2015-12-23 13:04

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: d01d21eb16186a3363226779d1270d6da90f3632
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Wed Dec 16 11:55:54 2015 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/d01d21eb16186a3363226779d1270d6da90f3632 [^]

Related to issue 30771: Changes in discounts.js

---
M web/org.openbravo.retail.posterminal/js/model/discounts.js
---
(0082961)
hgbot (developer)
2015-12-23 13:04

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 5beee319e35816dbb28b801266bffe238d9ccb33
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Tue Dec 22 12:15:04 2015 +0100
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/5beee319e35816dbb28b801266bffe238d9ccb33 [^]

Fixed issue 30771: CalculateTaxes should not be executed when the receipt is
being closed

If you create a ticket with a pricelist with the taxes not included and you
reload the POS before you pay it, when you try to pay it after the reload a
javascript error is show.

The problem is that the receipt save a value as big decimal, and when is
retrieve from the local database the value is no longer a number, it's an
object.

The solution is to save the value of discountedprice as a number instead
of big decimal.

---
M web/org.openbravo.retail.posterminal/js/data/dataordertaxes.js
---

- Issue History
Date Modified Username Field Change
2015-09-04 21:43 Orekaria New Issue
2015-09-04 21:43 Orekaria Assigned To => Retail
2015-09-04 21:43 Orekaria Triggers an Emergency Pack => No
2015-09-09 18:53 Orekaria Relationship added related to 0030809
2015-09-10 12:43 Orekaria Note Added: 0080315
2015-09-15 16:03 Orekaria Note Added: 0080407
2015-09-15 16:03 Orekaria Note Edited: 0080407 View Revisions
2015-09-18 13:14 Orekaria Relationship added blocks 0030856
2015-09-18 13:14 Orekaria Relationship added blocks 0030857
2015-09-18 13:16 Orekaria Proposed Solution updated
2015-09-18 13:16 Orekaria Priority normal => urgent
2015-09-18 13:16 Orekaria Target Version RR15Q4 => RR16Q1
2015-09-19 11:14 Orekaria Relationship added blocks 0030501
2015-09-19 13:05 hgbot Checkin
2015-09-19 13:05 hgbot Note Added: 0080510
2015-09-28 13:58 egoitz Resolution time => 1445032800
2015-10-05 12:42 Orekaria Status new => acknowledged
2015-11-23 09:09 jorge-garcia Assigned To Retail => jorge-garcia
2015-12-04 13:54 Orekaria Status acknowledged => scheduled
2015-12-14 18:17 Orekaria Relationship added blocks 0030904
2015-12-14 18:18 hgbot Checkin
2015-12-14 18:18 hgbot Note Added: 0082736
2015-12-15 15:15 hgbot Checkin
2015-12-15 15:15 hgbot Note Added: 0082769
2015-12-15 15:15 hgbot Status scheduled => resolved
2015-12-15 15:15 hgbot Resolution open => fixed
2015-12-15 15:15 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/ed7f8734ef3bb2cd7eb6b310facea36835c6d9cb [^]
2015-12-15 15:15 hgbot Checkin
2015-12-15 15:15 hgbot Note Added: 0082770
2015-12-15 15:15 hgbot Checkin
2015-12-15 15:15 hgbot Note Added: 0082771
2015-12-15 15:16 hgbot Checkin
2015-12-15 15:16 hgbot Note Added: 0082772
2015-12-15 16:40 Orekaria Review Assigned To => guilleaer
2015-12-17 15:29 Orekaria Note Added: 0082833
2015-12-17 15:29 Orekaria Status resolved => new
2015-12-17 15:29 Orekaria Resolution fixed => open
2015-12-17 15:29 Orekaria Status new => scheduled
2015-12-23 13:04 hgbot Checkin
2015-12-23 13:04 hgbot Note Added: 0082960
2015-12-23 13:04 hgbot Checkin
2015-12-23 13:04 hgbot Note Added: 0082961
2015-12-23 13:04 hgbot Status scheduled => resolved
2015-12-23 13:04 hgbot Resolution open => fixed
2015-12-23 13:04 hgbot Fixed in SCM revision http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/ed7f8734ef3bb2cd7eb6b310facea36835c6d9cb [^] => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/5beee319e35816dbb28b801266bffe238d9ccb33 [^]
2015-12-24 04:55 Orekaria Review Assigned To guilleaer => Orekaria
2015-12-24 04:55 Orekaria Status resolved => closed
2015-12-24 04:55 Orekaria Fixed in Version => RR16Q1
2016-04-21 18:05 dmitry_mezentsev Relationship added causes 0032699
2016-11-22 20:09 malsasua Relationship added related to 0034600


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker