Openbravo Issue Tracking System - Retail Modules
View Issue Details
0047948Retail ModulesDiscounts and Promotionspublic2021-10-28 18:202021-11-16 08:15
collazoandy4 
ranjith_qualiantech_com 
normalmajoralways
closedfixed 
5
 
RR22Q1 
No
0047948: Wrong User Defined Line Amount discount after C&R
If a C&R is created from a receipt which have a User Defined Line Amount discount applied the new receipt have a wrong total amount
Log in the backoffice as White Valley Group Admin role
Go to Discount and Promotions and create a new record:
  Discount promotion type: User Defined Line Amount
  Name: Line Amount Discount
  Starting date: First date of the month
Log in YS-11 Pos terminal and create a new Layway
  Product: Avalanche Transceiver
Add the previous discount created and set as final price 140
A new discount line is created with an amount of -10.50
Check the total amount of receipt is 140.0
Syncronize the Layaway to the backoffice
Open the previous receipt and Cancel and Replace it
Check the new receipt total amount is 10.50 and the discount amount is 140
If more quantity to the product is added to the line the discount amount is calculated with wrong value
No tags attached.
related to defect 0048068 closed ranjith_qualiantech_com Wrong User Defined Line Amount discount after create a Sales Order from Quotation 
Issue History
2021-10-28 18:20collazoandy4New Issue
2021-10-28 18:20collazoandy4Assigned To => Retail
2021-10-28 18:20collazoandy4Triggers an Emergency Pack => No
2021-11-09 07:05ranjith_qualiantech_comAssigned ToRetail => ranjith_qualiantech_com
2021-11-16 01:51collazoandy4Relationship addedrelated to 0048068
2021-11-16 07:05hgbotNote Added: 0133087
2021-11-16 07:05hgbotNote Added: 0133088
2021-11-16 08:15hgbotNote Added: 0133089
2021-11-16 08:15hgbotResolutionopen => fixed
2021-11-16 08:15hgbotStatusnew => closed
2021-11-16 08:15hgbotFixed in Version => RR22Q1
2021-11-16 08:15hgbotNote Added: 0133090
2021-11-16 08:15hgbotNote Added: 0133091
2021-11-16 08:15hgbotNote Added: 0133092

Notes
(0133087)
hgbot   
2021-11-16 07:05   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts/-/merge_requests/41 [^]
(0133088)
hgbot   
2021-11-16 07:05   
Merge Request created: https://gitlab.com/openbravo/ci/mobile-test/-/merge_requests/144 [^]
(0133089)
hgbot   
2021-11-16 08:15   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts/-/merge_requests/41 [^]
(0133090)
hgbot   
2021-11-16 08:15   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts [^]
Changeset: 521d90528068903d6b2146a5e8ef4fc2685d39d2
Author: Ranjith S R <ranjith@qualiantech.com>
Date: 2021-11-16T11:32:09+05:30
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts/-/commit/521d90528068903d6b2146a5e8ef4fc2685d39d2 [^]

Fixed ISSUE-47948: Updated User Defined Line Amount discount calculation
* For User Defined Line Amount Discount Type,
  Discount FinalLineGross should be updated with applied discount amount
* Discount FinalLineGross should not execeed the line gross amount

---
M src-test/org/openbravo/retail/discounts/test/unittests/DiscountUserDefinedLineAmountTest.java
M web/org.openbravo.retail.discounts/app/model/business-logic/discounts-engine/engine/rules/manual-linefinalprice-promotions-discount.js
M web/org.openbravo.retail.discounts/app/model/business-logic/discounts-engine/interface/discount-posinterface.js
---
(0133091)
hgbot   
2021-11-16 08:15   
Repository: https://gitlab.com/openbravo/ci/mobile-test [^]
Changeset: 75bc05bdc46a3c306fe097191433e6d77a3137a7
Author: Ranjith S R <ranjith@qualiantech.com>
Date: 2021-11-16T11:08:13+05:30
URL: https://gitlab.com/openbravo/ci/mobile-test/-/commit/75bc05bdc46a3c306fe097191433e6d77a3137a7 [^]

Verifies ISSUE-47948: Added Test I47948_VerifyUserDefinedLineDiscountWhenCR

---
A src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/discountsandpromotions/I47948_VerifyUserDefinedLineDiscountWhenCR.java
---
(0133092)
hgbot   
2021-11-16 08:15   
Merge request merged: https://gitlab.com/openbravo/ci/mobile-test/-/merge_requests/144 [^]