Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0013412Openbravo ERP07. Sales managementpublic2010-05-21 16:452010-06-03 22:49
shuehner 
adrianromero 
normalmajorhave not tried
closedfixed 
5
pi 
 
Core
No
0013412: SL_Order_DocType fails with non-numeric document type ID (i.e. newly created document types)
The following line in the callout implementation:

if (!newDocNo && Integer.valueOf(strDocType).intValue() != 0) {

fails with newly created document types as they a UUID's and not only numbers.

        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
        at java.lang.Integer.parseInt(Integer.java:449)
        at java.lang.Integer.valueOf(Integer.java:554)
        at org.openbravo.erpCommon.ad_callouts.SL_Order_DocType.printPage(SL_Order_DocType.java:95)
        at org.openbravo.erpCommon.ad_callouts.SL_Order_DocType.doPost(SL_Order_DocType.java:63)
UUID project
related to defect 00134322.50MP20 closed harikrishnan Identifiers are now UUID and java code cannot suppose are integer values 
Issue History
2010-05-21 16:45shuehnerNew Issue
2010-05-21 16:45shuehnerAssigned To => adrianromero
2010-05-21 16:45shuehnerNote Added: 0027645
2010-05-21 16:49shuehnerTag Attached: UUID project
2010-05-24 14:13hgbotCheckin
2010-05-24 14:13hgbotNote Added: 0027680
2010-05-24 14:13hgbotStatusnew => resolved
2010-05-24 14:13hgbotResolutionopen => fixed
2010-05-24 14:13hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/75ebe35a028a6f560d4a98c5f526499f6484fa50 [^]
2010-05-24 14:16adrianromeroNote Added: 0027681
2010-05-25 07:38arunkumarNote Added: 0027688
2010-05-25 07:38arunkumarStatusresolved => closed
2010-05-25 07:42sureshbabuNote Added: 0027689
2010-05-25 14:30adrianromeroRelationship addedrelated to 0013432
2010-05-26 00:00anonymoussf_bug_id0 => 3007110
2010-06-03 22:49hudsonbotCheckin
2010-06-03 22:49hudsonbotNote Added: 0027921

Notes
(0027645)
shuehner   
2010-05-21 16:45   
Found by seeing stacktrace in demo1.openbravo.com environment.
(0027680)
hgbot   
2010-05-24 14:13   
Repository: erp/devel/pi
Changeset: 75ebe35a028a6f560d4a98c5f526499f6484fa50
Author: Adrián Romero <adrianromero <at> openbravo.com>
Date: Mon May 24 14:12:24 2010 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/75ebe35a028a6f560d4a98c5f526499f6484fa50 [^]

Fixes issue 0013412: SL_Order_DocType fails with non-numeric document type ID (i.e. newly created document types)
This changeset modifies the condition of comparing the strDocType with 0, the Document type for new documents, not converting the value to integer because it will fail for new document types, document types with an UUID as identifier

---
M src/org/openbravo/erpCommon/ad_callouts/SL_Order_DocType.java
---
(0027681)
adrianromero   
2010-05-24 14:16   
* Steps to test
Create a new Document Type for Sales Orders. Just coping the values form another sales order document type.
Create a new Sales order with the recently created document type and process it.
Review the stack trace and verify that the error does not appear.

Other test that has to be done is to review the stacktrace in demo1.openbravo.com environment and review that this error does not appear again.

* Other areas affected
No other areas affected. Only the Sales order window with new document types is involved in this change.
(0027688)
arunkumar   
2010-05-25 07:38   
Tested working fine
(0027689)
sureshbabu   
2010-05-25 07:42   
verified..
(0027921)
hudsonbot   
2010-06-03 22:49   
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/75ebe35a028a [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/c011484a38d9 [^]
Tests: http://builds.openbravo.com/view/int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17407.obx [^]