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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0034301
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] Z. Othersmajoralways2016-10-26 10:022016-12-16 18:38
ReportermaiteView Statuspublic 
Assigned Tomarkmm82 
PriorityurgentResolutionfixedFixed in Version3.0PR17Q1
StatusclosedFix in branchFixed in SCM revision3b0fb57e7fed
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Toaferraz
Web browser
ModulesAdvanced Payables and Receivables Mngmt
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0034301: "Set new currency" process error when converting credit already generated in multicurrency payment

Description"Set new currency" process error when converting credit already generated in multicurrency payment
Steps To Reproduce1. Access Financial Account window, create new record for "España" organization, currency=FJD. Add "Transferencia" in Payment Method tab
2. Register new Payment Out document for "Bebidas alegres" using "Transferencia" payment method, financial account previously created, currency=EUR, rate=5 and generated credit=100. Process payment
3. Access "Bebidas alegres" business partner and run "Set new currency" process. Set FJD currency, uncheck option "use default rate" and set rate=18. Select any gl item and run
4. Access Payment Out window again and realize that:
  4.1) Payment Generating credit in FJD currency has "Paid (Financial Account)"=500, when it should be 1800 as it is not multicurrency
  4.2) Payment when amount is refunded (negative one) has negative amount (-100) but positive "Paid (Financial Account)" amount (500 when it should also be negative)
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0033977 closedmarkmm82 "Set new currency" process is not converting credit properly when more than one credit payment exists for this business partner 

-  Notes
(0091343)
markmm82 (developer)
2016-11-10 20:20
edited on: 2016-11-14 13:09

Test Plan

Go to Business Partner window and create a new one.
  Organization = F&B España - Región Norte
  Search Key = Name = BPC
  BP Category = Supplier
Go to Vendor/Creditor tab and fill the fields with following information:
  Purchase Pricelist = Tarifa Bebidas Alegres
  PO Payment Method = Transferencia
  PO Payment Terms = 30 Days
  PO Financial Account = Cuenta de Banco
Go to Location/Address tab and create a new entry for any Spain region.
Access Financial Account window, create new header:
  Organization = F&B España, S.A
  Name = FA_FJD
  Currency=FJD.
Add "Transferencia" in Payment Method tab, ensure you check the "Make Payments in Multiple Currencies" within the Payment Out section.
Go to Payment Out window and register a document
  Business Partner = previously created bp ("BPC")
  Payment method = "Transferencia"
  Financial Account = previously created (FA_FJD)
  Currency = EUR
  Rate = 5
  Generated credit = 100.
Notice Paid (Financial Account) field is recalculated and is shown 500 = (Generated credit * conversion rate) = 100 * 5
Process payment
Go back to new created BP and notice the balance is updated to 100 EUR.
Run "Set new currency" process. with the following configuration:
  Set FJD currency,
  Uncheck option "use default rate" and set rate=18.
  Select any gl item
Run
Notice the balance is updated to 1800 FJD
Access Payment Out window again, refresh and realize that:
  Payment Generating credit in FJD currency has "Paid (Financial Account)"=1800, as it is not multicurrency
  Payment when amount is refunded (negative one) has negative amount (-100) and negative "Paid (Financial Account)" amount = -500
It is correct.

(0091404)
psanjuan (manager)
2016-11-11 15:14
edited on: 2016-11-14 12:29

Issue verified.

(0091448)
psanjuan (manager)
2016-11-14 12:53
edited on: 2016-11-14 13:19

Test Plan:

Test Case 1
Go to Business Partner window and create a new one.
Organization = F&B España
Search Key = Name = Supplier FJD
BP Category = Supplier

Go to Vendor/Creditor tab and fill the fields with following information:
Purchase Pricelist = Tarifa Bebidas Alegres (in EUR)
PO Payment Method = Transferencia
PO Payment Terms = 30 Days
PO Financial Account = Cuenta de Banco

Go to Location/Address tab and create a new entry for any Spain region.

Access Financial Account window, create a new financial account
Organization = F&B España, S.A
Name = FA_FJD
Currency= FJD

Add "Transferencia" in Payment Method tab, ensure you check "Make Payments in Multiple Currencies" within the Payment Out section.

Ensure you also check "Receive Payment in Multiple Currencies" within the Payment In section.


Go to Payment Out window and show the column "Paid (Financial Account)".
Create a new payment out for F&B España, Supplier FJD business partner, with below information:
Payment method = "Transferencia"
Financial Account = previously created (FA_FJD)
Currency = EUR
Rate = 5
Generated credit = 100.00 (EUR).

Notice that "Paid (Financial Account)" field is recalculated to 500 = (Generated credit * conversion rate) = 100 * 5

Press Add Details and the Done.

Go back to the new created BP, Supplier FJD, and notice that is balance is updated to 100 EUR.

Run "Set new currency" process. with the following configuration:
Set FJD currency,
Uncheck option "use default rate" and enter a rate = 18.
Select any gl item

Run the process.

