Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0028552Openbravo ERPA. Platformpublic2015-01-09 13:042015-02-04 20:33
jonalegriaesarte 
alostale 
immediatecriticalhave not tried
closedfixed 
5
 
3.0PR15Q23.0PR15Q2 
AugustoMauch
Core
Production - Confirmed Stable
2014-04-08
3.0PR14Q3
http://code.openbravo.com/erp/devel/pi/rev/28afef8656512aeae764101425d2e46cd7b9d051 [^]
Yes
0028552: Purchase Invoice amount gets truncated upon saving, when the amount is big
Purchase Invoice amount gets truncated upon saving, when the amount is big
1. Create Purchase Invoice
2. Create a new line
- enter unit price = 1200
- enter quantity = 29 900 000
3. Move away from the fields, and the Line Net Amount shows = 35,988,000,000.00 (CORRECT)
4. Click Save to save the line
The Line Net Amount shows 35.9 (INCORRECT)
No tags attached.
related to defect 00257103.0PR14Q2 closed AugustoMauch Big numbers are not properly managed in amount fields 
caused by defect 00261323.0PR14Q3 closed guillermogil wrong visualization value of quantity fields with very small numbers 
related to defect 0028561 closed caristu OB.Utilities.Number.ScientificToDecimal does not work properly with numbers with leading zeros 
related to defect 0028262 acknowledged Triage Platform Base Number precision induces some unaccurate results 
related to defect 0029709 closed NaroaIriarte Cannot save a physical inventory line with a negative small number in the Book Quantity field 
related to defect 0030014 closed NaroaIriarte The function OB.Utilities.Number.OBMaskedToOBPlain is not working properly with negative big numbers 
causes defect 0028720 closed alostale System is not saving big numbers properly 
Issue History
2015-01-09 13:04jonalegriaesarteNew Issue
2015-01-09 13:04jonalegriaesarteAssigned To => AugustoMauch
2015-01-09 13:04jonalegriaesarteModules => Core
2015-01-09 13:04jonalegriaesarteResolution time => 1422745200
2015-01-09 13:04jonalegriaesarteTriggers an Emergency Pack => No
2015-01-09 14:10alostaleRegression level => Production - Confirmed Stable
2015-01-09 14:10alostaleRegression date => 2014-04-08
2015-01-09 14:10alostaleRegression introduced in release => 3.0PR14Q3
2015-01-09 14:10alostaleRegression introduced by commit => http://code.openbravo.com/erp/devel/pi/rev/28afef8656512aeae764101425d2e46cd7b9d051 [^]
2015-01-09 14:10alostaleTriggers an Emergency PackNo => Yes
2015-01-09 14:10alostaleAssigned ToAugustoMauch => alostale
2015-01-09 14:10alostaleRelationship addedcaused by 0026132
2015-01-09 14:12alostaleRelationship addedrelated to 0025710
2015-01-09 14:13alostaleNote Added: 0073397
2015-01-09 15:19alostaleReview Assigned To => AugustoMauch
2015-01-09 15:19hgbotCheckin
2015-01-09 15:19hgbotNote Added: 0073403
2015-01-09 15:19hgbotStatusnew => resolved
2015-01-09 15:19hgbotResolutionopen => fixed
2015-01-09 15:19hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/e5465c5925cf54475d090258a3832ec8cc9d14ca [^]
2015-01-09 15:40alostaleNote Added: 0073405
2015-01-12 11:07AugustoMauchRelationship addedrelated to 0028561
2015-01-12 11:08AugustoMauchNote Added: 0073411
2015-01-12 11:08AugustoMauchStatusresolved => closed
2015-01-12 11:08AugustoMauchFixed in Version => 3.0PR15Q2
2015-01-20 17:03alostaleRelationship addedrelated to 0028262
2015-01-22 09:27alostaleRelationship addedrelated to 0028720
2015-01-22 10:39alostaleRelationship replacedcauses 0028720
2015-02-04 20:33hudsonbotCheckin
2015-02-04 20:33hudsonbotNote Added: 0074132
2015-05-26 09:29NaroaIriarteRelationship addedrelated to 0029709
2015-05-26 13:20NaroaIriarteRelationship addedrelated to 0030014

Notes
(0073397)
alostale   
2015-01-09 14:13   
This issue was reproducible in versions previous to Q2, it was fixed in Q2 and broken again in Q3.
(0073403)
hgbot   
2015-01-09 15:19   
Repository: erp/devel/pi
Changeset: e5465c5925cf54475d090258a3832ec8cc9d14ca
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Fri Jan 09 15:18:45 2015 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/e5465c5925cf54475d090258a3832ec8cc9d14ca [^]

fixed bug 28552: big numbers are changed in some cases

  Big numbers are modified in case their scientific notation represntation ends
  with zeros, trailing zeros were removed. So, ie., 3.5E10 was changed to 3.5E1
  this is: 3.5.

  The problem was caused by fix for 0026132 which tries to transform scientific to
  decimal notation (and then remove trailing zeros, which is correct). But it
  expected 3.5E+10 instead of 3.5E10, so in latter case, which is actually used
  it didn't do the transformation.

  The fix accepts scientific notation with both + and no +.

---
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/utilities/ob-utilities-number.js
---
(0073405)
alostale   
2015-01-09 15:40   
Tested for big amounts and small ones (see 0026132)
(0073411)
AugustoMauch   
2015-01-12 11:08   
Code reviewed and verified in pi@5f64300e4811
(0074132)
hudsonbot   
2015-02-04 20:33   
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/f36c91d0ad63 [^]
Maturity status: Test