Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0033666Openbravo ERP09. Financial managementpublic2016-08-10 09:332018-02-22 17:21
malsasua 
nonofrancisco 
immediateminoralways
closedfixed 
5
 
3.0PR16Q4 
aferraz
Core
Production - Confirmed Stable
2016-01-13
3.0PR16Q2
https://code.openbravo.com/erp/devel/pi/rev/27ef13611fff [^]
No
0033666: when adding a payment in match statement, the actual payment is 0, and it should be the transaction amount
when a new payment is created, from match statement process, in the payment form, the actual payment is 0 and it should be the transaction amount
in f&b
. go to financial account: Bank - Account 1
 . tab: imported bank statement
   . new record
     new bank statement line
         BP: Be Soft Drinker, Inc.
         Amount out: 100
    . process bank statement
 . click in match statement process. Press "Cancel". Previous bank statement line is displayed
   . click in "add new transaction" -> add new transaction form is displayed
   . click in "add new payment" -> add payment form is displayed:
     the "actual payment" field should be 100 but it is 0
No tags attached.
related to defect 0033465 closed markmm82 Invoice amount not populated when running Add Payment from Add Transaction from Match Statement process 
related to defect 00293923.0PR15Q3 closed umartirena Bank Statement Line amount should be maintained when registering payment out from Match statement process 
related to defect 00291243.0PR15Q2 closed Sandrahuguet It is not possible to create Payment Out document from "match statement" window 
related to defect 0028755 closed Sandrahuguet It is not possible "leaving credit to be used later" when adding a payment in match statement. 
depends on backport 00337143.0PR16Q3.2 closed nonofrancisco when adding a payment in match statement, the actual payment is 0, and it should be the transaction amount 
depends on backport 00337153.0PR16Q2.3 closed nonofrancisco when adding a payment in match statement, the actual payment is 0, and it should be the transaction amount 
caused by defect 0031392 closed AtulOpenbravo It is not possible to match positive bank statement line against negative purchase invoice from Match Statement process 
Issue History
2016-08-10 09:33malsasuaNew Issue
2016-08-10 09:33malsasuaAssigned To => Triage Finance
2016-08-10 09:33malsasuaModules => Core
2016-08-10 09:33malsasuaResolution time => 1471212000
2016-08-10 09:33malsasuaRegression level => Production - Confirmed Stable
2016-08-10 09:33malsasuaTriggers an Emergency Pack => No
2016-08-11 12:34aferrazRelationship addedrelated to 0033465
2016-08-11 12:35aferrazRelationship addedrelated to 0031392
2016-08-11 12:37aferrazRelationship addedrelated to 0029392
2016-08-11 12:37aferrazRelationship addedrelated to 0029124
2016-08-11 12:37aferrazRelationship addedrelated to 0028755
2016-08-12 14:34aferrazAssigned ToTriage Finance => nonofrancisco
2016-08-12 14:45aferrazRegression date => 2016-01-13
2016-08-12 14:45aferrazRegression introduced in release => 3.0PR16Q2
2016-08-12 14:45aferrazRegression introduced by commit => https://code.openbravo.com/erp/devel/pi/rev/27ef13611fff [^]
2016-08-12 14:45aferrazRelationship deletedrelated to 0031392
2016-08-12 14:45aferrazRelationship addedcaused by 0031392
2016-08-15 14:51nonofranciscoStatusnew => scheduled
2016-08-17 12:26psanjuanSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=12847#r12847
2016-08-17 12:27psanjuanNote Added: 0089177
2016-08-17 13:38psanjuanNote Added: 0089181
2016-08-17 13:53psanjuanNote Edited: 0089181bug_revision_view_page.php?bugnote_id=0089181#r12849
2016-08-17 14:13psanjuanNote Edited: 0089181bug_revision_view_page.php?bugnote_id=0089181#r12850
2016-08-17 14:19psanjuanNote Edited: 0089181bug_revision_view_page.php?bugnote_id=0089181#r12851
2016-08-17 14:58psanjuanNote Edited: 0089181bug_revision_view_page.php?bugnote_id=0089181#r12852
2016-08-17 15:35psanjuanNote Added: 0089185
2016-08-29 15:19hgbotCheckin
2016-08-29 15:19hgbotNote Added: 0089509
2016-08-29 15:19hgbotStatusscheduled => resolved
2016-08-29 15:19hgbotResolutionopen => fixed
2016-08-29 15:19hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/380dc747bc6418d6ed54b31921bf55e9424bcd3a [^]
2016-08-29 15:21aferrazReview Assigned To => aferraz
2016-08-29 15:21aferrazNote Added: 0089510
2016-08-29 15:21aferrazStatusresolved => closed
2016-08-29 15:21aferrazFixed in Version => 3.0PR16Q4
2016-08-29 21:02hudsonbotCheckin
2016-08-29 21:02hudsonbotNote Added: 0089520
2016-09-05 13:12hgbotCheckin
2016-09-05 13:12hgbotNote Added: 0089753
2016-09-15 17:58nonofranciscoNote Edited: 0089181bug_revision_view_page.php?bugnote_id=0089181#r13122
2016-09-20 17:47nonofranciscoNote Added: 0090121
2016-09-26 15:40hgbotCheckin
2016-09-26 15:40hgbotNote Added: 0090266
2016-09-26 15:43hgbotCheckin
2016-09-26 15:43hgbotNote Added: 0090268
2018-02-22 17:21hgbotCheckin
2018-02-22 17:21hgbotNote Added: 0102604

