Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0012832Openbravo ERP07. Sales managementpublic2010-03-29 11:492010-05-18 12:12
arunkumar 
alostale 
urgentcriticalhave not tried
closedfixed 
5
2.50MP9 
2.50MP17 
Core
No
0012832: Precision error in sales invoice
Configure the Format.xml to 4 decimal places and configure the Price precision as 4 in general setup -> Application -> currency.If the product price has four decimal places for example 6.7849 then while selecting the product in sales invoice and changing the quantity to 2 then the price is rounded off to 6.7850.
Prerequisite:

Format.xml -> priceRelation and priceEdition are set as 0.0000

General Setup -> Application -> currency. For Euro Standard precision=2,
Price precision=4, Costing precision=2

Create a business partner CUSTOMER A.

Pricelist -> Create a pricelist CUSTOMER A - product : A Final Goods

List price = Standard Price = Price Limit = 6.7849 for the product.

Steps to reproduce the issue:

** Go to Sales Management || Transactions || Sales Invoice || Header
** Create a new record and select the business partner CUSTOMER A which has
the Price List "CUSTOMER A"
** Go to lines and select the product A Final Goods. If the ordered quantity
is 1 then the net unit price is set as 6.7849. But if I change the
quantity to 2 then the net unit price changes to 6.7850.
Since the Format.xml and Price precision are configured to hold 4 decimal places rounding off should not be done here.
Regression
related to defect 00128432.50MP17 closed harikrishnan Product price value truncated to 2 decimal places instead of 4 decimal places 
has duplicate defect 00127882.50MP17 closed alostale Precision error in simple sales order 
Issue History
2010-03-29 11:49arunkumarNew Issue
2010-03-29 11:49arunkumarAssigned To => adrianromero
2010-03-29 11:49arunkumarStatusnew => scheduled
2010-03-29 11:49arunkumarfix_in_branch => pi
2010-03-29 13:18adrianromeroRelationship addedrelated to 0012798
2010-03-29 13:19adrianromeroRelationship deletedrelated to 0012798
2010-03-29 13:19adrianromeroRelationship addedrelated to 0012788
2010-03-29 19:03adrianromeroRelationship addedrelated to 0012843
2010-03-30 11:11adrianromeroRelationship replacedduplicate of 0012788
2010-03-30 11:12adrianromeroAssigned Toadrianromero => alostale
2010-03-30 11:12adrianromeroPriorityimmediate => urgent
2010-03-30 11:12adrianromeroTarget Version => 2.50MP15
2010-03-30 11:12adrianromerofix_in_branchpi =>
2010-04-06 17:24hgbotCheckin
2010-04-06 17:24hgbotNote Added: 0025907
2010-04-06 17:24hgbotStatusscheduled => resolved
2010-04-06 17:24hgbotResolutionopen => fixed
2010-04-06 17:24hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/a31f8e677521b9dd6890f186f69f02f48a89d53f [^]
2010-04-06 17:26alostaleRelationship replacedhas duplicate 0012788
2010-04-07 12:33psarobeversionmain => 2.50MP9
2010-04-07 12:33psarobeTag Attached: Regression
2010-04-15 10:27iperdomoNote Added: 0026228
2010-04-15 10:27iperdomoStatusresolved => closed
2010-04-16 00:00anonymoussf_bug_id0 => 2987976
2010-04-19 21:12hudsonbotCheckin
2010-04-19 21:12hudsonbotNote Added: 0026419
2010-05-18 12:12gorka_gilTarget Version2.50MP15 => 2.50MP17

Notes
(0025907)
hgbot   
2010-04-06 17:24   
Repository: erp/devel/pi
Changeset: a31f8e677521b9dd6890f186f69f02f48a89d53f
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Tue Apr 06 17:35:29 2010 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/a31f8e677521b9dd6890f186f69f02f48a89d53f [^]

fixed bug 12832: Precision error

Format is now taken into accout for hidden fields

---
M src-wad/src/org/openbravo/wad/Wad.java
M src-wad/src/org/openbravo/wad/controls/WADControl.java
M src-wad/src/org/openbravo/wad/controls/WADHiddenXML.html
M src-wad/src/org/openbravo/wad/controls/WADInteger.java
M src-wad/src/org/openbravo/wad/controls/WADNumber.java
A src-wad/src/org/openbravo/wad/controls/WADHiddenNumber.html
A src-wad/src/org/openbravo/wad/controls/WADHiddenNumber.xml
R src-wad/src/org/openbravo/wad/controls/WADHidden.java
---
(0026228)
iperdomo   
2010-04-15 10:27   
Tested on PI @ rev 7076c219cdd9

Now, hidden fields have outputformat attribute
(0026419)
hudsonbot   
2010-04-19 21:12   
A changeset related to this issue has been promoted to main after passing a series of tests and an OBX has been generated:

Changeset: http://code.openbravo.com/erp/devel/main/rev/a31f8e677521 [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/91d98bda46c1 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17088.obx [^]