Commit 3c702010 by fukai

修改对nulleditable的兼容

parent ecadd0e6
...@@ -131,7 +131,12 @@ public class NoUiPresentationUtil { ...@@ -131,7 +131,12 @@ public class NoUiPresentationUtil {
if (dataType.equals(Integer.TYPE) || dataType.equals(Integer.class)) { if (dataType.equals(Integer.TYPE) || dataType.equals(Integer.class)) {
String data = value.toString().trim(); String data = value.toString().trim();
if (StringUtils.isEmpty(data)) if (StringUtils.isEmpty(data))
{
if(dataField.isNullable())
dataField.setValue(null);
else
dataField.setValue(0); dataField.setValue(0);
}
else else
dataField.setValue(Double.valueOf(data.replaceAll(",", "")).intValue()); dataField.setValue(Double.valueOf(data.replaceAll(",", "")).intValue());
return; return;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment