修复代码工具decimal类型的bug
This commit is contained in:
parent
b73999e344
commit
8be9f46291
@ -62,9 +62,11 @@ public interface GenConstants {
|
||||
* 数据库数字类型
|
||||
*/
|
||||
String[] COLUMNTYPE_NUMBER = {"tinyint", "smallint", "mediumint", "int", "int2", "int4", "int8", "number", "integer",
|
||||
"bit", "bigint", "float", "float4", "float8", "double", "decimal", "numeric", "real", "double precision",
|
||||
"bit", "bigint", "float", "float4", "float8", "double", "numeric", "real", "double precision",
|
||||
"smallserial", "serial", "bigserial", "money", "smallmoney"};
|
||||
|
||||
String[] COLUMNTYPE_DECIMAL = {"decimal"};
|
||||
|
||||
/**
|
||||
* BO对象 不需要添加字段
|
||||
*/
|
||||
|
@ -61,7 +61,10 @@ public class GenUtils {
|
||||
column.setHtmlType(GenConstants.HTML_INPUT);
|
||||
// 数据库的数字字段与java不匹配 且很多数据库的数字字段很模糊 例如oracle只有number没有细分
|
||||
// 所以默认数字类型全为Long可在界面上自行编辑想要的类型 有什么特殊需求也可以在这里特殊处理
|
||||
//column.setJavaType(GenConstants.TYPE_LONG);
|
||||
column.setJavaType(GenConstants.TYPE_LONG);
|
||||
//column.setJavaType(GenConstants.TYPE_BIGDECIMAL);
|
||||
}else if (arraysContains(GenConstants.COLUMNTYPE_DECIMAL, dataType)) {
|
||||
column.setHtmlType(GenConstants.HTML_INPUT);
|
||||
column.setJavaType(GenConstants.TYPE_BIGDECIMAL);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user