Openbravo Issue Tracking System - Retail Modules | ||||||||||||
View Issue Details | ||||||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | |||||||
0027904 | Retail Modules | Web POS | public | 2014-10-17 14:33 | 2015-01-15 19:27 | |||||||
Reporter | naiaramartinez | |||||||||||
Assigned To | mario_castello | |||||||||||
Priority | normal | Severity | major | Reproducibility | have not tried | |||||||
Status | closed | Resolution | fixed | |||||||||
Platform | OS | 5 | OS Version | |||||||||
Product Version | ||||||||||||
Target Version | Fixed in Version | pi | ||||||||||
Merge Request Status | ||||||||||||
Review Assigned To | Orekaria | |||||||||||
OBNetwork customer | ||||||||||||
Support ticket | ||||||||||||
Regression level | ||||||||||||
Regression date | ||||||||||||
Regression introduced in release | ||||||||||||
Regression introduced by commit | ||||||||||||
Triggers an Emergency Pack | No | |||||||||||
Summary | 0027904: Weird behaviour in lines when executing preorderSave hook and it stops the synchronization | |||||||||||
Description | When the shyncronziation is stopped (using args.cancellation=true in PreOrderSave Hook), and trying to continue with the synchronization of the order... the lines that were in the order are not taken into account, and the price of those lines become 0. | |||||||||||
Steps To Reproduce | PreorderSave hook is used to validate the data of the lines. Imagine, when selling 'gift cards and vouchers' before saving and creating the instance of the GC/Voucher, it is nice to have a validation to check if the ID is in used for another GC/Voucher or not. In the case of the ID is in used for another GC/Voucher, the synchronization should be stopped, the user should change the ID of the voucher and user should be able to continue with the synchronization. But this behaviour is not working correctly. Steps to reproduce: Install 'gift cards and vouchers' module, and apply the patch is attached to the issue. Login as 'The White Valley Group Admin'. Go to Products and select 'Alpine skiing backpack 27 L'. Open it in form view and modify the following information: - gift Card Type: Gift voucher - Grouped Product: No Login in the webPOs and create a new order. Add 'Alpine skiing backpack 27 L' to the order. In the popup write in ID field: 1 Pay and complete the order. Now, open the develpers tool and uncomment the following code: // gcids.push({ // gcid: '1' // }); The previous code is adding the code 1 to the list of ids to check in the backend if it is already in use. Since we create a voucher with id 1, now that the code is uncommented, the preOrderSave won't do the synchronization with the backend. Create a new order. Add 'Alpine skiing backpack 27 L' and in the ID write something different to 1 (in the previous code is already writing 1). Pay it and see that an error is shown because the id 1 is already in use. Notice that 'Done' button is disabled (this could be another issue). Then, click again in the line and notice that 'done' button is enabled again. Click in 'Done' button and notice that the price of 'Alpine skiing backpack 27 L', the tax amount, the total amount... all of them are 0. Using this hook, we should be able to fix the data (in this case the ID of the voucher) and be able to process the order, but there is a bug that is not allowing to continue with the process. | |||||||||||
Proposed Solution | ||||||||||||
Additional Information | ||||||||||||
Tags | No tags attached. | |||||||||||
Relationships |
| |||||||||||
Attached Files | PreOrderSaveHookError.diff (10,402) 2014-10-17 14:33 https://issues.openbravo.com/file_download.php?file_id=7390&type=bug | |||||||||||
Issue History | ||||||||||||
Date Modified | Username | Field | Change | |||||||||
2014-10-17 14:33 | naiaramartinez | New Issue | ||||||||||
2014-10-17 14:33 | naiaramartinez | Assigned To | => marvintm | |||||||||
2014-10-17 14:33 | naiaramartinez | File Added: PreOrderSaveHookError.diff | ||||||||||
2014-10-17 14:33 | naiaramartinez | Triggers an Emergency Pack | => No | |||||||||
2015-01-09 19:37 | mario_castello | Assigned To | marvintm => mario_castello | |||||||||
2015-01-09 19:37 | mario_castello | Status | new => scheduled | |||||||||
2015-01-09 19:37 | mario_castello | fix_in_branch | => pi | |||||||||
2015-01-12 16:29 | malsasua | Relationship added | related to 0027864 | |||||||||
2015-01-13 15:15 | hgbot | Checkin | ||||||||||
2015-01-13 15:15 | hgbot | Note Added: 0073460 | ||||||||||
2015-01-13 15:15 | hgbot | Status | scheduled => resolved | |||||||||
2015-01-13 15:15 | hgbot | Resolution | open => fixed | |||||||||
2015-01-13 15:15 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/f2e1ff005d0ddc043bc30043c06a141f917651f0 [^] | |||||||||
2015-01-15 19:27 | Orekaria | Review Assigned To | => Orekaria | |||||||||
2015-01-15 19:27 | Orekaria | Status | resolved => closed | |||||||||
2015-01-15 19:27 | Orekaria | Fixed in Version | => pi |
Notes | |||||
|
|||||
|
|