Openbravo Issue Tracking System - Retail Modules
View Issue Details
0035637Retail ModulesDiscounts and Promotionspublic2017-03-29 01:422019-01-28 18:33
letcharren 
ranjith_qualiantech_com 
normalmajoralways
closedfixed 
5
RR17Q1 
RR17Q3 
marvintm
No
0035637: Check is Multiple in price Adjustment not working in Web Pos
When a discount of type price adjustment is created with the check is multiple in description, this check is not taken into account and the discount always applies
1-Enter Live builds, window Discounts and promotions
2-Create a new Discount of type price adjusment, with the check is multiple and 4 units per package
3-Enter in Web POS
4-Add a product and verify that the discount is applied despite entering a single product
No tags attached.
patch issue 35637 source posterminal 8128.patch (1,761) 2017-05-09 09:26
https://issues.openbravo.com/file_download.php?file_id=10734&type=bug
patch issue 35637 test 6520.patch (5,837) 2017-05-09 09:27
https://issues.openbravo.com/file_download.php?file_id=10735&type=bug
Issue History
2017-03-29 01:42letcharrenNew Issue
2017-03-29 01:42letcharrenAssigned To => Retail
2017-03-29 01:42letcharrenResolution time => 1492466400
2017-03-29 01:42letcharrenTriggers an Emergency Pack => No
2017-03-29 15:43ranjith_qualiantech_comAssigned ToRetail => ranjith_qualiantech_com
2017-03-29 15:43ranjith_qualiantech_comStatusnew => scheduled
2017-04-03 14:55hgbotCheckin
2017-04-03 14:55hgbotNote Added: 0095808
2017-04-05 14:38hgbotCheckin
2017-04-05 14:38hgbotNote Added: 0095847
2017-04-05 14:38hgbotStatusscheduled => resolved
2017-04-05 14:38hgbotResolutionopen => fixed
2017-04-05 14:38hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/f875959175bb584e77c5f781c34d913bc03a2301 [^]
2017-05-08 11:09marvintmNote Added: 0096451
2017-05-08 11:09marvintmStatusresolved => new
2017-05-08 11:09marvintmResolutionfixed => open
2017-05-09 09:20ranjith_qualiantech_comStatusnew => scheduled
2017-05-09 09:26ranjith_qualiantech_comFile Added: issue 35637 source posterminal 8128.patch
2017-05-09 09:27ranjith_qualiantech_comFile Added: issue 35637 test 6520.patch
2017-05-09 17:09jorge-garciaAssigned Toranjith_qualiantech_com => jorge-garcia
2017-05-12 12:29hgbotCheckin
2017-05-12 12:29hgbotNote Added: 0096556
2017-05-12 12:31hgbotCheckin
2017-05-12 12:31hgbotNote Added: 0096557
2017-05-12 12:31jorge-garciaStatusscheduled => resolved
2017-05-12 12:31jorge-garciaFixed in Version => RR17Q3
2017-05-12 12:31jorge-garciaResolutionopen => fixed
2017-05-15 12:03marvintmNote Added: 0096586
2017-05-15 12:03marvintmStatusresolved => new
2017-05-15 12:03marvintmResolutionfixed => open
2017-05-15 12:03marvintmFixed in VersionRR17Q3 =>
2017-05-15 12:04marvintmAssigned Tojorge-garcia => ranjith_qualiantech_com
2017-05-16 11:36ranjith_qualiantech_comStatusnew => scheduled
2017-05-17 11:14hgbotCheckin
2017-05-17 11:14hgbotNote Added: 0096633
2017-05-17 11:14hgbotStatusscheduled => resolved
2017-05-17 11:14hgbotResolutionopen => fixed
2017-05-17 11:14hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/f875959175bb584e77c5f781c34d913bc03a2301 [^] => http://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts/rev/44e2cc233500e7e07e77495d7379192b33acf3a3 [^]
2017-05-17 11:14hgbotCheckin
2017-05-17 11:14hgbotNote Added: 0096634
2017-05-18 12:38marvintmReview Assigned To => marvintm
2017-05-18 12:38marvintmNote Added: 0096660
2017-05-18 12:38marvintmStatusresolved => closed
2017-05-18 12:38marvintmFixed in Version => RR17Q3
2019-01-28 18:33hgbotCheckin
2019-01-28 18:33hgbotNote Added: 0109282
2019-01-28 18:33hgbotCheckin
2019-01-28 18:33hgbotNote Added: 0109287

Notes
(0095808)
hgbot   
2017-04-03 14:55   
Repository: tools/automation/pi-mobile
Changeset: 638b0d8dc0f0786472b2314af30ced23a63b7f29
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Mon Apr 03 18:20:44 2017 +0530
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/638b0d8dc0f0786472b2314af30ced23a63b7f29 [^]

