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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0052664
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POSmajoralways2023-06-05 12:352023-06-14 13:06
ReporterngarciaView Statuspublic 
Assigned Toranjith_qualiantech_com 
PriorityurgentResolutionfixedFixed in VersionRR23Q3
StatusclosedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned To
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0052664: Cash Up in Errors While Importing POS Data cannot be saved again if the amount counted is higher than the amount to keep

DescriptionCash Up in Errors While Importing POS Data cannot be saved again if the amount counted is higher than the amount to keep.

The problem seems to be in the associateTransactions of CashCloseProcessor class
Steps To ReproduceUsed 23Q2 as I was not able to log in in newest versions:
https://livebuilds.openbravo.com/context/pos2_mp_23Q2 [^]

In the backoffice:

In Open/Close Period, select current period (jun-23) and Close period

In the POS:
https://livebuilds.openbravo.com/context/pos2_mp_23Q2/web/org.openbravo.retail.posterminal/?terminal=VBS-1 [^]

Add a product and pay it with Cash
Do a cash up:
Count more cash than the expected one (higher than 200)
Select 200 as the amount to keep

In the backoffice:
Check the order is stuck in Errors While Importing POS Data with the following error:
The Period does not exist or it is not opened

Check the cash up is stuck with the following error
There are errors related to non-created customers, orders, or cash management movements pending to be processed. Process them before processing the cash ups

Check you are logged in with * Organization

In Open/Close Period, select current period (jun-23) and Open period

In Errors While Importing POS Data, Save Again the order
Try to Save Again the cash-up and check the following error is shown:

org.openbravo.base.exception.OBException: Couldn't enable triggers:
    at org.openbravo.dal.core.TriggerHandler.enable(TriggerHandler.java:98)
    at org.openbravo.retail.posterminal.ProcessCashClose.doReconciliationAndInvoices(ProcessCashClose.java:507)
    at org.openbravo.retail.posterminal.ProcessCashClose.saveRecord(ProcessCashClose.java:189)
    ...
Caused by: javax.persistence.OptimisticLockException: Batch update returned unexpected row count from update [0]; actual row count: 0; expected: 1; statement executed: update FIN_Finacc_Transaction set AD_Client_ID=?, AD_Org_ID=?, Created=?, Createdby=?, Updated=?, Updatedby=?, Isactive=?, C_Currency_ID=?, Fin_Financial_Account_ID=?, Line=?, Fin_Payment_ID=?, DateAcct=?, C_Glitem_ID=?, Status=?, Paymentamt=?, Depositamt=?, Processed=?, Processing=?, Posted=?, C_Project_ID=?, C_Campaign_ID=?, C_Activity_ID=?, User1_ID=?, User2_ID=?, Trxtype=?, Statementdate=?, Description=?, FIN_Reconciliation_ID=?, CreatedByAlgorithm=?, Foreign_Currency_ID=?, Foreign_Convert_Rate=?, Foreign_Amount=?, C_Bpartner_ID=?, M_Product_ID=?, C_Salesregion_ID=?, C_Costcenter_ID=?, EM_Aprm_Processed=?, EM_Obpos_App_Cashup_ID=?, EM_Aprm_Finacc_Trans_Origin=? where Fin_Finacc_Transaction_ID=?
...
Caused by: org.hibernate.StaleStateException: Batch update returned unexpected row count from update [0]; actual row count: 0; expected: 1; statement executed: update FIN_Finacc_Transaction set AD_Client_ID=?, AD_Org_ID=?, Created=?, Createdby=?, Updated=?, Updatedby=?, Isactive=?, C_Currency_ID=?, Fin_Financial_Account_ID=?, Line=?, Fin_Payment_ID=?, DateAcct=?, C_Glitem_ID=?, Status=?, Paymentamt=?, Depositamt=?, Processed=?, Processing=?, Posted=?, C_Project_ID=?, C_Campaign_ID=?, C_Activity_ID=?, User1_ID=?, User2_ID=?, Trxtype=?, Statementdate=?, Description=?, FIN_Reconciliation_ID=?, CreatedByAlgorithm=?, Foreign_Currency_ID=?, Foreign_Convert_Rate=?, Foreign_Amount=?, C_Bpartner_ID=?, M_Product_ID=?, C_Salesregion_ID=?, C_Costcenter_ID=?, EM_Aprm_Processed=?, EM_Obpos_App_Cashup_ID=?, EM_Aprm_Finacc_Trans_Origin=? where Fin_Finacc_Transaction_ID=?
...

Change the login organization to the touchpoint's organization and check the Cashup can be saved again properly
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
causes defect 0053493 closedranjith_qualiantech_com Cash up is not stuck in Errors While Importing POS Data but it is not set as isprocessedbo if it has an existing reconciliation 

-  Notes
(0151129)
hgbot (developer)
2023-06-14 07:26

Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/1243 [^]
(0151149)
hgbot (developer)
2023-06-14 13:06

Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/1243 [^]
(0151150)
hgbot (developer)
2023-06-14 13:06

Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal [^]
Changeset: faabbb8d7b63d358a3f032d02bbcee51471532a3
Author: Ranjith S R <ranjith@qualiantech.com>
Date: 14-06-2023 10:49:31
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/commit/faabbb8d7b63d358a3f032d02bbcee51471532a3 [^]

Fixed ISSUE-52664: Organization property should be added when creating cashup

---
M src/org/openbravo/retail/posterminal/ProcessCashClose.java
M web/org.openbravo.retail.posterminal/app/model/business-object/cashup/actions/CompleteCashupAndCreateNew.js
M web/org.openbravo.retail.posterminal/js/closecash/model/cashup/cashup-model.js
---

- Issue History
Date Modified Username Field Change
2023-06-05 12:35 ngarcia New Issue
2023-06-05 12:35 ngarcia Assigned To => Retail
2023-06-05 12:35 ngarcia Triggers an Emergency Pack => No
2023-06-13 14:47 ranjith_qualiantech_com Assigned To Retail => ranjith_qualiantech_com
2023-06-14 07:26 hgbot Note Added: 0151129
2023-06-14 13:06 hgbot Note Added: 0151149
2023-06-14 13:06 hgbot Resolution open => fixed
2023-06-14 13:06 hgbot Status new => closed
2023-06-14 13:06 hgbot Fixed in Version => RR23Q3
2023-06-14 13:06 hgbot Note Added: 0151150
2023-09-25 12:15 ranjith_qualiantech_com Relationship added causes 0053493


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker