Xml Deserializer does not support BigDecimal
--------------------------------------------

                 Key: OFBIZ-4733
                 URL: https://issues.apache.org/jira/browse/OFBIZ-4733
             Project: OFBiz
          Issue Type: Bug
          Components: framework
    Affects Versions: SVN trunk
            Reporter: Alexander Reelsen


In the last weeks the XML Serializer in trunk was extended to support 
BigDecimal. Unfortunately deserializing is not supported, which leads to 
services being broken when running via async as their are persisted in 
runtime_data... like sending mails, when a bigdecimal is involved

Patch is:

--- a/framework/entity/src/org/ofbiz/entity/serialize/XmlSerializer.java        
Fri Mar 16 16:32:16 2012 +0100
+++ b/framework/entity/src/org/ofbiz/entity/serialize/XmlSerializer.java        
Mon Mar 19 09:08:17 2012 +0100
@@ -300,6 +300,9 @@
             } else if ("std-Integer".equals(tagName)) {
                 String valStr = element.getAttribute("value");
                 return Integer.valueOf(valStr);
+            } else if ("std-BigDecimal".equals(tagName)) {
+                String valStr = element.getAttribute("value");
+                return new BigDecimal(valStr);
             } else if ("std-Long".equals(tagName)) {
                 String valStr = element.getAttribute("value");
                 return Long.valueOf(valStr);



--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to