Verifies issue 35637 : Added automated test 'I35637_VerifyPriceAdjWithIsMultiple'

---
A src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/discountsandpromotions/I35637_VerifyPriceAdjWithIsMultiple.java
---
(0095847)
hgbot   
2017-04-05 14:38   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: f875959175bb584e77c5f781c34d913bc03a2301
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Wed Apr 05 18:00:58 2017 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/f875959175bb584e77c5f781c34d913bc03a2301 [^]

Fixed issue 35637 : Added Discount logic for Price Adjustment

* Added Discount logic for Price Adjustment if "ismultiple" is configured

---
M web/org.openbravo.retail.posterminal/js/model/discounts.js
---
(0096451)
marvintm   
2017-05-08 11:09   
The change works correctly when the discount amount is set, but if instead a discount percentage is specified, the discount is calculated as zero, which is wrong.
(0096556)
hgbot   
2017-05-12 12:29   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 3ee0bc8f739422eb26d23e0f7c593a3f66ca2c88
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Tue May 09 17:08:57 2017 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/3ee0bc8f739422eb26d23e0f7c593a3f66ca2c88 [^]

Related to issue 35637 : Modified Discount logic for Price Adjustment IsMultiple

* Both Discount Amount & Percentage included for discount calculation if Price Adjustment "ismultiple" is configured

---
M web/org.openbravo.retail.posterminal/js/model/discounts.js
---
(0096557)
hgbot   
2017-05-12 12:31   
Repository: tools/automation/pi-mobile
Changeset: acd0e059f22966917729b2d63e15bd35a0272e4b
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Tue May 09 17:06:19 2017 +0200
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/acd0e059f22966917729b2d63e15bd35a0272e4b [^]

Verifies issue 35637 : Modified automated test 'I35637_VerifyPriceAdjWithIsMultiple'

* Added logic for discount percentage

---
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/discountsandpromotions/I35637_VerifyPriceAdjWithIsMultiple.java
---
(0096586)
marvintm   
2017-05-15 12:03   
Now it seems to be working correctly with percentage discount, but it fails with absolute amount.

We need to check both cases also in the automated test, or create a second test, whatever is better.
(0096633)
hgbot   
2017-05-17 11:14   
Repository: erp/pmods/org.openbravo.retail.discounts
Changeset: 44e2cc233500e7e07e77495d7379192b33acf3a3
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Wed May 17 14:44:05 2017 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts/rev/44e2cc233500e7e07e77495d7379192b33acf3a3 [^]

Fixes issue 35637 : Updated Event handler for m_offer table for "Price Adjustment" discount type

* In Discounts, Both Discount Percentage and Discount Amount cannot be set at same time for the discount type "Price Adjustment".

---
M src-db/database/sourcedata/AD_MESSAGE.xml
M src/org/openbravo/retail/discounts/event/MOfferEventHandler.java
---
(0096634)
hgbot   
2017-05-17 11:14   
Repository: tools/automation/pi-mobile
Changeset: 08238f4a83d4116950426ea4ae3c0cead9220435
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Wed May 17 14:43:58 2017 +0530
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/08238f4a83d4116950426ea4ae3c0cead9220435 [^]

Verifies issue 35637 : Modified automated test 'I35637_VerifyPriceAdjWithIsMultiple'

---
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/discountsandpromotions/I35637_VerifyPriceAdjWithIsMultiple.java
---
(0096660)
marvintm   
2017-05-18 12:38   
Finally both cases work correctly, and the event handler which prevents the user from specifying both absolute and percentage discount also works correctly.
(0109282)
hgbot   
2019-01-28 18:33   
Repository: erp/pmods/org.openbravo.retail.sampledata
Changeset: 094a4541c37ea086e861bb61f4a4c559435936cd
Author: Alejandro <alekosmp86 <at> gmail.com>
Date: Thu Jan 24 14:22:40 2019 -0500
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.sampledata/rev/094a4541c37ea086e861bb61f4a4c559435936cd [^]

Related to issue 35637: added sampledata for testing purposes

---
M referencedata/sampledata/The_White_Valley_Group/M_OFFER.xml
M referencedata/sampledata/The_White_Valley_Group/M_OFFER_PRODUCT.xml
---
(0109287)
hgbot   
2019-01-28 18:33   
Repository: tools/automation/pi-mobile
Changeset: e622205a4015ea8d6611f67edbf184210baa18af
Author: Alejandro <alekosmp86 <at> gmail.com>
Date: Thu Jan 24 14:24:09 2019 -0500
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/e622205a4015ea8d6611f67edbf184210baa18af [^]

Related to issue 35637: test has been refactored due to it no longer creates its
own sampledata.

---
M src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/discountsandpromotions/I35637_VerifyPriceAdjWithIsMultiple.java
---