Openbravo Issue Tracking System - Retail Modules
View Issue Details
0051795Retail ModulesDiscounts and Promotionspublic2023-03-07 17:532023-04-20 12:06
noemieroussel 
ranjith_qualiantech_com 
highmajoralways
closedfixed 
5
 
RR23Q3 
No
0051795: When "Apply only once" is uncheck, it is possible to add gift endlessly
When "Apply only once" is uncheck, it is possible to add gift endlessly
1. Go to the Backoffice.

2. Go to the "Discounts and Promotion" window and create a new record.

3. Select the discount type "Buy X and get Y as gift".

4. Select the subtype "Any X Any Y" and set Min X=1, Min Y=1, Max Y=1, and add the X and Y product.

5. Uncheck the box "Apply only once".

6. In the "POS Configuration", check the "Gift reminder notification" and set the application method to automatic.

7. Repete the same creation of promo with the exact same steps than steps 1-6.

8. Go to the POS and add the eligible products to trigger the promotion.

9. Add manually the gift three times: See that it is added endlessly.
No tags attached.
related to defect 0051879 closed ranjith_qualiantech_com [Promo] - Buy X Get Y - Number of gifts is multiplied by number of eligible products bought even if Max Y = 1 
Issue History
2023-03-07 17:53noemierousselNew Issue
2023-03-07 17:53noemierousselAssigned To => Retail
2023-03-07 17:53noemierousselTriggers an Emergency Pack => No
2023-03-08 09:29noemierousselSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=25645#r25645
2023-03-24 06:37ranjith_qualiantech_comAssigned ToRetail => ranjith_qualiantech_com
2023-03-24 06:37ranjith_qualiantech_comStatusnew => scheduled
2023-03-30 11:16ranjith_qualiantech_comRelationship addedrelated to 0051879
2023-04-03 11:29ranjith_qualiantech_comNote Added: 0148188
2023-04-03 11:29ranjith_qualiantech_comStatusscheduled => feedback
2023-04-04 07:31ranjith_qualiantech_comStatusfeedback => scheduled
2023-04-09 09:44ranjith_qualiantech_comNote Edited: 0148188bug_revision_view_page.php?bugnote_id=0148188#r25845
2023-04-10 07:19hgbotNote Added: 0148342
2023-04-20 11:14ranjith_qualiantech_comNote Edited: 0148188bug_revision_view_page.php?bugnote_id=0148188#r25912
2023-04-20 12:06hgbotResolutionopen => fixed
2023-04-20 12:06hgbotStatusscheduled => closed
2023-04-20 12:06hgbotNote Added: 0148627
2023-04-20 12:06hgbotFixed in Version => RR23Q3
2023-04-20 12:06hgbotNote Added: 0148628

Notes
(0148188)
ranjith_qualiantech_com   
2023-04-03 11:29   
(edited on: 2023-04-20 11:14)
Issue will not reproduced if "Apply Next Discount/Promotion" is unchecked for discounts

(0148342)
hgbot   
2023-04-10 07:19   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts/-/merge_requests/98 [^]
(0148628)
hgbot   
2023-04-20 12:06   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts [^]
Changeset: 8275db1798042399322e462e26995a049d7d17e8
Author: Ranjith S R <ranjith@qualiantech.com>
Date: 09-04-2023 12:55:39
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts/-/commit/8275db1798042399322e462e26995a049d7d17e8 [^]

Fixed ISSUE-51795: Discount amt should not exceed line gross amount
* When adding BuyYGiftY discount, Discount amt should not exceed line gross amount
  Hidden discount should not be added, when gift discount is not added

---
M web/org.openbravo.retail.discounts/app/model/business-logic/discounts-engine/engine/rules/buy-x-gift-y-discount.js
---
(0148627)
hgbot   
2023-04-20 12:06   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.discounts/-/merge_requests/98 [^]