View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0007100 | OXID eShop (all versions) | 1.02. Price calculations (discounts, coupons, additional costs etc.) | public | 2020-02-21 17:08 | 2021-04-27 08:57 |
Reporter | nitin.singh | ||||
Priority | normal | Severity | minor | Reproducibility | always |
Status | acknowledged | Resolution | open | ||
Product Version | 6.1.2 | ||||
Target Version | Fixed in Version | ||||
Summary | 0007100: voucher doesn't work in case same voucher number been used for multiple voucherseries | ||||
Description | We had one use case where customer used some voucher number for multiple voucherseries and one voucherseries got expired and second voucherseries is still live. Then, if you use related voucher then it doesn't work and give you error. | ||||
Steps To Reproduce | Added by QA - SG - : 1. Add Serie "Test 1" with code "test" 2. Add Serie "Test 2" with code "test" 3. Set Test 1 to be deactivated 4. the code "test" won't be accepted. | ||||
Tags | No tags attached. | ||||
Theme | Not defined | ||||
Browser | Not defined | ||||
PHP Version | Not defined | ||||
Database Version | Not defined | ||||
|
We have fixed this issue with attached patch. oxps_patches_oxvoucher.php (6,329 bytes) |
|
For me personally it is more a bug to allow the same code to be used. If both series are active, how can the shop know with series should be assigned? Therefore to prevent such behavior, I recommend forbidding usage of the same code. QA - SG - |
|
Sorry, QA, but that makes not much sense. This is a bug that should be fixed. Marketing stuff like coupon codes is often handled by external and changing service providers and they won't keep lists or check those of predecessors. If you believe using the same code again is bad style then please fix the bug by providing the user with a warning. |
|
Dear kukulcan, that there is a issue software side, i acknowledge. therefore the bug was set to status acknowledged and not to the status closed, so it will be fixed and the whole issue will be solved in the future. Best Regards QA -SG- |
|
Thanks for the clarification, QA. @nitin.singh - The supposed patch does not work if vouchers have no start and no end date. I think it should be: $sQ .= " and ({$sSeriesViewName}.oxenddate >= NOW() OR {$sSeriesViewName}.oxenddate IS NULL)"; |
|
@kukulcan - Thanks for noticing edge case. OXENDDATE field is not null but having default value '0000-00-00 00:00:00'. So, i think you can write query like this. $sQ .= " and ({$sSeriesViewName}.oxenddate >= NOW() OR {$sSeriesViewName}.oxenddate = '0000-00-00 00:00:00')"; Field Type: `OXENDDATE` datetime NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT 'Valid to' |