Notes
(0089177)
psanjuan   
2016-08-17 12:27   
Issue verified.
(0089181)
psanjuan   
2016-08-17 13:38   
(edited on: 2016-09-15 17:58)
Test Plan

Test Case 1 - Financial Account / Transaction tab / Withdrawal Amount = 0.00

In F&B, go to financial account: F&B España - Cuenta de Banco.
Go to transaction tab. Create a new record.
Select BP Withdrawal. Leave Withdrawal Amount = 0.00
Go to Payment field and press on (+). Add a Payment.
Check that Actual Payment Amount = 0.00.
Select more than 1 invoices.
Check that Actual Payment = Expected Payment = 4.967.05 for instance.
Unselect the Invoices. Press Cancel.

Test Case 2 - Financial Account / Transaction tab / Withdrawal Amount <> 0.00

In F&B, go to financial account: F&B España - Cuenta de Banco.
Go to transaction tab. Create a new record.
Select BP Withdrawal. Enter a withdrawal Amount = 500.00
Go to Payment field and press on (+). Add a Payment.
Check that Actual Payment Amount = 500.00
Select Bebidas Alegres BP and select 1 invoice.
Check that Actual Payment = 500.00 while Expected Payment = 4.967.05 (Outstanding Invoice Amount) for instance.
Unselect the Invoices. Press Cancel.

Test Case 3 - Financial Account / Transaction tab / Withdrawal Amount <> 0.00 + Leave as credit

In F&B, go to financial account: F&B España - Cuenta de Banco.
Go to transaction tab. Create a new record.
Select BP Withdrawal. Enter a withdrawal Amount = 500.00
Go to Payment field and press on (+). Add a Payment.
Check that Actual Payment Amount = 500.00
Select SI Rapid BP as this BP has an invoice amount = 145.20. Select it.
Check that Actual Payment = 500.00 while Expected Payment = 145.20
Go down and check it is possible to leave the credit amount to be used later.
Unselect the Invoices. Press Cancel.

Test Case 4 - Financial Account / Imported Bank Statements / Withdrawal Amount = 0,00

In F&B, go to financial account: F&B España - Cuenta de Banco.
Go to Imported bank statement. Create a new record dated on today's date (ie. 17-08-2016). Enter "Test 04" as Name. Save.
Go to Bank Statement Lines tab and create a new one with below setup:
Business Partner: Bebidas Alegres.
Amount Out = 0.00
Reference Nº = Test 04
Process.
Go to Match Statement and press Cancel.
Check that bank statement line is displayed with an amount = 0.00
Press (+) to Add a new transaction.
In Add New Transaction window select BP Withdrawal. Check Withdrawal Amount = 0.00.
In payment field Press (+) to Add a new payment.
Check that Actual Payment = Expected Payment = 0.00
Select an invoice.
Check that Actual Payment = Expected Payment = Invoice outstanding amount.
Press Done.
Check that Withdrawal amount is updated with Actual Payment Amount. Press Done.


Test Case 5 - Financial Account / Imported Bank Statements / Withdrawal Amount <> 0,00

Go to purchase invoice window. Enter a purchase invoice for F&B España, Bebidas Alegres BP for an amount = 658.24 for instance.

