Openbravo Issue Tracking System - Retail Modules
View Issue Details
0037048Retail ModulesWeb POSpublic2017-10-10 18:402017-11-22 14:59
marvintm 
jorge-garcia 
normalmajoralways
closedfixed 
5
 
RR18Q1 
marvintm
No
0037048: Synchronized mode doesn't work correctly when a new payment method is created
When using the Web POS, the application automatically creates a new cashup if there is no cashup open for a terminal. This functionality contains logic which is able to detect automatically if a new payment method was activated for a terminal, and it's able to create a new "PaymentMethodCashup" record for it.

The logic is also able to detect if a new payment method was added after the cashup was created, and in this case it's also able to create a new "PaymentMethodCashup" record for it.

However, this second part doesn't work correctly when using synchronized mode, because the cashup information is always refreshed from the backend every time a ticket is created, and the cashup in the backend doesn't yet have the information for this payment method. This leads to problems if a new payment method is enabled in the Web POS while already having a cashup created.
-Activate Synchronized Mode.
- Login in the Web POS (this will create a cashup, or retrieve the existing cashup).
- Enable a new payment method for the terminal you are working on.
- Refresh the browser (F5). Realise that a new "PaymentMethodCashup" record was created for this cashup and payment method. This is correct.
- Create a new ticket and complete it. This will trigger the "rebuildCashupFromServer" function, and this will delete the PaymentMethodCashup record we just created. This is wrong.
The rebuildCashupFromServer function should keep (or at least regenerate) the record for the missing payment methods after it has loaded everything from the backend.
No tags attached.
Issue History
2017-10-10 18:40marvintmNew Issue
2017-10-10 18:40marvintmAssigned To => Retail
2017-10-10 18:40marvintmTriggers an Emergency Pack => No
2017-10-10 18:41marvintmResolution time => 1508796000
2017-10-18 13:33jorge-garciaAssigned ToRetail => jorge-garcia
2017-10-26 16:46jorge-garciaStatusnew => scheduled
2017-10-27 08:24hgbotCheckin
2017-10-27 08:24hgbotNote Added: 0100086
2017-10-27 08:24hgbotStatusscheduled => resolved
2017-10-27 08:24hgbotResolutionopen => fixed
2017-10-27 08:24hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/961a91100a2f13a395738aadcc29847143a67332 [^]
2017-10-27 13:07marvintmReview Assigned To => marvintm
2017-10-27 13:07marvintmStatusresolved => closed
2017-10-27 13:07marvintmFixed in Version => RR18Q1
2017-11-22 14:59hgbotCheckin
2017-11-22 14:59hgbotNote Added: 0100667

Notes
(0100086)
hgbot   
2017-10-27 08:24   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 961a91100a2f13a395738aadcc29847143a67332
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Thu Oct 26 16:39:15 2017 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/961a91100a2f13a395738aadcc29847143a67332 [^]

Fixed issue 37048: Synchronized mode doesn't work correctly when a new
payment method is created

The solution is to include those cashup payment methods saved in the
local database.

---
M web/org.openbravo.retail.posterminal/js/utils/cashUpReportUtils.js
---
(0100667)
hgbot   
2017-11-22 14:59   
Repository: tools/automation/pi-mobile
Changeset: 648a6245d6226c0e6688e624b70aaa83e25c08ed
Author: Alejandro <alekosmp86 <at> gmail.com>
Date: Wed Nov 22 08:59:31 2017 -0500
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/648a6245d6226c0e6688e624b70aaa83e25c08ed [^]

Verifies issue 37048: Synchronized mode doesn't work correctly when a new payment
method is created

---
A src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/cashup/I37048_VerifyPaymentMethodCashupInSyncMode.java
---