Openbravo Issue Tracking System - Retail Modules
View Issue Details
0051371Retail ModulesSessionspublic2023-01-16 08:342023-01-17 11:04
caristu 
caristu 
highminorhave not tried
closedfixed 
5
 
 
No
0051371: Reasons and approvals info is persisted twice for the initial count user action
Having the sessions module installed, the reasons and approvals information is persisted twice
Having the sessions module installed:

1) Configure Open till user action to request reason and/or approval
2) Navigate to terminal organization and configure initial count difference limit to 30
3) Open the POS2 application
4) Execute a transaction with amount greater than 30 and pay it with cash
5) Go to the main menu and execute cashup
6) Let as cashup keeped an amount greater than 30
7) Finish cashup
8) Open the terminal and on initial count let expected amount as 0
7) Insert supervisor credentials to process the requested approval
8) Finish initial count
8) Go to the main manu and process the cashup again
9) Go to the backoffice, navigate to the Cashup History window and switch to the Approval/Reason History tab, note the the approval/reason information is duplicated (there are two records for the same initial count)
No tags attached.
related to feature request 0051249 closed njimenez POS2 Action Reasons in Open till and Cashup with differences 
Issue History
2023-01-16 08:34caristuNew Issue
2023-01-16 08:34caristuAssigned To => caristu
2023-01-16 08:34caristuTriggers an Emergency Pack => No
2023-01-16 08:35caristuSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=25392#r25392
2023-01-16 08:35caristuRelationship addedrelated to 0051249
2023-01-16 08:48hgbotNote Added: 0145437
2023-01-16 12:17hgbotResolutionopen => fixed
2023-01-16 12:17hgbotStatusnew => closed
2023-01-16 12:17hgbotNote Added: 0145450
2023-01-16 12:17hgbotNote Added: 0145451
2023-01-17 11:00njimenezSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=25401#r25401
2023-01-17 11:04njimenezSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=25402#r25402

Notes
(0145437)
hgbot   
2023-01-16 08:48   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.sessions/-/merge_requests/65 [^]
(0145450)
hgbot   
2023-01-16 12:17   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.sessions [^]
Changeset: 03791616900e33417100bad3ddadc1e3b67ac19d
Author: Carlos Aristu <carlos.aristu@openbravo.com>
Date: 16-01-2023 12:13:26
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.sessions/-/commit/03791616900e33417100bad3ddadc1e3b67ac19d [^]

fixes BUG-51371: Reasons and approvals persisted twice for the initial count

  When invoking the open till user action as a post hook of the initial
count user action, it was reusing the payload generated for the initial
count which contains the reasons and approvals user action.

  This caused that the reasons and approvals information was being added
twice by the state hook which eventually caused the information to be
persisted duplicated in the backoffice.

  To avoid this, we avoid passing the payload in the openTill function
used by the posthook, and just invoke the user action with an empty
payload. Note that this should not have any effect, as the openTill
state action does not use any information coming from the payload.

  If in the future the openTill state action needs information coming
from the payload it should be explicititly included in this openTill
function, instead of passing an empty object.

---
M web-jspack/org.openbravo.retail.sessions/src/model/till/TillUtils.js
M web-jspack/org.openbravo.retail.sessions/src/model/till/user-actions/OpenTill.js
---
(0145451)
hgbot   
2023-01-16 12:17   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.sessions/-/merge_requests/65 [^]