Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0028886Openbravo ERPZ. Otherspublic2015-02-06 12:222015-06-11 22:43
maite 
aferraz 
urgentmajoralways
closedfixed 
5
 
3.0PR15Q3 
vmromanos
Advanced Payables and Receivables Mngmt
No
0028886: Error when registering "Refund payment" from Match Statement process
Error when registering "Refund payment" from Match Statement process
0. Configure Alimentos y Supermercados as a provider also
1. Register Payment In for Alimentos y Supermercados to generate credit for 20EUR
2. Access Cuenta de Banco financial account, register new Bank Statement header 3. Add bank statement line with amount out= 20
4. Add bank statement line with amount in= -20 and process bank statement
5. Run "Match Statement" process:
  5.1. from out line, press "+". Change transaction type to "BP Deposit" and press "+" in payment's selector.
  5.2. set again business partner (in order to load "use credit" section)
  5.3. set actual payment amount = 0.00
  5.4. select previous credit in "credit to use" section and set amount=20
  5.5. choose "Refund amount to customer" in Overpayment action
  5.6. press "done" and following error will be raised "It is not possible to add a payment of zero amount to a transaction"

Same error is raised following steps from negative in line.

Following same steps directly from Payment In window you are able to register refund payment
  

No tags attached.
related to defect 0027155 closed eduardo_Argal Cannot return the credit to a customer 
related to defect 0030085 acknowledged Triage Platform Base Action field is not shown properly in Add Payment process definition 
related to defect 0030086 scheduled AtulOpenbravo Error in the log when refunding a credit in Add Payment process 
Issue History
2015-02-06 12:22maiteNew Issue
2015-02-06 12:22maiteAssigned To => dmiguelez
2015-02-06 12:22maiteModules => Advanced Payables and Receivables Mngmt
2015-02-06 12:22maiteResolution time => 1426114800
2015-02-06 12:22maiteTriggers an Emergency Pack => No
2015-02-06 12:22maiteIssue Monitored: networkb
2015-02-06 14:09maitePriorityimmediate => urgent
2015-02-23 13:30jonalegriaesarteTarget Version3.0PR15Q2 => 3.0PR15Q3
2015-02-23 17:55reinaldoguerraAssigned Todmiguelez => reinaldoguerra
2015-02-23 17:55reinaldoguerraStatusnew => scheduled
2015-02-25 14:12reinaldoguerraNote Added: 0074912
2015-05-04 10:59umartirenaAssigned Toreinaldoguerra => Triage Finance
2015-05-04 10:59umartirenaStatusscheduled => acknowledged
2015-05-04 11:00umartirenaStatusacknowledged => scheduled
2015-05-04 11:00umartirenaStatusscheduled => feedback
2015-05-04 11:01umartirenaStatusfeedback => new
2015-06-03 17:54aferrazRelationship addedrelated to 0027155
2015-06-03 17:54aferrazAssigned ToTriage Finance => aferraz
2015-06-03 18:17aferrazNote Edited: 0074912bug_revision_view_page.php?bugnote_id=0074912#r8744
2015-06-03 18:33aferrazRelationship addedrelated to 0030085
2015-06-03 18:41aferrazRelationship addedrelated to 0030086
2015-06-03 18:42aferrazStatusnew => scheduled
2015-06-10 18:21hgbotCheckin
2015-06-10 18:21hgbotNote Added: 0078194
2015-06-10 18:21hgbotStatusscheduled => resolved
2015-06-10 18:21hgbotResolutionopen => fixed
2015-06-10 18:21hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/0e8c704992089fefcb801f3c72efc18a8413e418 [^]
2015-06-10 18:21hgbotCheckin
2015-06-10 18:21hgbotNote Added: 0078195
2015-06-10 18:22vmromanosReview Assigned To => vmromanos
2015-06-10 18:22vmromanosNote Added: 0078196
2015-06-10 18:22vmromanosStatusresolved => closed
2015-06-11 22:43hudsonbotCheckin
2015-06-11 22:43hudsonbotNote Added: 0078222
2015-06-11 22:43hudsonbotCheckin
2015-06-11 22:43hudsonbotNote Added: 0078223

Notes
(0074912)
reinaldoguerra   
2015-02-25 14:12   
(edited on: 2015-06-03 18:17)
Test plan used:

1- Login into Openbravo ERP
2- Configure Alimentos y Supermercados as a vendor also
3- Go to Payment In window and register a new record
4- Set "Alimentos y Supermercados" as Received From and set Amount = 20
5- Click on Add Details button, unselect any order or invoice and select "Leave the credit to be used later" as Overpayment Action
6- Complete the process clicking in "Done" button. This action will generate 20 EUR of credit.
7- Access "Cuenta de Banco" financial account
8- Go to Imported Bank Statements tab and create a new record named for example: Test
9- Go to Bank Statement Lines and create a new one for business partner "Alimentos y Supermercados" and amount out = 20. Enter any reference number too.
10- Add another bank statement line with amount in= -20
11- Process the Bank Statement and then Run "Match Statement" process
12- From created line with amount out defined, press "+". Change transaction type to "BP Deposit" and press "+" in payment's selector.
13- Set again business partner in order to load "use credit" section (solved with the patch for issue 28884)
14- Set actual payment amount = 0.00
15- Select previous credit in "credit to use" section and set amount=20
16- Choose "Refund amount to customer" in Overpayment action
17- Press "done" and realize that now, no error will be raised.

Repeat the same flow from the line with amount in.

Repeat also the same flow, refunding the credit from Payment In or Transaction.

Repeat also the same flow (create a credit and refund it) from Payment Out.

(0078194)
hgbot   
2015-06-10 18:21   
Repository: erp/devel/pi
Changeset: 0e8c704992089fefcb801f3c72efc18a8413e418
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Wed Jun 03 18:12:35 2015 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/0e8c704992089fefcb801f3c72efc18a8413e418 [^]

Fixes issue 28886: Error in "Refund Payment" from Match Statement

ob-aprm-addPayment.js has been changed to check if Overpayment Action field is visible in order to raise APRM_ZEROAMOUNTPAYMENTTRANSACTION or not.
AddPaymentActionHandler.java has been changed to do a commit at the end of createNewPayment method and avoid error when retrieving the created payment later.

---
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/actionHandler/AddPaymentActionHandler.java
M modules/org.openbravo.advpaymentmngt/web/org.openbravo.advpaymentmngt/js/ob-aprm-addPayment.js
---
(0078195)
hgbot   
2015-06-10 18:21   
Repository: erp/devel/pi
Changeset: 2a75107a6f00b818f78a05f48096e4ea1c975860
Author: Víctor Martínez Romanos <victor.martinez <at> openbravo.com>
Date: Wed Jun 10 18:04:18 2015 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/2a75107a6f00b818f78a05f48096e4ea1c975860 [^]

Related to issue 28886: Applied JS Beautify

---
M modules/org.openbravo.advpaymentmngt/web/org.openbravo.advpaymentmngt/js/ob-aprm-addPayment.js
---
(0078196)
vmromanos   
2015-06-10 18:22   
Code review + testing OK
(0078222)
hudsonbot   
2015-06-11 22:43   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/559a6242635c [^]
Maturity status: Test
(0078223)
hudsonbot   
2015-06-11 22:43   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/559a6242635c [^]
Maturity status: Test