Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0057631
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Cash upmajoralways2025-01-13 16:472025-01-15 13:41
ReporteraaroncaleroView Statuspublic 
Assigned Tomigueldejuana 
PriorityurgentResolutionfixedFixed in VersionRR25Q2
StatusclosedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Merge Request Statusapproved
Review Assigned To
OBNetwork customerNo
Support ticket
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0057631: InitCashup action should not load a cashup from backoffice if the existing cashup in the state is newer

DescriptionWhen a cashup is completed in POS, a new cashup is added to the state and the closed cashup is sent to backoffice for processing. However, the closed cashup is not marked as "processed" until its import entry is processed.

If the POS performs a login before that import entry is processed, the Global.initCashup action (in one of its actionPreparations[*]) calls the backoffice and retrieves the last non-processed cashup.

In this situation, the POS finishes the login process with a cashup that is going to be processed in the server as soon as the import entry is triggered. After performing any action involving that cashup (the Open Till process, a ticket, etc), if the import entry has finished processing, an Error While Importing record will be generated for the related document.

[*] https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/blob/master/web/org.openbravo.retail.posterminal/app/model/business-object/cashup/actions/InitCashup.js#L215 [^]
Steps To ReproduceIn a development environment, set a breakpoint inside the saveRecord method of ProcessCashClose.java.

Log in POS or POS2.
Check the Cashup id in the state: OB.App.State.getState().Cashup.id
Navigate to the cashup window and complete the process. The POS will automatically log out. At the same time, the server code will be stopped on the breakpoint; leave the code paused for now.
Check the cashup id again. Verify that the id is new.
In POS, log in again.
Check the cashup id for the third time. Note that the id is the first id again.
Let the server code continue and process the cashup.
Try to complete a ticket. Verify that a record has been created in the Errors While Importing POS Data window

Proposed SolutionThe code that was added as part of previous mitigations should not try to reload the non-processed cashup from backoffice if it is detected that the creationDate of the backoffice cashup is older that the current new cashup in the state.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0056263 closedranjith_qualiantech_com Mitigation https://issues.openbravo.com/view.php?id=52070 [^] should not create a new cashup in POS 
depends on backport 0057632RR25Q1 closedmigueldejuana InitCashup action should not load a cashup from backoffice if the existing cashup in the state is newer 
depends on backport 0057633RR24Q4.1 closedmigueldejuana InitCashup action should not load a cashup from backoffice if the existing cashup in the state is newer 

-  Notes
(0174168)
hgbot (developer)
2025-01-14 16:11

Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/1872 [^]
(0174191)
hgbot (developer)
2025-01-15 13:41

Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/1872 [^]
(0174192)
hgbot (developer)
2025-01-15 13:41

Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal [^]
Changeset: cec74cfcc8fc4b80f7247b396da0f12480d38fe5
Author: miguel.dejuana <m.dejuana@orisha.com>
Date: 14-01-2025 15:11:32
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/commit/cec74cfcc8fc4b80f7247b396da0f12480d38fe5 [^]

Fixed ISSUE-57631: Use Backend Cashup only when it is newer

---
M web/org.openbravo.retail.posterminal/app/model/business-object/cashup/CashupUtils.js
---
(0174193)
hgbot (developer)
2025-01-15 13:41

Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal [^]
Changeset: cbf9f2c731259539e9fa794e2d815a41d89e7e2b
Author: miguel.dejuana <m.dejuana@orisha.com>
Date: 15-01-2025 09:09:25
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/commit/cbf9f2c731259539e9fa794e2d815a41d89e7e2b [^]

Fixed ISSUE-57631: Pass state as parameter

---
M web/org.openbravo.retail.posterminal/app/model/business-object/cashup/CashupUtils.js
M web/org.openbravo.retail.posterminal/app/model/business-object/cashup/actions/InitCashup.js
---

- Issue History
Date Modified Username Field Change
2025-01-13 16:47 aaroncalero New Issue
2025-01-13 16:47 aaroncalero Assigned To => Retail
2025-01-13 16:47 aaroncalero OBNetwork customer => No
2025-01-13 16:47 aaroncalero Triggers an Emergency Pack => No
2025-01-13 16:47 aaroncalero Status new => acknowledged
2025-01-13 16:47 aaroncalero Relationship added related to 0056263
2025-01-14 07:30 migueldejuana Assigned To Retail => migueldejuana
2025-01-14 07:31 migueldejuana Status acknowledged => scheduled
2025-01-14 16:11 hgbot Merge Request Status => open
2025-01-14 16:11 hgbot Note Added: 0174168
2025-01-15 13:41 hgbot Merge Request Status open => approved
2025-01-15 13:41 hgbot Resolution open => fixed
2025-01-15 13:41 hgbot Status scheduled => closed
2025-01-15 13:41 hgbot Note Added: 0174191
2025-01-15 13:41 hgbot Fixed in Version => RR25Q2
2025-01-15 13:41 hgbot Note Added: 0174192
2025-01-15 13:41 hgbot Note Added: 0174193


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker