Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0020861Openbravo ERP08. Project and service managementpublic2012-06-25 23:052012-06-28 13:35
malsasua 
mirurita 
urgentcriticalalways
closedfixed 
20Community Appliance
 
 
Google Chrome
Core
No
0020861: error with decimals to run process "create ap expense invoice"
If you have a line in an expense sheet with amount with more of 2 decimals (stdPrecision=2), if you create an invoice from this expense, the invoice is generated, but error is returned when it is processed.
. in F&B:
 . product: Cerveza Ale 0.5L:
  . stocked=N
  . product type: expense type

 . employee: Javier Martin
  . vendor=Y
  . purchase price list: bebidas alegres
  . po payment method: Al contado
  . po payment terms: 30 days
  . po financial account: libro de caja españa - región norte

 . create new project: name: test

 . create new expense sheet:
  . org: F&B Españá
  . employee: javier martin
  . date: 25/06/2012
  . create new line:
   . product: cerveza ale 0.5 L
   . qty: 38.56
   . net unit price: 0.55
   . project: test

 . run process: create AP Expense invoice:
  . employee: javi martin
  . from date - to date: 25-06-2012
  . date invoice: 01-07-2012
  . run
. purchase invoice is generated:
 . process it. error is returned:
Accounting amount differs from lines amount
The invoice is generated with a new record in invoice line accounting dimension (in live, this tab is hidden, but the record has been created in database). The amount in this record is not rounded to strPrecision

Attached a file with proposed solution
No tags attached.
diff diffRedondeoFacturaProvenienteHojaGasto.diff (2,989) 2012-06-27 12:42
https://issues.openbravo.com/file_download.php?file_id=5334&type=bug
Issue History
2012-06-25 23:05malsasuaNew Issue
2012-06-25 23:05malsasuaAssigned To => mirurita
2012-06-25 23:05malsasuaWeb browser => Google Chrome
2012-06-25 23:05malsasuaModules => Core
2012-06-27 12:42malsasuaWeb browserGoogle Chrome => Google Chrome
2012-06-27 12:42malsasuaProposed Solution updated
2012-06-27 12:42malsasuaFile Added: diffRedondeoFacturaProvenienteHojaGasto.diff
2012-06-27 17:08hgbotCheckin
2012-06-27 17:08hgbotNote Added: 0050193
2012-06-27 17:08hgbotStatusnew => resolved
2012-06-27 17:08hgbotResolutionopen => fixed
2012-06-27 17:08hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/db25f47ad0a40579de4321ef7a56b6ac74684702 [^]
2012-06-28 07:59hudsonbotCheckin
2012-06-28 07:59hudsonbotNote Added: 0050222
2012-06-28 13:35eduardo_ArgalNote Added: 0050253
2012-06-28 13:35eduardo_ArgalStatusresolved => closed

Notes
(0050193)
hgbot   
2012-06-27 17:08   
Repository: erp/devel/pi
Changeset: db25f47ad0a40579de4321ef7a56b6ac74684702
Author: Mikel Irurita <mikel.irurita <at> openbravo.com>
Date: Wed Jun 27 16:55:42 2012 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/db25f47ad0a40579de4321ef7a56b6ac74684702 [^]

Fixes issue 20861: error with decimals to run process 'create ap expense invoice'

---
M src/org/openbravo/erpCommon/ad_process/ExpenseAPInvoice.java
---
(0050222)
hudsonbot   
2012-06-28 07:59   
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/c66e853c5cf4 [^]

Maturity status: Test
(0050253)
eduardo_Argal   
2012-06-28 13:35   
Tested and working. Now amount is rounded