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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0036090
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Modules] Cash VAT Managementmajoralways2017-05-24 16:422017-06-08 17:12
ReportermaiteView Statuspublic 
Assigned ToAtulOpenbravo 
PriorityurgentResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revisionf7bca35786a1
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Regression date
Regression introduced by commit
Regression level
Review Assigned Toaferraz
Regression introduced in release
Summary

0036090: Wrong Business Partner Balance when non paid cash vat invoice is voided

DescriptionWhen a non-paid invoice is voided, zero payment is automatically created. In case invoice is set as cash vat, Current Balance field in business partner window is updated twice so final balance is wrong.
Steps To Reproduce0. Check Current Balance for any business partner
1. Register Sales Invoice for this bp. Add line and Complete invoice
2. Check that Current Balance has been increased with invoice's amount
3. Void invoice (zero payment has been automatically created)
4. Check that Current Balance has not changed, which is wrong as it should has been descreased

NOTE: if you enable "fully audit" functionality for business partner table you can see that field is updated 2 times when voiding, which seems to be root cause of problem
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0097031)
AtulOpenbravo (developer)
2017-05-30 18:49

Test Plan

- Check Current Balance for any business partner.
- Register Sales Invoice for this business partner. Add line and Complete invoice
- Check that Current Balance has been increased with invoice's amount.
- Void invoice (zero payment has been automatically created).
- Check that Current Balance is decreased with reversed invoice amount.


- Register Sales Invoice for above business partner. Add line and complete invoice.
- Check that current balance has been increased by invoice amount.
- Reactivate the invoice.
- Check that current balance has been decreased by invoice amount.
- Complete the invoice again.
- Check that current balance has been increased by invoice amount.
- Add Payment with full amount of the invoice.
- Check that current balance has been decreased by the paid amount.


- Register Sales Invoice for above business partner. Add line and complete invoice.
- Check that current balance has been increased by invoice amount.
- Add Payment with partial amount against invoice.
- Check that current balance has been decreased by the paid partial amount.
- Reactivate and delete the Payment.
- Check that current balance has been increased by the partial amount of the deleted payment.
(0097033)
AtulOpenbravo (developer)
2017-05-30 18:59

Test Plan

- Enable Reverse Payment button in Payment In Header.
- Register Sales Invoice for above business partner. Add line and complete invoice.
- Check that current balance has been increased by invoice amount.
- Add Payment with full amount against invoice.
- Check that current balance has been decreased by the paid amount.
- Reverse the Payment In created.
- Check that current balance has been increased by reversed payment amount.
(0097047)
hgbot (developer)
2017-05-31 12:48

Repository: erp/devel/pi
Changeset: f7bca35786a1d56820c2ca301624fc30f55f9d60
Author: Atul Gaware <atul.gaware <at> openbravo.com>
Date: Tue May 30 22:32:28 2017 +0530
URL: http://code.openbravo.com/erp/devel/pi/rev/f7bca35786a1d56820c2ca301624fc30f55f9d60 [^]

Fixes issue 36090: Wrong BP balance when non paid cash vat invoice is voided

creditUsed in updateCustomerCredit method in FIN_PaymentProcess
is not the updated usedcredit of business partner after processing
the reverse invoice created in void process. In order to get correct
value, business partner object is refreshed. Doing refresh was not
enough as in the case of dummy payment has +ve and -ve payment details,
updateCustomerCredit is called twice first time decreases invoice amount
(+ve) and second time decreases (-ve) reversed invoice amount. Net effect
is nullified. So after first call flush is needed to save values to
database.

---
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/process/FIN_PaymentProcess.java
---
(0097048)
aferraz (manager)
2017-05-31 12:48

Code review + Testing OK
(0097225)
hudsonbot (developer)
2017-06-08 17:12

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/fda0f16ab470 [^]
Maturity status: Test

- Issue History
Date Modified Username Field Change
2017-05-24 16:42 maite New Issue
2017-05-24 16:42 maite Assigned To => Triage Finance
2017-05-24 16:42 maite Resolution time => 1497391200
2017-05-24 16:42 maite Issue Monitored: networkb
2017-05-25 16:51 aferraz Assigned To Triage Finance => AtulOpenbravo
2017-05-30 07:22 AtulOpenbravo Status new => scheduled
2017-05-30 18:49 AtulOpenbravo Note Added: 0097031
2017-05-30 18:59 AtulOpenbravo Note Added: 0097033
2017-05-31 12:48 hgbot Checkin
2017-05-31 12:48 hgbot Note Added: 0097047
2017-05-31 12:48 hgbot Status scheduled => resolved
2017-05-31 12:48 hgbot Resolution open => fixed
2017-05-31 12:48 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/f7bca35786a1d56820c2ca301624fc30f55f9d60 [^]
2017-05-31 12:48 aferraz Review Assigned To => aferraz
2017-05-31 12:48 aferraz Note Added: 0097048
2017-05-31 12:48 aferraz Status resolved => closed
2017-06-08 17:12 hudsonbot Checkin
2017-06-08 17:12 hudsonbot Note Added: 0097225


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker