Openbravo Issue Tracking System - Retail Modules |
View Issue Details |
|
ID | Project | Category | View Status | Date Submitted | Last Update |
0055258 | Retail Modules | Retail API | public | 2024-04-08 11:14 | 2024-04-23 09:10 |
|
Reporter | gorkaion | |
Assigned To | Rajesh_18 | |
Priority | high | Severity | major | Reproducibility | always |
Status | closed | Resolution | fixed | |
Platform | | OS | 5 | OS Version | |
Product Version | | |
Target Version | RR24Q2 | Fixed in Version | | |
Merge Request Status | |
Review Assigned To | |
OBNetwork customer | |
Support ticket | |
Regression level | |
Regression date | |
Regression introduced in release | |
Regression introduced by commit | |
Triggers an Emergency Pack | No |
|
Summary | 0055258: Consume Coupons API returns a 500 error when the coupon is consumed |
Description | When the Coupons API is called with a coupon that it is already consumed the response has 500 status. The expected result is a 2XX status with an error message since the call has not fail technically. |
Steps To Reproduce | 1. Create a coupon in backend for a single use.
2. Check using the API that the coupon code is available using /org.openbravo.api.ExportService/Coupon/byCouponCode
3. Consume the coupon using /ws/org.openbravo.retail.discounts.coupons.api.ConsumeCoupon the response is 2XX
4. Check again the coupon and notice the coupon is already used.
5. Try to consume again the coupon using the ConsumeCoupon api, notice that the response is a 500 error. This is wrong, status should be 2XX with a message indicating that the coupon is already expired/consumed/... |
Proposed Solution | change the response status to 2XX |
Additional Information | |
Tags | No tags attached. |
Relationships | blocks | defect | 0055120 | | closed | Rajesh_18 | Consume Coupons API returns a 500 error when the coupon is consumed |
|
Attached Files | |
|
Issue History |
Date Modified | Username | Field | Change |
2024-04-19 08:12 | marvintm | Type | defect => backport |
2024-04-19 08:12 | marvintm | Target Version | => RR24Q2 |
2024-04-23 08:46 | hgbot | Note Added: 0163559 | |
2024-04-23 09:10 | hgbot | Note Added: 0163569 | |
2024-04-23 09:10 | hgbot | Resolution | open => fixed |
2024-04-23 09:10 | hgbot | Status | scheduled => closed |
2024-04-23 09:10 | hgbot | Note Added: 0163570 | |