diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/PtlEnumUtil.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/PtlEnumUtil.java index 128e322..9b2b76a 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/PtlEnumUtil.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/PtlEnumUtil.java @@ -11,6 +11,31 @@ import com.fasterxml.jackson.annotation.JsonFormat; public class PtlEnumUtil { /** + * 方法类型 + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum PTL_METHOD_TYPE { + INTERFACE(10, "界面方法"), + MONITOR(20, "监听方法"); + + private int value; + private String description; + + PTL_METHOD_TYPE(int value, String description) { + this.value = value; + this.description = description; + } + + public int getValue() { + return value; + } + + public String getDescription() { + return description; + } + } + + /** * 流程状态-触发类型 */ @JsonFormat(shape = JsonFormat.Shape.OBJECT) diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/PtlPcnEnumUtil.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/PtlPcnEnumUtil.java index 7889a71..3d1fc0d 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/PtlPcnEnumUtil.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/PtlPcnEnumUtil.java @@ -3,8 +3,6 @@ package cn.estsh.i3plus.pojo.base.enumutil; import com.fasterxml.jackson.annotation.JsonFormat; import org.springframework.util.StringUtils; -import static cn.estsh.i3plus.pojo.base.enumutil.PtlPcnEnumUtil.MONITOR_PROCESS_MESSAGE_TYPE.*; - /** * @author Wynne.Lu * @date 2020/2/12 17:41 @@ -732,164 +730,6 @@ public class PtlPcnEnumUtil { } /** - * 监听消息类型 - */ - @JsonFormat(shape = JsonFormat.Shape.OBJECT) - public enum MONITOR_PROCESS_MESSAGE_TYPE { - CONNECT_CONTROL_CMD(10, "CONNECT_CONTROL_CMD", "connectControlService", "连接控制器"), - DISCONNECT_CONTROL_CMD(20, "DISCONNECT_CONTROL_CMD", "disconnectControlService", "断开控制器"), - EXCEPTION_DISCONNECT_CONTROL_CMD(25, "EXCEPTION_DISCONNECT_CONTROL_CMD", "disconnectControlService", "断开控制器"), - LIGHT_ON_CMD(30, "LIGHT_ON_CMD", "lightOnService", "亮灯命令"), - LIGHT_OFF_CMD(40, "LIGHT_OFF_CMD", "lightOffService", "灭灯命令"), - CONTROL_SIGNAL_CMD(50, "CONTROL_SIGNAL_CMD", "controlSignalService", "控制器反馈信号"), - INTERFACE_SIGNAL_CMD(60, "INTERFACE_SIGNAL_CMD", "", "发送给界面actor通过websocket返回"), - REFRESH_CONTROL_CMD(70, "REFRESH_CONTROL_CMD", "refreshControlService", "刷新"); - - private int value; - private String code; - private String callClass; - private String description; - - MONITOR_PROCESS_MESSAGE_TYPE(int value, String code, String callClass, String description) { - this.value = value; - this.code = code; - this.callClass = callClass; - this.description = description; - } - - public int getValue() { - return value; - } - - public String getCode() { - return code; - } - - public String getCallClass() { - return callClass; - } - - public String getDescription() { - return description; - } - - public static MONITOR_PROCESS_MESSAGE_TYPE getTypeByValue(String code) { - if (StringUtils.isEmpty(code)) { - return null; - } - for (MONITOR_PROCESS_MESSAGE_TYPE enums : values()) { - if (enums.getCode().equals(code)) { - return enums; - } - } - return null; - } - } - - /** - * 界面消息类型 - */ - @JsonFormat(shape = JsonFormat.Shape.OBJECT) - public enum INTERFACE_SIGNAL_MESSAGE_TYPE { - CONNECT_CONTROL_CMD(10, "CONNECT_CONTROL_CMD", "connectControlService", "连接控制器"), - DISCONNECT_CONTROL_CMD(20, "DISCONNECT_CONTROL_CMD", "disconnectControlService", "断开控制器"), - REFRESH_CONTROL_CMD(30, "REFRESH_CONTROL_CMD", "refreshControlService", "刷新"), - SCAN_CONTROL_CMD(40, "SCAN_CONTROL_CMD", "scanControlService", "扫描"), - INIT_MODULE_CONTROL_CMD(50, "INIT_MODULE_CONTROL_CMD", "initModuleControlService", "初始化页面"); -// UNLOCK_CONTROL_CMD(50, "UNLOCK_CONTROL_CMD", "unlockControlService", "解锁"), -// LABEL_SELF_CHECK_CONTROL_CMD(60, "labelSelfCheck", "labelSelfCheckControlService", "标签自检"), -// LIGHT_DETAIL_CONTROL_CMD(70, "LABEL_SELF_CHECK_CONTROL_CMD", "lightDetailControlService", "亮灯明细"); - - private int value; - private String code; - private String callClass; - private String description; - - INTERFACE_SIGNAL_MESSAGE_TYPE(int value, String code, String callClass, String description) { - this.value = value; - this.code = code; - this.callClass = callClass; - this.description = description; - } - - public int getValue() { - return value; - } - - public String getCallClass() { - return callClass; - } - - public String getCode() { - return code; - } - - public String getDescription() { - return description; - } - - public static INTERFACE_SIGNAL_MESSAGE_TYPE getTypeByValue(String code) { - if (StringUtils.isEmpty(code)) { - return null; - } - for (INTERFACE_SIGNAL_MESSAGE_TYPE enums : INTERFACE_SIGNAL_MESSAGE_TYPE.values()) { - if (enums.getCode().equals(code)) { - return enums; - } - } - return null; - } - } - - /** - * 任务消息类型 - */ - @JsonFormat(shape = JsonFormat.Shape.OBJECT) - public enum GEN_TASK_MESSAGE_TYPE { - GEN_TASK_CMD(10, "GEN_TASK_CMD", "", "生成任务"); - - private int value; - private String code; - private String callClass; - private String description; - - GEN_TASK_MESSAGE_TYPE(int value, String code, String callClass, String description) { - this.value = value; - this.code = code; - this.callClass = callClass; - this.description = description; - } - - public int getValue() { - return value; - } - - public String getCallClass() { - return callClass; - } - - public String getCode() { - return code; - } - - public String getDescription() { - return description; - } - - public static INTERFACE_SIGNAL_MESSAGE_TYPE getTypeByValue(String code) { - if (StringUtils.isEmpty(code)) { - return null; - } - for (INTERFACE_SIGNAL_MESSAGE_TYPE enums : INTERFACE_SIGNAL_MESSAGE_TYPE.values()) { - if (enums.getCode().equals(code)) { - return enums; - } - } - return null; - } - } - - /** * websocket业务类型 */ @JsonFormat(shape = JsonFormat.Shape.OBJECT) diff --git a/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/bean/PtlAreaActorAction.java b/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/bean/PtlAreaActorAction.java index caf5c46..ad66202 100644 --- a/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/bean/PtlAreaActorAction.java +++ b/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/bean/PtlAreaActorAction.java @@ -12,6 +12,7 @@ import org.hibernate.annotations.DynamicUpdate; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.Table; +import javax.persistence.Transient; import java.io.Serializable; /** @@ -47,7 +48,11 @@ public class PtlAreaActorAction extends BaseBean implements Serializable { @ApiParam("特定条件") private String otherWhere; - @Column(name = "AMG_ID") - @ApiParam("组件集编号") - private Long amgId; + @Column(name = "METHOD_CODE") + @ApiParam("方法代码") + private String methodCode; + + @Transient + @ApiParam("实现类") + private String callClass; } diff --git a/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/bean/PtlMethod.java b/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/bean/PtlMethod.java new file mode 100644 index 0000000..cd2ba93 --- /dev/null +++ b/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/bean/PtlMethod.java @@ -0,0 +1,49 @@ +package cn.estsh.i3plus.pojo.ptl.bean; + +import cn.estsh.i3plus.pojo.base.bean.BaseBean; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiParam; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.hibernate.annotations.DynamicInsert; +import org.hibernate.annotations.DynamicUpdate; + +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.Table; +import java.io.Serializable; + +/** + * @author Wynne.Lu + * @date 2020/2/14 11:18 + * @desc + */ +@Data +@Entity +@DynamicInsert +@DynamicUpdate +@Table(name = "PTL_METHOD") +@EqualsAndHashCode(callSuper = true) +@Api("方法清单") +public class PtlMethod extends BaseBean implements Serializable { + + private static final long serialVersionUID = 1208980343927922927L; + + @Column(name = "METHOD_CODE") + @ApiParam("方法代码") + private String methodCode; + + @Column(name = "METHOD_NAME") + @ApiParam("方法描述") + private String methodName; + + @Column(name = "CALL_CLASS") + @ApiParam("实现类") + private String callClass; + + @Column(name = "METHOD_TYPE") + @ApiParam("方法类型") + private Integer methodType; + + +} diff --git a/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/repository/PtlAreaActorActionRepository.java b/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/repository/PtlAreaActorActionRepository.java new file mode 100644 index 0000000..8eba13c --- /dev/null +++ b/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/repository/PtlAreaActorActionRepository.java @@ -0,0 +1,15 @@ +package cn.estsh.i3plus.pojo.ptl.repository; + + +import cn.estsh.i3plus.pojo.base.jpa.dao.BaseRepository; +import cn.estsh.i3plus.pojo.ptl.bean.PtlAreaActorAction; + +/** + * @author Wynne.Lu + * @date 2020/2/12 17:41 + * @desc + */ + +public interface PtlAreaActorActionRepository extends BaseRepository { + +} diff --git a/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/repository/PtlMethodRepository.java b/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/repository/PtlMethodRepository.java new file mode 100644 index 0000000..2737250 --- /dev/null +++ b/modules/i3plus-pojo-ptl/src/main/java/cn/estsh/i3plus/pojo/ptl/repository/PtlMethodRepository.java @@ -0,0 +1,15 @@ +package cn.estsh.i3plus.pojo.ptl.repository; + + +import cn.estsh.i3plus.pojo.base.jpa.dao.BaseRepository; +import cn.estsh.i3plus.pojo.ptl.bean.PtlMethod; + +/** + * @author Wynne.Lu + * @date 2020/2/12 17:41 + * @desc + */ + +public interface PtlMethodRepository extends BaseRepository { + +}