Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0025359Openbravo ERP08. Project and service managementpublic2013-12-18 03:062014-03-25 19:47
pjuvara 
shankarb 
normalmajoralways
closedfixed 
5
3.0MP29.1 
 
AugustoMauch
Google Chrome
Core
No
0025359: Invalid currency in invoice plan master for service contract
In a service contract, the currency should be dictated by the currency of the price list specified on the contract.
Instead, the lines have a separate currency field which is always defaulted to AED (the first currency in alphabetical order) and users cannot change it.

The consequence is that all the downstream transactions (invoices, etc.) are created with the wrong currency.

See attached screenshot where the price list is based on USD (I know in the screenshot you see the name of the price list but please do trust me that the price list is specified in USD) and on the Invoice Plan Master line (in this screenshot, the tab has been renamed to "Subscribed Services") the currency is AED.
The problem reproduces in the Service Contract Management module version 1.2.1 or above (I reproduced it in 1.2.1, 1.2.5 and 1.2.10) but it does not reproduce in version 1.1.1).

To reproduce:
1) Create product (we used type service)
2) Create a price list in USD and add the product to that price list
3) Create a business partner and choose the above price list as the default price list for the business partner
4) Create a new contract for the business partner.
5) Add an invoice plan master line for the product of step 1

You will see the invalid currency.
No tags attached.
related to defect 00257543.0PR14Q2 closed shankarb Wrong behavior when calculating the value of a property field for a new record (FIC) 
png OBInvalidCurrency.png (121,431) 2013-12-18 03:06
https://issues.openbravo.com/file_download.php?file_id=6572&type=bug
png
Issue History
2013-12-18 03:06pjuvaraNew Issue
2013-12-18 03:06pjuvaraAssigned To => dmiguelez
2013-12-18 03:06pjuvaraFile Added: OBInvalidCurrency.png
2013-12-18 03:06pjuvaraWeb browser => Google Chrome
2013-12-18 03:06pjuvaraModules => Core
2013-12-18 03:06pjuvaraTriggers an Emergency Pack => No
2013-12-18 03:09pjuvaraNote Added: 0062752
2013-12-18 03:21pjuvaraNote Added: 0062753
2014-01-23 08:18shankarbNote Added: 0063632
2014-01-23 11:05shankarbAssigned Todmiguelez => shankarb
2014-03-24 08:13shankarbRelationship addedrelated to 0025754
2014-03-24 12:05shankarbIssue Monitored: AugustoMauch
2014-03-24 12:06shankarbReview Assigned To => AugustoMauch
2014-03-24 12:06shankarbWeb browserGoogle Chrome => Google Chrome
2014-03-24 12:06hgbotCheckin
2014-03-24 12:06hgbotNote Added: 0065388
2014-03-24 12:06hgbotStatusnew => resolved
2014-03-24 12:06hgbotResolutionopen => fixed
2014-03-24 12:06hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/8780b04632631f7512582fcb3e6b74faf1a749de [^]
2014-03-24 15:45AugustoMauchNote Added: 0065400
2014-03-24 15:45AugustoMauchStatusresolved => closed
2014-03-25 19:47hudsonbotCheckin
2014-03-25 19:47hudsonbotNote Added: 0065446

Notes
(0062752)
pjuvara   
2013-12-18 03:09   
Please notice that if there is a charge associated as a sales order to this contract, the Contract Billing Process is not going to be able to generate a single invoice.
The invoice plan will generate an invoice in AED (incorrect) and the order will be invoiced on a separate invoice in USD.
(0062753)
pjuvara   
2013-12-18 03:21   
Since at line level the currency is defaulted to the first currency in alphabetical order, a possible workaround is to deactivate all currencies except USD.
This workaround obviously is not acceptable to companies that operate in multiple currencies.
(0063632)
shankarb   
2014-01-23 08:18   
Test plan for core:
* Login as System Administrator.
* Navigate to Windows, tabs and fields
* Go to window sales order
* Go to lines tab
* Go to fields and create a new record
   Name: Sample Currency
   property: salesOrder.priceList.currency
* Login as Client Admin
* Navigate to sales order
* Create an header
* Create new line.
* Notice that sample currency field always has the same value.
* Save the record.
* Refresh the record.
* Notice that correct currency is getting selected.
(0065388)
hgbot   
2014-03-24 12:06   
Repository: erp/devel/pi
Changeset: 8780b04632631f7512582fcb3e6b74faf1a749de
Author: Shankar Balachandran <shankar.balachandran <at> openbravo.com>
Date: Mon Mar 24 16:33:35 2014 +0530
URL: http://code.openbravo.com/erp/devel/pi/rev/8780b04632631f7512582fcb3e6b74faf1a749de [^]

Fixes Issue 0025754, Fixes Issue 25359: Property fields are evaluated on NEW request

When a new record is created, property fields were not evaluated and default values were sent.
Now the property fields are tried to be evaluated, if value is not found, null is returned.

---
M modules/org.openbravo.client.application/src/org/openbravo/client/application/window/FormInitializationComponent.java
---
(0065400)
AugustoMauch   
2014-03-24 15:45   
Code reviewed and verified in pi@8780b0463263
(0065446)
hudsonbot   
2014-03-25 19:47   
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/05169b1f5a79 [^]
Maturity status: Test