Notice the balance is updated to 1800 FJD

Go to Payment Out window again, refresh and realize that there are three new payments created for the supplier "Supplier FJD":

(1) Credit consumption payment related to the GL Item selected (Currency Conversion) in EUR for a paid amount of 100.00 at an Exchange Rate = 5 and a Paid (Financial Account ) 500.00

(2) Refunded of payment above for -100.00 paid amount and -500.00 Paid (Financial Account ) Amount.

(3) 0.00 amount Credit payment in FJD with a Generated Credit 1800.00 Paid Amount 1800.00 and -1800.00 = 0.00; and a Paid (Financial Account ) amount = 1800.00. Status Payment Made.

Test Case 2

Repeat same test for a customer and a payment in.

Test Case 3

Repeat same test as abover for a supplier and for a customer, by generating Credit in the same currency of the financial Account (EUR). After that run Set New Currency Process and verify that the 0.00 Amount credit payment is generated for 1800.00 Received (Financial Account) or Paid (Financial account); in case the conversion rate used while running set new currency process is 18 and the initial credit in EUR amount is 100.00

(0091452)
psanjuan (manager)
2016-11-14 13:13
edited on: 2016-11-14 13:16

Test plan above verified.

Issue can be code reviewed and closed.

(0091453)
hgbot (developer)
2016-11-14 13:26

Repository: erp/devel/pi
Changeset: 3b0fb57e7fed324c6e4efb57a4c5657a1fa08e90
Author: Mark <markmm82 <at> gmail.com>
Date: Thu Nov 10 14:12:42 2016 -0500
URL: http://code.openbravo.com/erp/devel/pi/rev/3b0fb57e7fed324c6e4efb57a4c5657a1fa08e90 [^]

Fixes issue 34301: "Set new currency" process fixed if multicurrency payment

When converting credit already generated in multicurrency payment "Set new
currency" process, generated entries was incorrect.
It includes:
- Update the "Paid (Financial Account)" amount field to be negated just its
  amount is the case.
- Updated the "Paid (Financial Account)" with the generatedCredit amount to
  Payment Generating credit in the new currency as it will be not multicurrency.

---
M src/org/openbravo/common/actionhandler/SetNewBPCurrency.java
---
(0091454)
aferraz (manager)
2016-11-14 13:27

Code review OK
(0092615)
hudsonbot (developer)
2016-12-16 18:38

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

- Issue History
Date Modified Username Field Change
2016-10-26 10:02 maite New Issue
2016-10-26 10:02 maite Assigned To => Triage Finance
2016-10-26 10:02 maite Modules => Advanced Payables and Receivables Mngmt
2016-10-26 10:02 maite Triggers an Emergency Pack => No
2016-10-26 10:02 maite Relationship added related to 0033977
2016-10-26 11:08 aferraz Assigned To Triage Finance => markmm82
2016-10-26 11:11 maite Resolution time => 1478646000
2016-10-26 11:12 maite Issue Monitored: networkb
2016-10-26 11:13 maite Resolution time 1478646000 => 1479250800
2016-10-31 17:01 markmm82 Status new => scheduled
2016-11-10 20:20 markmm82 Note Added: 0091343
2016-11-11 15:14 psanjuan Note Added: 0091404
2016-11-14 12:29 psanjuan Note Edited: 0091404 View Revisions
2016-11-14 12:53 psanjuan Note Edited: 0091343 View Revisions
2016-11-14 12:53 psanjuan Note Added: 0091448
2016-11-14 12:57 psanjuan Note Edited: 0091343 View Revisions
2016-11-14 13:07 psanjuan Note Edited: 0091343 View Revisions
2016-11-14 13:09 psanjuan Note Edited: 0091343 View Revisions
2016-11-14 13:09 psanjuan Note Edited: 0091448 View Revisions
2016-11-14 13:09 psanjuan Note Edited: 0091343 View Revisions
2016-11-14 13:10 psanjuan Note Edited: 0091448 View Revisions
2016-11-14 13:13 psanjuan Note Added: 0091452
2016-11-14 13:16 psanjuan Note Edited: 0091452 View Revisions
2016-11-14 13:19 psanjuan Note Edited: 0091448 View Revisions
2016-11-14 13:26 hgbot Checkin
2016-11-14 13:26 hgbot Note Added: 0091453
2016-11-14 13:26 hgbot Status scheduled => resolved
2016-11-14 13:26 hgbot Resolution open => fixed
2016-11-14 13:26 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/3b0fb57e7fed324c6e4efb57a4c5657a1fa08e90 [^]
2016-11-14 13:27 aferraz Review Assigned To => aferraz
2016-11-14 13:27 aferraz Note Added: 0091454
2016-11-14 13:27 aferraz Status resolved => closed
2016-11-14 13:27 aferraz Fixed in Version => 3.0PR17Q1
2016-12-16 18:38 hudsonbot Checkin
2016-12-16 18:38 hudsonbot Note Added: 0092615


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker