Openbravo Issue Tracking System - POS2
View Issue Details
0057356POS2Fashionpublic2024-12-03 17:172025-02-06 20:45
philippe_mui 
Bimla_vm 
highmajoralways
closedfixed 
5
 
 
No
0057356: RM-19593 Pos 2: promotions wrongly configured block the access to the WebPOS
This was supposed to be solved with https://issues.openbravo.com/view.php?id=52618 [^] but it is still KO in 24Q4.

https://openbravo.atlassian.net/browse/RM-19593 [^]

When we configure a promotion wrongly, the expected behavior is to have an error message in Back Office when activating a promotion where a mandatory filter is missing (for Combo for example, the error occurs when there is no record registered in Family subtab), but not in the WEBPOS.

If I configure a promotion with an error or a missing filter, I should still be able to log in to WebPOS and do a sale, and the promotion that is not correctly set up will not be available.

We need to know which configuration can cause this blocking error.
Go to the backoffice

Create a new record in "Discounts and Promotions" : a Combo promotion without adding family. Set it as active.

Try to enter in the WebPOS. -> POS can't be opened

Then, go to the backoffice and deactivate the promotion.

Go to the POS and refresh, see that POS is now accesible.

Go to the backoffice and activate the promotion.

Go to the POS and refresh, see that POS is now unaccesible.
I combos module add an eventObserver for discounts entity to ensure that a correct configuration is done when a discount type combo is created/modified.

We should changes how disocunts validation rules works. Instead of showing a blocking popup, the POS should startup normally but those discounts which are not passing the validation successfully should be de-activated in the frontend.

A yellow bubble message should appear informing to the casier that "Discount XXX is not active because --validation explanation--"

FASH
Issue History
2024-12-03 17:17philippe_muiNew Issue
2024-12-03 17:17philippe_muiAssigned To => Retail
2024-12-03 17:17philippe_muiTriggers an Emergency Pack => No
2024-12-03 17:17philippe_muiTag Attached: FASH
2024-12-04 14:51guilleaerAssigned ToRetail => guilleaer
2024-12-04 14:51guilleaerStatusnew => acknowledged
2024-12-05 07:14Bimla_vmAssigned Toguilleaer => Bimla_vm
2024-12-05 07:14Bimla_vmStatusacknowledged => scheduled
2025-01-20 17:36guilleaerProposed Solution updated
2025-01-29 13:30hgbotNote Added: 0174853
2025-02-06 20:45hgbotNote Added: 0175241
2025-02-06 20:45hgbotResolutionopen => fixed
2025-02-06 20:45hgbotStatusscheduled => closed
2025-02-06 20:45hgbotNote Added: 0175242

Notes
(0174853)
hgbot   
2025-01-29 13:30   
Merge Request created: https://gitlab.com/orisha-group/bu-commerce/openbravo/product/pmods/org.openbravo.retail.discounts.combo/-/merge_requests/71 [^]
(0175241)
hgbot   
2025-02-06 20:45   
Merge request merged: https://gitlab.com/orisha-group/bu-commerce/openbravo/product/pmods/org.openbravo.retail.discounts.combo/-/merge_requests/71 [^]
(0175242)
hgbot   
2025-02-06 20:45   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/orisha-group/bu-commerce/openbravo/product/pmods/org.openbravo.retail.discounts.combo [^]
Changeset: 95eb046fbe349f9f93943067f5334980ab62881f
Author: Bimla V Mayavan <b.mayavan@external.orisha.com>
Date: 06-02-2025 19:45:15
URL: https://gitlab.com/orisha-group/bu-commerce/openbravo/product/pmods/org.openbravo.retail.discounts.combo/-/commit/95eb046fbe349f9f93943067f5334980ab62881f [^]

Fixed ISSUE-57356: Wrong combo confg does not block pos usage

---
A src/org/openbravo/retail/discounts/combo/event/DiscountEventHandler.java
M src-db/database/sourcedata/AD_MESSAGE.xml
M web-jspack/org.openbravo.retail.discounts.combo/src/ob-init.js
R src/org/openbravo/retail/discounts/combo/master/DiscountComboValidation.java
---