From f039095f8349d7e209bd3e4318de758e497b68c3 Mon Sep 17 00:00:00 2001 From: "wei.peng" Date: Tue, 26 Mar 2019 12:04:23 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=AF=B9=E8=B1=A1?= =?UTF-8?q?=E5=AE=9E=E4=BD=93=E6=9B=B4=E6=96=B0=20=E5=88=9B=E5=BB=BA?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=AF=B9=E8=B1=A1=20Model?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pojo/base/enumutil/BlockFormEnumUtil.java | 94 +++++++++++++++++++++- .../i3plus/pojo/base/enumutil/CommonEnumUtil.java | 9 +++ .../estsh/i3plus/pojo/form/bean/BfDataObject.java | 6 +- .../i3plus/pojo/model/form/SqlColumnModel.java | 52 ++++++++++++ .../i3plus/pojo/model/form/SqlCreateDllModel.java | 31 +++++++ 5 files changed, 190 insertions(+), 2 deletions(-) create mode 100644 modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlColumnModel.java create mode 100644 modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlCreateDllModel.java diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/BlockFormEnumUtil.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/BlockFormEnumUtil.java index eb0862b..168c94a 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/BlockFormEnumUtil.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/BlockFormEnumUtil.java @@ -54,7 +54,7 @@ public class BlockFormEnumUtil { public static int codeOfValue(String code) { int tmp = 1; for (int i = 0; i < values().length; i++) { - if (values()[i].code.equals(code)) { + if (values()[i].code.equals(code.toLowerCase())) { tmp = values()[i].value; } } @@ -93,6 +93,87 @@ public class BlockFormEnumUtil { } /** + * 原数据状态 + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum FORM_TABLE_STATUS { + SYNCHRONOUS_UNDONE(1, "未完成", "未同步"), + SYNCHRONOUS_COMPLETE(2, "已完成", "已同步"); + + private int value; + private String code; + private String description; + + private FORM_TABLE_STATUS(int value, String code, String description) { + this.value = value; + this.code = code; + this.description = description; + } + + public int getValue() { + return value; + } + + public String getCode() { + return code; + } + + public String getDescription() { + return description; + } + + public static String valueOfCode(int val) { + String tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].value == val) { + tmp = values()[i].code; + } + } + return tmp; + } + + public static int codeOfValue(String code) { + int tmp = 1; + for (int i = 0; i < values().length; i++) { + if (values()[i].code.equals(code.toLowerCase())) { + tmp = values()[i].value; + } + } + return tmp; + } + + public static String valueOfDescription(int val) { + String tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].value == val) { + tmp = values()[i].description; + } + } + return tmp; + } + + public static FORM_TABLE_STATUS valueOf(int val) { + String tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].value == val) { + return values()[i]; + } + } + return null; + } + + public static String codeOfDescription(String code) { + String tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].code.equals(code)) { + tmp = values()[i].description; + } + } + return tmp; + } + } + + /** * 行信息 */ @JsonFormat(shape = JsonFormat.Shape.OBJECT) @@ -881,6 +962,16 @@ public class BlockFormEnumUtil { return null; } + public static PROPERTY_TYPE indexOf(String val) { + String tmp = null; + for (int i = 0; i < values().length; i++) { + if (val.indexOf(values()[i].value) >= 0) { + return values()[i]; + } + } + return null; + } + public static String codeOfDescription(String code) { String tmp = null; for (int i = 0; i < values().length; i++) { @@ -1429,4 +1520,5 @@ public class BlockFormEnumUtil { return tmp; } } + } diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/CommonEnumUtil.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/CommonEnumUtil.java index b3ce5ec..ed2f951 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/CommonEnumUtil.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/CommonEnumUtil.java @@ -153,6 +153,15 @@ public class CommonEnumUtil { } return tmp; } + + public static int descOf(boolean desc) { + return desc ? TRUE_OR_FALSE.TRUE.getValue() : TRUE_OR_FALSE.FALSE.getValue(); + } + + public static int descOf(int desc) { + return desc == 0 ? TRUE_OR_FALSE.TRUE.getValue() : TRUE_OR_FALSE.FALSE.getValue(); + } + public static String valueOfDescription(int val) {return valueOf(val);} public static int descriptionOfValue(String desc) {return descOf(desc);} diff --git a/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObject.java b/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObject.java index bba2a17..b6d2f95 100644 --- a/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObject.java +++ b/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObject.java @@ -47,10 +47,14 @@ public class BfDataObject extends BaseBean { @ApiParam(value ="数据表名") private String objectTableName; - @Column(name="OBJECT_CONTENT") + @Column(name="OBJECT_CONTENT",columnDefinition="TEXT") @ApiParam(value ="数据内容") private String objectContent; + @Column(name="OBJECT_STATUS") + @ApiParam(value ="表状态(是否同步)") + private Integer objectStatus; + @Column(name="OBJECT_TYPE") @ApiParam(value ="数据类型") private Integer objectType; diff --git a/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlColumnModel.java b/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlColumnModel.java new file mode 100644 index 0000000..81f736e --- /dev/null +++ b/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlColumnModel.java @@ -0,0 +1,52 @@ +package cn.estsh.i3plus.pojo.model.form; + +import io.swagger.annotations.ApiParam; +import lombok.Data; + +/** + * @Description : + * @Reference : + * @Author : Adair Peng + * @CreateDate : 2019-03-22 17:17 + * @Modify: + **/ +@Data +public class SqlColumnModel { +// isAutoIncrement true isNullable 0 isSigned true getColumnDisplaySize 11 getColumnLabel id getColumnName id getSchemaName getPrecision 11 getScale 0 getTableName test getColumnType 4 getColumnTypeName INT getColumnClassName java.lang.Integer +// isAutoIncrement false isNullable 1 isSigned false getColumnDisplaySize 50 getColumnLabel name getColumnName name getSchemaName getPrecision 50 getScale 0 getTableName test getColumnType 12 getColumnTypeName VARCHAR getColumnClassName java.lang.String +// isAutoIncrement false isNullable 1 isSigned true getColumnDisplaySize 11 getColumnLabel age getColumnName age getSchemaName getPrecision 11 getScale 0 getTableName test getColumnType 4 getColumnTypeName INT getColumnClassName java.lang.Integer +// isAutoIncrement false isNullable 1 isSigned false getColumnDisplaySize 19 getColumnLabel date_time getColumnName date_time getSchemaName getPrecision 19 getScale 0 getTableName test getColumnType 93 getColumnTypeName TIMESTAMP getColumnClassName java.sql.Timestamp +// isAutoIncrement false isNullable 0 isSigned true getColumnDisplaySize 11 getColumnLabel test_num_not_null getColumnName test_num_not_null getSchemaName getPrecision 11 getScale 0 getTableName test getColumnType 4 getColumnTypeName INT getColumnClassName java.lang.Integer +// isAutoIncrement false isNullable 1 isSigned true getColumnDisplaySize 11 getColumnLabel test_unique getColumnName test_unique getSchemaName getPrecision 11 getScale 0 getTableName test getColumnType 4 getColumnTypeName INT getColumnClassName java.lang.Integer +// isAutoIncrement false isNullable 1 isSigned true getColumnDisplaySize 11 getColumnLabel test_comment getColumnName test_comment getSchemaName getPrecision 11 getScale 0 getTableName test getColumnType 4 getColumnTypeName INT getColumnClassName java.lang.Integer +// isAutoIncrement false isNullable 1 isSigned false getColumnDisplaySize 500 getColumnLabel test_string_1000 getColumnName test_string_1000 getSchemaName getPrecision 500 getScale 0 getTableName test getColumnType 12 getColumnTypeName VARCHAR getColumnClassName java.lang.String +// isAutoIncrement false isNullable 1 isSigned true getColumnDisplaySize 4 getColumnLabel test_double getColumnName test_double getSchemaName getPrecision 4 getScale 2 getTableName test getColumnType 8 getColumnTypeName DOUBLE getColumnClassName java.lang.Double + // 是否自增 + @ApiParam(value = "是否自增") + private Integer isAutoIncrement; + // 是否允许为空 + @ApiParam(value = "是否允许为空") + private Integer isNullable; + // 是否是对象 + @ApiParam(value = "是否是对象") + private Integer isSigned; + // 字段名称 + @ApiParam(value = "字段名称") + private String columnName; + // 字段长度 + @ApiParam(value = "字段长度") + private Integer precision; + // 字段精确长度 + @ApiParam(value = "字段精确长度") + private Integer scale; + // 字段类型编号 + @ApiParam(value = "字段类型编号") + private Integer columnType; + // 字段类型名称 + @ApiParam(value = "字段类型名称") + private String columnTypeName; + // 字段Java 类型 + @ApiParam(value = "字段Java 类型") + private String columnClassName; + +} diff --git a/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlCreateDllModel.java b/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlCreateDllModel.java new file mode 100644 index 0000000..ac7da8e --- /dev/null +++ b/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlCreateDllModel.java @@ -0,0 +1,31 @@ +package cn.estsh.i3plus.pojo.model.form; + +import io.swagger.annotations.ApiParam; +import lombok.Data; + +import java.util.List; +import java.util.Objects; + +/** + * @Description : + * @Reference : + * @Author : Adair Peng + * @CreateDate : 2019-03-22 16:40 + * @Modify: + **/ +@Data +public class SqlCreateDllModel { + + private String tableCat; + private String tableSchem; + private String tableName; + private Integer tableType; + private String tableTypeName; + private String remarks; + private String typeCat; + private String typeName; + private String selfReferencingColName; + private String refGeneration; + + List columnlist ; +} From 2ce0dcbaf178278c270b64d752f9c74f2319d7ce Mon Sep 17 00:00:00 2001 From: "gragon.xu" Date: Tue, 26 Mar 2019 21:25:58 +0800 Subject: [PATCH 2/3] dragon --- .../cn/estsh/i3plus/pojo/wms/bean/WmsLocate.java | 72 +++++++++++----------- 1 file changed, 36 insertions(+), 36 deletions(-) diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/WmsLocate.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/WmsLocate.java index 276a37d..f5eabd7 100644 --- a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/WmsLocate.java +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/WmsLocate.java @@ -21,85 +21,85 @@ import javax.persistence.Table; **/ @Data @Entity -@Table(name="WMS_LOCATE") +@Table(name = "WMS_LOCATE") @DynamicInsert @DynamicUpdate @EqualsAndHashCode(callSuper = true) -@Api(value="库位表",description = "库位表") +@Api(value = "库位表", description = "库位表") public class WmsLocate extends BaseBean { - @Column(name="LOCATE_NO") - @ApiParam(value ="库位代码") + @Column(name = "LOCATE_NO") + @ApiParam(value = "库位代码") private String locateNo; - @Column(name="LOCATE_NAME") - @ApiParam(value ="库位名称") + @Column(name = "LOCATE_NAME") + @ApiParam(value = "库位名称") private String locateName; /** * 库位类型:10=收货库,20=基础库,30=机动库,40=组合库,50=线边库,60=NC库,70=溢料,80=在途库位 */ - @Column(name="LOCATE_TYPE") - @ApiParam(value ="库位类型") + @Column(name = "LOCATE_TYPE") + @ApiParam(value = "库位类型") private Integer locateType; - @Column(name="WH_NO") - @ApiParam(value ="仓库代码") + @Column(name = "WH_NO") + @ApiParam(value = "仓库代码") private String whNo; - @Column(name="ZONE_NO") - @ApiParam(value ="存储区代码") + @Column(name = "ZONE_NO") + @ApiParam(value = "存储区代码") private String zoneNo; - @Column(name="X") - @ApiParam(value ="X", example = "-1") + @Column(name = "X") + @ApiParam(value = "X", example = "-1") private Integer x; - @Column(name="Y") - @ApiParam(value ="Y", example = "-1") + @Column(name = "Y") + @ApiParam(value = "Y", example = "-1") private Integer y; - @Column(name="Z") - @ApiParam(value ="Z", example = "-1") + @Column(name = "Z") + @ApiParam(value = "Z", example = "-1") private Integer z; - @Column(name="SEQ") - @ApiParam(value ="序号", example = "-1") + @Column(name = "SEQ") + @ApiParam(value = "序号", example = "-1") private Integer seq; - @Column(name="STATUS") - @ApiParam(value ="库位状态", example = "-1") + @Column(name = "STATUS") + @ApiParam(value = "库位状态", example = "-1") private Integer status; - @Column(name="MAX_PACKAGE_QTY") - @ApiParam(value ="最大包装数量", example = "-1") + @Column(name = "MAX_PACKAGE_QTY") + @ApiParam(value = "最大包装数量", example = "-1") private Integer maxPackageQty; - @Column(name="MAX_PART_QTY") - @ApiParam(value ="最大零件数量", example = "-1") - private Integer maxPartQty; + @Column(name = "MAX_PART_QTY") + @ApiParam(value = "最大零件数量", example = "-1") + private Double maxPartQty; - @Column(name="STOCK_UNIT") - @ApiParam(value ="存放单位") + @Column(name = "STOCK_UNIT") + @ApiParam(value = "存放单位") private String stockUnit; - @Column(name="LINE_CODE") - @ApiParam(value ="生产线") + @Column(name = "LINE_CODE") + @ApiParam(value = "生产线") private String lineCode; - @Column(name="BOX_QTY") - @ApiParam(value ="箱数", example = "-1") + @Column(name = "BOX_QTY") + @ApiParam(value = "箱数", example = "-1") private Integer boxQty; - @Column(name="PART_QTY") - @ApiParam(value ="零件数", example = "-1") + @Column(name = "PART_QTY") + @ApiParam(value = "零件数", example = "-1") private Double partQty; public Integer getMaxPackageQty() { return this.maxPackageQty == null ? 0 : this.maxPackageQty; } - public Integer getMaxPartQty() { + public Double getMaxPartQty() { return this.maxPartQty == null ? 0 : this.maxPartQty; } From e4adb35413061acb6ba51790d08e1b9a1d2a4d69 Mon Sep 17 00:00:00 2001 From: "wei.peng" Date: Tue, 26 Mar 2019 21:50:11 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E8=87=AA=E5=AE=9A=E4=B9=89=E8=A1=A8?= =?UTF-8?q?=E5=8D=95=20=E6=95=B0=E6=8D=AE=E5=AF=B9=E8=B1=A1=20=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E6=8E=A5=E5=8F=A3=E5=AE=8C=E6=88=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../i3plus/pojo/base/dynamic/DynamicBean.java | 4 +- .../i3plus/pojo/base/dynamic/DynamicEntity.java | 24 +++++++++- .../pojo/base/enumutil/BlockFormEnumUtil.java | 53 ++++++++++++++++------ .../estsh/i3plus/pojo/form/bean/BfDataObject.java | 1 + .../pojo/form/bean/BfDataObjectProperty.java | 4 ++ .../pojo/form/bean/BfElementPropertyVirtual.java | 2 +- .../i3plus/pojo/model/form/SqlColumnModel.java | 5 ++ 7 files changed, 77 insertions(+), 16 deletions(-) diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/dynamic/DynamicBean.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/dynamic/DynamicBean.java index 577139e..cb05869 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/dynamic/DynamicBean.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/dynamic/DynamicBean.java @@ -46,7 +46,9 @@ public class DynamicBean { * @param value */ public void setValue(String property, Object value) { - beanMap.put(property, value); + if(!beanMap.containsKey(property)){ + beanMap.put(property, value); + } } /** diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/dynamic/DynamicEntity.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/dynamic/DynamicEntity.java index c8006b8..f9437db 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/dynamic/DynamicEntity.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/dynamic/DynamicEntity.java @@ -14,6 +14,7 @@ import java.lang.reflect.Method; import java.sql.ResultSet; import java.sql.SQLException; import java.util.ArrayList; +import java.util.Date; import java.util.List; import java.util.Map; @@ -158,20 +159,41 @@ public class DynamicEntity extends BaseBean implements Serializable { fieldVal = 0.0f; } else if (f.getType() == Double.class) { fieldVal = 0.0d; - } else { + } else if (f.getType() == String.class) { + fieldVal = ""; + }else if (f.getType() == Character.class) { + fieldVal = ""; + }else if (f.getType() == Boolean.class) { + fieldVal = true; + }else if (f.getType() == Byte.class) { + fieldVal = 0; + }else if (f.getType() == Date.class) { + fieldVal = new Date(); + }else { fieldVal = ""; } } try { setMethod = this.getClass().getDeclaredMethod(setMethodName, new Class[]{f.getType()}); + System.out.println("Method Name:" + setMethod.getName() + "\t\t Value : " + fieldVal); setMethod.invoke(this, fieldVal); + } catch (ClassCastException e) { + e.printStackTrace(); + LOGGER.error("ClassCastException :{}", setMethodName, e); + } catch (IllegalArgumentException e) { + e.printStackTrace(); + LOGGER.error("IllegalArgumentException :{}", setMethodName, e); } catch (NoSuchMethodException e) { LOGGER.error("没有方法:{}", setMethodName, e); } catch (IllegalAccessException e) { LOGGER.error("入参出错:{}:{}:{}", f, f.getType(), fieldVal, e); } catch (InvocationTargetException e) { LOGGER.error("方法返回出错:{}", setMethodName, e); + }catch (RuntimeException e) { + LOGGER.error("RuntimeException :{}", setMethodName, e); + }catch (Exception e) { + LOGGER.error("Exception :{}", setMethodName, e); } } } diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/BlockFormEnumUtil.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/BlockFormEnumUtil.java index c6a518e..6cef54a 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/BlockFormEnumUtil.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/BlockFormEnumUtil.java @@ -1,6 +1,9 @@ package cn.estsh.i3plus.pojo.base.enumutil; import com.fasterxml.jackson.annotation.JsonFormat; +import javafx.scene.chart.Chart; + +import java.util.Date; /** * @Description : 模块表单枚举类 @@ -805,7 +808,7 @@ public class BlockFormEnumUtil { * 虚拟类型信息 */ @JsonFormat(shape = JsonFormat.Shape.OBJECT) - public enum PROPERTY_VIRTUAL_TYPE { + public enum PROPERTY_VIRTUAL_OPERATE_TYPE { STRING_SPLICE(10, "SPLICE", "字符串拼接"), NUM_ADD(20, "ADD", "加法计算"), NUM_LESS(30, "MIN", "减法计算"), @@ -816,7 +819,7 @@ public class BlockFormEnumUtil { private String code; private String description; - private PROPERTY_VIRTUAL_TYPE(int value, String code, String description) { + private PROPERTY_VIRTUAL_OPERATE_TYPE(int value, String code, String description) { this.value = value; this.code = code; this.description = description; @@ -864,7 +867,7 @@ public class BlockFormEnumUtil { return tmp; } - public static PROPERTY_VIRTUAL_TYPE valueOf(int val) { + public static PROPERTY_VIRTUAL_OPERATE_TYPE valueOf(int val) { String tmp = null; for (int i = 0; i < values().length; i++) { if (values()[i].value == val) { @@ -890,24 +893,28 @@ public class BlockFormEnumUtil { */ @JsonFormat(shape = JsonFormat.Shape.OBJECT) public enum PROPERTY_TYPE { - STRING(10, "String", "字符串"), - CHAR(11, "Character", "单字符"), - INTEGER(20, "Integer", "短整型"), - LONG(21, "Long", "长整型"), - DOUBLE(30, "Double", "大浮点型"), - FLOAT(31, "Float", "小浮点型"), - BOOLEAN(40, "Boolean", "布尔值"), - BYTE(50, "Byte", "字节"), - DATE(60, "Date", "日期"); + STRING(10, "String", "字符串", "java.lang.String", String.class), + CHAR(11, "Character", "单字符", "java.lang.Character", Character.class), + INTEGER(20, "Integer", "短整型", "java.lang.Integer", Integer.class), + LONG(21, "Long", "长整型", "java.lang.Long", Long.class), + DOUBLE(30, "Double", "大浮点型", "java.lang.Double", Double.class), + FLOAT(31, "Float", "小浮点型", "java.lang.Float", Float.class), + BOOLEAN(40, "Boolean", "布尔值", "java.lang.Boolean", Boolean.class), + BYTE(50, "Byte", "字节", "java.lang.Byte", Byte.class), + DATE(60, "Date", "日期", "java.sql.Timestamp", Date.class); private int value; private String code; private String description; + private String classPath; + private Class clzFullName; - private PROPERTY_TYPE(int value, String code, String description) { + private PROPERTY_TYPE(int value, String code, String description,String classPath,Class clzFullName) { this.value = value; this.code = code; this.description = description; + this.classPath = classPath; + this.clzFullName = clzFullName; } public int getValue() { @@ -932,6 +939,16 @@ public class BlockFormEnumUtil { return tmp; } + public static Class valueOfClzFullName(int val) { + Class tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].value == val) { + tmp = values()[i].clzFullName; + } + } + return tmp; + } + public static int codeOfValue(String code) { int tmp = 1; for (int i = 0; i < values().length; i++) { @@ -942,6 +959,16 @@ public class BlockFormEnumUtil { return tmp; } + public static int codeOfClassPath(String classPath) { + int tmp = 1; + for (int i = 0; i < values().length; i++) { + if (values()[i].classPath.equals(classPath)) { + tmp = values()[i].value; + } + } + return tmp; + } + public static String valueOfDescription(int val) { String tmp = null; for (int i = 0; i < values().length; i++) { diff --git a/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObject.java b/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObject.java index 496d6f8..4953b67 100644 --- a/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObject.java +++ b/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObject.java @@ -67,4 +67,5 @@ public class BfDataObject extends BaseBean { @ApiParam(value = "数据对象属性") @AnnoOutputColumn(hidden = true) private List propertyList; + } diff --git a/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObjectProperty.java b/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObjectProperty.java index 5f6c074..fbedb77 100644 --- a/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObjectProperty.java +++ b/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfDataObjectProperty.java @@ -64,6 +64,10 @@ public class BfDataObjectProperty extends BaseBean { @ApiParam(value ="属性类型") private Integer propertyType; + @Column(name="PROPERTY_TYPE_NAME_RDD") + @ApiParam(value ="属性类型名称") + private String propertyTypeNameRdd; + @Column(name="PROPERTY_DESCRIPTION") @ApiParam(value ="属性描述") private String propertyDescription; diff --git a/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfElementPropertyVirtual.java b/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfElementPropertyVirtual.java index 01ccdb7..00e71ce 100644 --- a/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfElementPropertyVirtual.java +++ b/modules/i3plus-pojo-form/src/main/java/cn/estsh/i3plus/pojo/form/bean/BfElementPropertyVirtual.java @@ -38,7 +38,7 @@ public class BfElementPropertyVirtual extends BaseBean { @JsonSerialize(using = ToStringSerializer.class) private Long elementId; - @Column(name = "PROPERTY_VIRTUAL_TYPE") + @Column(name = "PROPERTY_VIRTUAL_OPERATE_TYPE") @ApiParam(value = "虚拟元素类型") private Integer propertyVirtualType; diff --git a/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlColumnModel.java b/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlColumnModel.java index 81f736e..9c50dec 100644 --- a/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlColumnModel.java +++ b/modules/i3plus-pojo-model/src/main/java/cn/estsh/i3plus/pojo/model/form/SqlColumnModel.java @@ -48,5 +48,10 @@ public class SqlColumnModel { // 字段Java 类型 @ApiParam(value = "字段Java 类型") private String columnClassName; + // 字段Java 类型 + @ApiParam(value = "枚举:BlockFormEnumUtil.PROPERTY_TYPE") + private Integer columnClassType; + + }