Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0039536 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Retail Modules] Discounts and Promotions | major | always | 2018-10-25 14:02 | 2018-12-27 13:58 | |||
Reporter | inaki_garcia | View Status | public | |||||
Assigned To | ranjith_qualiantech_com | |||||||
Priority | normal | Resolution | fixed | Fixed in Version | RR19Q1 | |||
Status | closed | Fix in branch | Fixed in SCM revision | |||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | main | SCM revision | ||||||
Merge Request Status | ||||||||
Review Assigned To | marvintm | |||||||
OBNetwork customer | No | |||||||
Support ticket | ||||||||
Regression level | Packaging and release | |||||||
Regression date | 2018-01-12 | |||||||
Regression introduced in release | main | |||||||
Regression introduced by commit | https://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts.bytotal/rev/edd903ba2305#l8.75 [^] | |||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0039536: [RR18Q4] Total Amount discounts get removed when splitting lines | |||||||
Description | A ticket with a Total Amount type discount applied, which shows on all lines, gets removed when using the Split Lines feature. Said discount cannot be reapplied again unless the ticket is removed. Further observations after the steps to reproduce are executed: - Adding a product which requires providing extra contact info ("Item Declaration" popup appears) throws the following error and makes the POS unusable (check the attached "2018-10-11 13-33-09.png" screenshot and the following error log message). 'Contact customer info for product' module is required to be installed and the 'WEB POS Show BusinessPartner Birth Information' set to 'Y' to execute this step: Uncaught TypeError: discountRule.set is not a function at 2de4b76c91e46e250b8a916b152d94d1.js:3516 at Array.forEach (<anonymous>) at Function.b.each.b.forEach (underscore-1.3.3.min.js:11) at Object.manualByTotalPromotionsExecutor (2de4b76c91e46e250b8a916b152d94d1.js:3516) at Object.implementation (2de4b76c91e46e250b8a916b152d94d1.js:3516) at G.d.applyRule (2de4b76c91e46e250b8a916b152d94d1.js:1915) at G.d.nextAction (2de4b76c91e46e250b8a916b152d94d1.js:1903) at G.d.<anonymous> (2de4b76c91e46e250b8a916b152d94d1.js:1903) at g.Model.trigger (backbone-0.9.2.min.js:9) at 2de4b76c91e46e250b8a916b152d94d1.js:1912 - If another type of discount is applied (such as "Fixed Percentage Disount" type discount) for one or more lines, the Total Amount discount reappears only for that/those line(s) (check the attached "Screenshot from 2018-10-25 14-08-11.png" screenshot) | |||||||
Steps To Reproduce | Precondition: the "Discount rules for Retail by total" module is required to be installed and a Total Amount type discount configured. Use this test case in as a guide to configure a Total Amount discount: https://testlink.openbravo.com/testlink/linkto.php?tprojectPrefix=Communit&item=testcase&id=Communit-10507 [^] 0. Log into the WebPOS 1. Add some products to the ticket to insert several lines and quantities 2. Open the "Receipt disounts" popup by selecting it from the dropdown menu 3. Apply the previously created Total Amount to the ticket by selecting it and clicking on "Apply" 4. Select a line with Quantity greater than 1, and click on the "Split" option from the right pane 5. Click "Apply" on the "Split" popup 6. NOTICE that the applied discount has dissappeared from all lines Steps are reproduced in the attached video | |||||||
Tags | No tags attached. | |||||||
Attached Files | ![]() ![]() ![]() | |||||||
![]() |
|||||||||||||||
|
![]() |
|
(0108318) hgbot (developer) 2018-12-06 14:22 |
Repository: erp/pmods/org.openbravo.retail.discounts.bytotal Changeset: acc28bc9b14186d976bacb2800869861099e9483 Author: Ranjith S R <ranjith <at> qualiantech.com> Date: Thu Dec 06 18:52:12 2018 +0530 URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts.bytotal/rev/acc28bc9b14186d976bacb2800869861099e9483 [^] Related to issue 39536 : Modified Discount Per Total Amount calculation * Removed unnecessary attribute 'qtyOffer' for Disccount Per Total Amount calculation --- M web/org.openbravo.retail.discounts.bytotal/js/promotion-by-total-utils.js --- |
(0108320) hgbot (developer) 2018-12-07 04:14 |
Repository: erp/pmods/org.openbravo.retail.discounts.bytotal Changeset: 8cc9dda150f603fc151aa86a7fd8fd143ed5e740 Author: Ranjith S R <ranjith <at> qualiantech.com> Date: Fri Dec 07 08:44:18 2018 +0530 URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts.bytotal/rev/8cc9dda150f603fc151aa86a7fd8fd143ed5e740 [^] Related to issue 39536 : Backed out changeset: acc28bc9b141 --- M web/org.openbravo.retail.discounts.bytotal/js/promotion-by-total-utils.js --- |
(0108627) hgbot (developer) 2018-12-17 07:03 |
Repository: erp/pmods/org.openbravo.retail.discounts.bytotal Changeset: 8f683d71795f20e926385aa588570c0342142db4 Author: Ranjith S R <ranjith <at> qualiantech.com> Date: Mon Dec 17 11:33:18 2018 +0530 URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts.bytotal/rev/8f683d71795f20e926385aa588570c0342142db4 [^] Related to issue 39536 : Total Discounts must be applied to lines when spliting it * Discount attribute 'qtyOffer' was set to 0 to support Multi Discount. Same attribute was used in applying discount while spliting the lines. So new attrbiute 'pendingQtyOffer' added to discountRule which is used in applying discounts while spliting lines --- M web/org.openbravo.retail.discounts.bytotal/js/promotion-by-total-utils.js --- |
(0108628) hgbot (developer) 2018-12-17 09:08 |
Repository: erp/pmods/org.openbravo.retail.posterminal Changeset: f8aece110f2c41b624c6d6139b69ce6ce3d2eaf5 Author: Ranjith S R <ranjith <at> qualiantech.com> Date: Mon Dec 17 13:38:14 2018 +0530 URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/f8aece110f2c41b624c6d6139b69ce6ce3d2eaf5 [^] Related to issue 39536 : Discounts must be splited proportionally to lines when splitting it * For Mutli Discounts functionality, discountRule attribute 'qtyOffer' can be zero. To split the discounts, new discountRule attribute 'pendingQtyOffer' must be used for spliitng discounts. --- M web/org.openbravo.retail.posterminal/js/model/order.js --- |
(0108629) hgbot (developer) 2018-12-17 09:08 |
Repository: tools/automation/pi-mobile Changeset: aa9f3edc74d33b3d30dd2a20b555b55c3d10fae6 Author: Ranjith S R <ranjith <at> qualiantech.com> Date: Mon Dec 17 13:37:59 2018 +0530 URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/aa9f3edc74d33b3d30dd2a20b555b55c3d10fae6 [^] Verifies issue 39536 : Added Test 'I39536_VerifyTotalDiscountWithSplitLines' --- M src-test/org/openbravo/test/mobile/retail/extmodules/selenium/TestIdExtModules.java A src-test/org/openbravo/test/mobile/retail/extmodules/selenium/tests/discounts_bytotal/I39536_VerifyTotalDiscountWithSplitLines.java --- |
(0108631) ranjith_qualiantech_com (viewer) 2018-12-17 10:29 |
Regression introduced due to Muti Discounts Logic. Discount Rule attribute "qtyOffer" has been set as zero for Multi Discount support, but it was used in Split Lines functionality |
(0108727) marvintm (viewer) 2018-12-24 09:46 |
Main case is now working fine. However, I still see a problem in products which have an automatic discount applied: - Add 6 units of "Bottle 1L". This will automatically add two discounts of 3x2 Bottles - Add manual discount "Fixed percentage discount by total 23%" - Select the line and split it in two lines. The 23% discount will disappear |
(0108768) marvintm (viewer) 2018-12-27 13:56 |
The behaviour is now better than before, as discounts are no longer always lost when splitting the line. However, there is a specific case that is still failing, which will be fixed in a separate issue. |
![]() |
|||
Date Modified | Username | Field | Change |
2018-10-25 14:02 | inaki_garcia | New Issue | |
2018-10-25 14:02 | inaki_garcia | Assigned To | => Retail |
2018-10-25 14:02 | inaki_garcia | OBNetwork customer | => No |
2018-10-25 14:02 | inaki_garcia | Triggers an Emergency Pack | => No |
2018-10-25 14:04 | inaki_garcia | File Added: ScreenRecording 2018-10-25 at 13.01.54.avi | |
2018-10-25 14:06 | inaki_garcia | File Added: 2018-10-11 13-33-09.png | |
2018-10-25 14:08 | inaki_garcia | File Added: Screenshot from 2018-10-25 14-08-11.png | |
2018-10-25 14:09 | inaki_garcia | Description Updated | View Revisions |
2018-10-25 14:10 | inaki_garcia | Description Updated | View Revisions |
2018-10-25 14:11 | inaki_garcia | Description Updated | View Revisions |
2018-11-23 11:03 | ranjith_qualiantech_com | Assigned To | Retail => ranjith_qualiantech_com |
2018-11-23 11:04 | ranjith_qualiantech_com | Status | new => scheduled |
2018-12-06 14:22 | ranjith_qualiantech_com | Regression level | => Packaging and release |
2018-12-06 14:22 | ranjith_qualiantech_com | Regression date | => 2018-01-12 |
2018-12-06 14:22 | ranjith_qualiantech_com | Regression introduced in release | => main |
2018-12-06 14:22 | ranjith_qualiantech_com | Regression introduced by commit | => https://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts.bytotal/rev/edd903ba2305#l8.75 [^] |
2018-12-06 14:22 | hgbot | Checkin | |
2018-12-06 14:22 | hgbot | Note Added: 0108318 | |
2018-12-07 04:14 | hgbot | Checkin | |
2018-12-07 04:14 | hgbot | Note Added: 0108320 | |
2018-12-07 04:36 | ranjith_qualiantech_com | Regression level | Packaging and release => |
2018-12-07 04:36 | ranjith_qualiantech_com | Regression date | 2018-01-12 => |
2018-12-07 04:36 | ranjith_qualiantech_com | Regression introduced in release | main => |
2018-12-07 04:36 | ranjith_qualiantech_com | Regression introduced by commit | https://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts.bytotal/rev/edd903ba2305#l8.75 [^] => |
2018-12-17 07:03 | hgbot | Checkin | |
2018-12-17 07:03 | hgbot | Note Added: 0108627 | |
2018-12-17 09:08 | hgbot | Checkin | |
2018-12-17 09:08 | hgbot | Note Added: 0108628 | |
2018-12-17 09:08 | hgbot | Checkin | |
2018-12-17 09:08 | hgbot | Note Added: 0108629 | |
2018-12-17 10:29 | ranjith_qualiantech_com | Regression level | => Packaging and release |
2018-12-17 10:29 | ranjith_qualiantech_com | Regression date | => 2018-01-12 |
2018-12-17 10:29 | ranjith_qualiantech_com | Regression introduced in release | => main |
2018-12-17 10:29 | ranjith_qualiantech_com | Regression introduced by commit | => https://code.openbravo.com/erp/pmods/org.openbravo.retail.discounts.bytotal/rev/edd903ba2305#l8.75 [^] |
2018-12-17 10:29 | ranjith_qualiantech_com | Note Added: 0108631 | |
2018-12-17 10:29 | ranjith_qualiantech_com | Status | scheduled => resolved |
2018-12-17 10:29 | ranjith_qualiantech_com | Resolution | open => fixed |
2018-12-24 09:46 | marvintm | Note Added: 0108727 | |
2018-12-24 09:46 | marvintm | Status | resolved => new |
2018-12-24 09:46 | marvintm | Resolution | fixed => open |
2018-12-26 08:37 | ranjith_qualiantech_com | Status | new => scheduled |
2018-12-27 13:55 | marvintm | Status | scheduled => resolved |
2018-12-27 13:55 | marvintm | Fixed in Version | => RR19Q1 |
2018-12-27 13:55 | marvintm | Resolution | open => fixed |
2018-12-27 13:56 | marvintm | Review Assigned To | => marvintm |
2018-12-27 13:56 | marvintm | Note Added: 0108768 | |
2018-12-27 13:56 | marvintm | Status | resolved => closed |
2018-12-27 13:58 | marvintm | Relationship added | related to 0039858 |
2019-01-28 07:22 | ranjith_qualiantech_com | Relationship added | related to 0040007 |
Copyright © 2000 - 2009 MantisBT Group |