Openbravo Issue Tracking System - Retail Modules
View Issue Details
0044646Retail ModulesLoyalty Programs for Web POSpublic2020-07-21 12:552020-08-24 11:20
prakashmurugesan88 
prakashmurugesan88 
normalmajoralways
closedfixed 
5
 
RR20Q4 
marvintm
No
0044646: Unable to remove added redemption points in webpos if 'org.openbravo.retail.testsampledata' module is not installed
Unable to remove added redemption points in webpos if 'org.openbravo.retail.testsampledata' module is not installed

* Seems this is because in CancelGiftCertificateAmount.java MANUAL_EARN_RULE_ID is hardcoded
* This id will not exists if testsampledata module is not installed
Prepare 20Q1 environment without testsampledata module.
For eg:(Pack + Loyalty Modules)

Loyalty Modules:
org.openbravo.retail.loyalty.programs -> version 1.0.400
org.openbravo.retail.loyalty.burn.giftcertificate -> 1.0.100
org.openbravo.loyalty.programs -> 1.0.100
org.openbravo.loyalty.earn.buyxearny -> 1.0.0
org.openbravo.loyalty.burn.giftcertificate -> 1.0.100
org.openbravo.loyalty.burn.expired -> 1.0.100
org.openbravo.retail.giftcards-> 1.3.1300

1. Configure the loyalty program in the Backend http://wiki.openbravo.com/wiki/Projects:Loyalty_Programs/User_Guide [^]
2. Login into Web POS
3. Add a customer who is subscribed to a loyalty program.
4. Add a product.
5. Click on total receipt.
6. Confirm that we want to redeem the points.
7. Try to remove the added points.
No tags attached.
patch FixesRedeemPointsRemovalIssue.patch (3,042) 2020-07-22 05:19
https://issues.openbravo.com/file_download.php?file_id=14795&type=bug
Issue History
2020-07-21 12:55prakashmurugesan88New Issue
2020-07-21 12:55prakashmurugesan88Assigned To => prakashmurugesan88
2020-07-21 12:55prakashmurugesan88Triggers an Emergency Pack => No
2020-07-21 12:59prakashmurugesan88Steps to Reproduce Updatedbug_revision_view_page.php?rev_id=21380#r21380
2020-07-22 05:19prakashmurugesan88File Added: FixesRedeemPointsRemovalIssue.patch
2020-08-03 16:10prakashmurugesan88Issue Monitored: Leyre
2020-08-14 07:17LeyreResolution time => 1599170400
2020-08-14 07:17LeyreReproducibilityhave not tried => always
2020-08-21 11:03prakashmurugesan88Statusnew => scheduled
2020-08-24 06:16hgbotNote Added: 0122271
2020-08-24 07:25hgbotNote Added: 0122273
2020-08-24 07:25hgbotNote Added: 0122274
2020-08-24 07:25marvintmStatusscheduled => resolved
2020-08-24 07:25marvintmFixed in Version => RR20Q4
2020-08-24 07:25marvintmResolutionopen => fixed
2020-08-24 07:25marvintmReview Assigned To => marvintm
2020-08-24 07:25marvintmStatusresolved => closed
2020-08-24 11:12hgbotNote Added: 0122280
2020-08-24 11:20hgbotNote Added: 0122283
2020-08-24 11:20hgbotNote Added: 0122284

Notes
(0122271)
hgbot   
2020-08-24 06:16   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.loyalty.burn.giftcertificate/-/merge_requests/4 [^]
(0122273)
hgbot   
2020-08-24 07:25   
Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.loyalty.burn.giftcertificate [^]
Changeset: 5304c1629d22002e3cf6d2f7f6be105557e43efa
Author: Prakash <prakash@qualiantech.com>
Date: 2020-08-23T14:17:32+05:30
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.loyalty.burn.giftcertificate/-/commit/5304c1629d22002e3cf6d2f7f6be105557e43efa [^]

Related to ISSUE-44646: Unable to remove added redeem loyalty points when all module sample data is not
installed (org.openbravo.retail.testsampledata)

* This is because of foreign key violation of Earn Rule
* In class CancelGiftCertificateAmount, MANUAL_EARN_RULE_ID is hardcoded
* This id will not exists if testsampledata module is not installed

* Instead of hardcoded earn rule id, fetched earn rule using subscription's category
and manual rule id

---
M src/org/openbravo/retail/loyalty/burn/giftcertificate/process/CancelGiftCertificateAmount.java
---
(0122274)
hgbot   
2020-08-24 07:25   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.loyalty.burn.giftcertificate/-/merge_requests/4 [^]
(0122280)
hgbot   
2020-08-24 11:12   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.loyalty.burn.giftcertificate/-/merge_requests/5 [^]
(0122283)
hgbot   
2020-08-24 11:20   
Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.loyalty.burn.giftcertificate [^]
Changeset: dcd1ae838ae78bc1a63b8135ec4f45b4dee43a5e
Author: Prakash M <prakash@qualiantech.com>
Date: 2020-08-24T14:38:59+05:30
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.loyalty.burn.giftcertificate/-/commit/dcd1ae838ae78bc1a63b8135ec4f45b4dee43a5e [^]

Related to BUG-44646: Removed unused imports and fixes try warnings

---
M src/org/openbravo/retail/loyalty/burn/giftcertificate/process/CancelGiftCertificateAmount.java
---
(0122284)
hgbot   
2020-08-24 11:20   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.loyalty.burn.giftcertificate/-/merge_requests/5 [^]