Openbravo Issue Tracking System - Retail Modules
View Issue Details
0044773Retail ModulesWeb POSpublic2020-08-10 13:242022-04-11 15:01
guillermogil 
ranjith_qualiantech_com 
urgentmajorrandom
closedfixed 
5
 
RR20Q4 
No
0044773: Delete Ticket does not wait for the CalculateReceipt execution
Delete Ticket does not wait for the CalculateReceipt execution.
It just executes the calculate receipt and it may rely on wrong data generation such as no tax.
As orderloader does not fail the Sales Order has some missing data.
As it is random we cannot ensure the steps
It just happens on standard ticket deletion
The main problem here is that in some cases, the ticket may be modified while it is being synchronised to the backend (in case the Save Removed Tickets preference is activated). This is a problem because it may cause inconsistencies in the ticket that is finally sent to the backend.

The best way to prevent the problem is to implement the same change we did for the main ticket completion mechanism. In the "markOrdersAsDeleted" function, we should clone the main receipt, and all logic related to synchronisation, like the execution of the PresyncReceipt hook and everything else, should happen against this cloned instance.

This way we will ensure that if there is any uncontrolled process trying to mutate the ticket, at least it will not influence the synchronisation process itself and the consistency of the data.
NOR
related to defect 0043481 closed ranjith_qualiantech_com Order Error Deleting Lines With SUPR key 
related to defect 0055002 closed Rajesh_18 Error when trying to change line quantity after deleting an order 
diff 44773_posterminal_19Q3.diff (5,414) 2021-01-19 09:59
https://issues.openbravo.com/file_download.php?file_id=15264&type=bug
Issue History
2020-08-10 13:24guillermogilNew Issue
2020-08-10 13:24guillermogilAssigned To => Retail
2020-08-10 13:24guillermogilResolution time => 1598824800
2020-08-10 13:24guillermogilTriggers an Emergency Pack => No
2020-08-10 14:45marvintmProposed Solution updated
2020-08-11 12:09martinsdanIssue Monitored: martinsdan
2020-08-13 15:21ranjith_qualiantech_comAssigned ToRetail => ranjith_qualiantech_com
2020-08-13 15:25ranjith_qualiantech_comStatusnew => scheduled
2020-08-17 07:15hgbotNote Added: 0122084
2020-08-18 07:34hgbotNote Added: 0122109
2020-08-18 07:35hgbotResolutionopen => fixed
2020-08-18 07:35hgbotStatusscheduled => closed
2020-08-18 07:35hgbotFixed in Version => RR20Q4
2020-08-18 07:35hgbotNote Added: 0122110
2020-09-23 15:46ngarciaRelationship addedrelated to 0043481
2020-09-23 21:30rafarodaTag Attached: NOR
2021-01-19 09:59ranjith_qualiantech_comFile Added: 44773_posterminal_19Q3.diff
2022-03-16 15:03hgbotNote Added: 0135780
2022-04-11 15:01hgbotNote Added: 0136466
2024-03-20 00:45ivazquezRelationship addedrelated to 0055002

Notes
(0122084)
hgbot   
2020-08-17 07:15   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/60 [^]
(0122109)
hgbot   
2020-08-18 07:34   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/60 [^]
(0122110)
hgbot   
2020-08-18 07:35   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal [^]
Changeset: 1e218a7c4e216328072e77f9976cba89857f463c
Author: Ranjith S R <ranjith@qualiantech.com>
Date: 2020-08-18T05:34:50+00:00
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/commit/1e218a7c4e216328072e77f9976cba89857f463c [^]

Fixed ISSUE-44773: Updated Delete Ticket Sync Process
* With Pref. Save Removed Ticket is enabled, cloned receipt should be used for Sync process to avoid any modification when syncing the receipt

---
M web/org.openbravo.retail.posterminal/js/model/order.js
---
(0135780)
hgbot   
2022-03-16 15:03   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/748 [^]
(0136466)
hgbot   
2022-04-11 15:01   
Merge request closed: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/748 [^]