In F&B, go to financial account: F&B España - Cuenta de Banco.
Go to Imported bank statement. Create a new record dated on tomorrow's date (ie. 18-08-2016). Enter "Test 05" as Name. Save.
Go to Bank Statement Lines tab and create a new one with below setup:
Business Partner: Bebidas Alegres.
Amount Out = 500.00
Reference Nº = Test 05
Process.
Go to Match Statement and press Cancel.
Check that bank statement line is displayed with an amount = -500.00
Press (+) to Add a new transaction.
In Add New Transaction window check BP Withdrawal is selected with a Withdrawal Amount = 500.00
In payment field Press (+) to Add a new payment.
Check that Actual Payment = Expected Payment = 500.00
Select the invoice previously created
Check that Actual Payment = 500.00 while Expected Payment = 658.24
Press Done.

Test Case 6 - Financial Account / Imported Bank Statements / Withdrawal Amount <> 0,00 + leave as credit.

Go to purchase invoice window. Enter a purchase invoice for F&B España, Bebidas Alegres BP for an amount = 49.37 for instance.

In F&B, go to financial account: F&B España - Cuenta de Banco.
Go to Imported bank statement. Create a new record dated on day after tomorrow's date (ie. 19-08-2016). Enter "Test 06" as Name. Save.
Go to Bank Statement Lines tab and create a new one with below setup:
Business Partner: Bebidas Alegres.
Amount Out = 500.00
Reference Nº = Test 06
Process.
Go to Match Statement and press Cancel.
Check that bank statement line is displayed with an amount = -500.00
Press (+) to Add a new transaction.
In Add New Transaction window check BP Withdrawal is selected with a Withdrawal Amount = 500.00
In payment field Press (+) to Add a new payment.
Select the invoice previously created
Check that Actual Payment = 500.00 while Expected Payment = 49.37
Check you can select to leave the credit to be used later.
Press Done. Verify a payment out for 500.00 has been created with a credit amount = 450.63.

Test Case 7 - Financial Account / Imported Bank Statements / Withdrawal Amount <> 0,00 + it is possible to pay more than withdrawal amount.

Go to purchase invoice window. Enter a purchase invoice for F&B España, Bebidas Alegres BP for an amount = 158.24 for instance.

In F&B, go to financial account: F&B España - Cuenta de Banco.
Go to Imported bank statement. Create a new record dated on 20-08-2016.
Enter "Test 07" as Name. Save.
Go to Bank Statement Lines tab and create a new one with below setup:
Business Partner: Bebidas Alegres.
Amount Out = 5.00
Reference Nº = Test 07
Process.
Go to Match Statement and press Cancel.
Check that bank statement line is displayed with an amount = -5.00
Press (+) to Add a new transaction.
In Add New Transaction window check BP Withdrawal is selected with a Withdrawal Amount = 5.00
In payment field Press (+) to Add a new payment.
Select the invoice previously created. Enter a amount = 158.24
Check that Actual Payment = Expected Payment = 158.24.
Press Done.
Check Withrawal amount is updated with value 158.24 in Add Transaction window

(0089185)
psanjuan   
2016-08-17 15:35   
Verified issues related as well.

Issue can be code reviewed and closed.
(0089509)
hgbot   
2016-08-29 15:19   
Repository: erp/devel/pi
Changeset: 380dc747bc6418d6ed54b31921bf55e9424bcd3a
Author: Nono Carballo <nonofce <at> gmail.com>
Date: Tue Aug 16 14:44:35 2016 -0400
URL: http://code.openbravo.com/erp/devel/pi/rev/380dc747bc6418d6ed54b31921bf55e9424bcd3a [^]

Fixes issue 33666: Zero amount instead of withdrawal amount in Add Payment

When creating a payment out with Add Payment process in Financial Account window (from Transaction tab or Match Statement | Add Transaction process), actual payment will be loaded with withdrawal amount.
If transaction withdrawal amount is different than 0, actual payment will be loaded with withdrawal amount but will not be distributed into order/invoices in the grid. If total amount is lower than withdrawal amount, actual payment will not be updated with total amount and we will be able to leave the difference between withdrawal amount and total amount as credit. If total amount is higher than withdrawal amount, actual payment will be updated with total amount and we will be able to pay more amount than withdrawal amount.
If transaction withdrawal amount is 0, actual payment will always be updated with total amount and it will not be possible to generate credit in this payment.

We have reverted changes done in ob-aprm-addPayment.js for issues 33465 and 31392, and we will retrieve bslamount as deposit amount - withdrawal amount also in Transaction tab, as it is done in Add Transaction process.
With this, opening Add Payment from both Transaction tab and Add Transaction process, will have the same behavior as it used to when opening from Add Transaction process in 16Q1 (before fixing issue 31392).

---
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/filterexpression/TransactionAddPaymentDefaultValues.java
M modules/org.openbravo.advpaymentmngt/web/org.openbravo.advpaymentmngt/js/ob-aprm-addPayment.js
---
(0089510)
aferraz   
2016-08-29 15:21   
Code review + Testing OK
(0089520)
hudsonbot   
2016-08-29 21:02   
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/bc86301d6ff4 [^]
Maturity status: Test
(0089753)
hgbot   
2016-09-05 13:12   
Repository: tools/automation/int
Changeset: 47c28ed3178a38309035f78f1498776b341a7c3b
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Mon Aug 29 10:58:07 2016 +0200
URL: http://code.openbravo.com/tools/automation/int/rev/47c28ed3178a38309035f78f1498776b341a7c3b [^]

Related to issue 33666: Fix APRTransaction010 & APRTransaction011 tests

---
M src-test/com/openbravo/test/integration/erp/modules/functionalteam/addpayment/testsuites/APR_TransactionRefactor/APRTransaction010.java
M src-test/com/openbravo/test/integration/erp/modules/functionalteam/addpayment/testsuites/APR_TransactionRefactor/APRTransaction011.java
---
(0090121)
nonofrancisco   
2016-09-20 17:47   
Test Cases in Test Link

URL: https://testlink.openbravo.com/testlink/linkto.php?tprojectPrefix=Communit&item=testcase&id=Communit-10187 [^]
URL: https://testlink.openbravo.com/testlink/linkto.php?tprojectPrefix=Communit&item=testcase&id=Communit-10188 [^]
(0090266)
hgbot   
2016-09-26 15:40   
Repository: tools/automation/int
Changeset: 48ceeffc88e701b68d3960764052f6a6c4514da3
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Mon Aug 29 10:58:07 2016 +0200
URL: http://code.openbravo.com/tools/automation/int/rev/48ceeffc88e701b68d3960764052f6a6c4514da3 [^]

Related to issue 33666: Fix APRTransaction010 & APRTransaction011 tests

---
M src-test/com/openbravo/test/integration/erp/modules/functionalteam/addpayment/testsuites/APR_TransactionRefactor/APRTransaction010.java
M src-test/com/openbravo/test/integration/erp/modules/functionalteam/addpayment/testsuites/APR_TransactionRefactor/APRTransaction011.java
---
(0090268)
hgbot   
2016-09-26 15:43   
Repository: tools/automation/int
Changeset: a78fefedc818f9694033b24ddeaa64f737a71ac6
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Mon Aug 29 10:58:07 2016 +0200
URL: http://code.openbravo.com/tools/automation/int/rev/a78fefedc818f9694033b24ddeaa64f737a71ac6 [^]

Related to issue 33666: Fix APRTransaction010 & APRTransaction011 tests

---
M src-test/com/openbravo/test/integration/erp/modules/functionalteam/addpayment/testsuites/APR_TransactionRefactor/APRTransaction010.java
M src-test/com/openbravo/test/integration/erp/modules/functionalteam/addpayment/testsuites/APR_TransactionRefactor/APRTransaction011.java
---
(0102604)
hgbot   
2018-02-22 17:21   
Repository: tools/automation/int
Changeset: 5b20ec29a7c7a1d4fe75f43e761b17dfdcabc68b
Author: Nono Carballo <nonofce <at> gmail.com>
Date: Tue Sep 20 11:01:34 2016 -0400
URL: http://code.openbravo.com/tools/automation/int/rev/5b20ec29a7c7a1d4fe75f43e761b17dfdcabc68b [^]

Related to issue 33666: Added some automated tests

---
M src-test/com/openbravo/test/integration/erp/data/selectors/PaymentSelectorData.java
M src-test/com/openbravo/test/integration/erp/modules/client/application/gui/selectors/PaymentSelector.java
M src-test/com/openbravo/test/integration/erp/modules/functionalteam/addpayment/testsuites/APR_TransactionRefactor/APRTransaction005.java
M src-test/com/openbravo/test/integration/erp/modules/functionalteam/addpayment/testsuites/APR_TransactionRefactor/APRTransaction010.java
---