From 638801e54b0d20b8fac2b494457e2f3fda60f775 Mon Sep 17 00:00:00 2001 From: zuoqinbo Date: Tue, 14 Nov 2023 10:51:52 +0800 Subject: [PATCH] =?UTF-8?q?feat:1.=E5=85=AC=E5=85=B1=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../core/common/enums/BpmnButtonEnum.java | 69 +++++++++++++++++++ .../core/common/enums/BpmnErrorCode.java | 2 + .../constants/BpmnBtnActionConstants.java | 57 +++++++++++++++ 3 files changed, 128 insertions(+) create mode 100644 workflow-engine-core/src/main/java/cn/axzo/workflow/core/common/enums/BpmnButtonEnum.java create mode 100644 workflow-engine-core/src/main/java/cn/axzo/workflow/core/constants/BpmnBtnActionConstants.java diff --git a/workflow-engine-core/src/main/java/cn/axzo/workflow/core/common/enums/BpmnButtonEnum.java b/workflow-engine-core/src/main/java/cn/axzo/workflow/core/common/enums/BpmnButtonEnum.java new file mode 100644 index 000000000..123ec08fb --- /dev/null +++ b/workflow-engine-core/src/main/java/cn/axzo/workflow/core/common/enums/BpmnButtonEnum.java @@ -0,0 +1,69 @@ +package cn.axzo.workflow.core.common.enums; + +import static cn.axzo.workflow.core.constants.BpmnBtnActionConstants.*; + +/** + * Flowable Event Enum For RocketMQ + * + * @author wangli + * @since 2023/9/4 10:38 + */ +public enum BpmnButtonEnum { + + + /** + * 同意按钮 + */ + BPMN_APPROVE(1, "BPMN_APPROVE", "同意", BPMN_APPROVE_URL), + + + /** + * 拒绝按钮 + */ + BPMN_REJECT(2, "BPMN_REJECT", "拒绝", BPMN_REJECT_URL), + + /** + * 撤回按钮 + */ + BPMN_REVOCATION(3, "BPMN_revocation", "撤回", BPMN_REVOCATION_URL), + + /** + * 转交按钮 + */ + BPMN_FORWARD(4, "BPMN_FORWARD", "转交", BPMN_FORWARD_URL), + + + /** + * 加签按钮 + */ + BPMN_COUNTERSIGN(5, "BPMN_COUNTERSIGN", "加签", BPMN_COUNTERSIGN_URL), + /** + * 评论按钮 + */ + BPMN_COMMENT(6, "BPMN_COMMENT", "评论", BPMN_COMMENT_URL), + + + /** + * 回退按钮 + */ + BPMN_ROLLBACK(7, "BPMN_ROLLBACK", "回退", BPMN_ROLLBACK_URL), + + /** + * 抄送按钮 + */ + BPMN_COPY(8, "BPMN_COPY", "抄送", BPMN_COPY_URL); + + private final int order; + private final String btnKey; + private final String btnAction; + private final String btnName; + + + BpmnButtonEnum(int order, String btnKey, String btnName, String btnAction) { + this.order = order; + this.btnKey = btnKey; + this.btnName = btnName; + this.btnAction = btnAction; + } + +} diff --git a/workflow-engine-core/src/main/java/cn/axzo/workflow/core/common/enums/BpmnErrorCode.java b/workflow-engine-core/src/main/java/cn/axzo/workflow/core/common/enums/BpmnErrorCode.java index d9f33bc8e..c2d944d64 100644 --- a/workflow-engine-core/src/main/java/cn/axzo/workflow/core/common/enums/BpmnErrorCode.java +++ b/workflow-engine-core/src/main/java/cn/axzo/workflow/core/common/enums/BpmnErrorCode.java @@ -49,6 +49,8 @@ public enum BpmnErrorCode implements IProjectRespCode { // ========== bpmn task 06-001 ========== TASK_COMPLETE_FAIL_NOT_EXISTS("06001", "未找到指定审批任务"), TASK_COMPLETE_FAIL_ASSIGN_NOT_SELF("06002", "该任务的审批人不是你"), + TASK_APOSTILLE_NOT_SUPPORT("06003", "当前加签模式不支持"), + // ========== form Model 07-001 ========== FORM_MODEL_NOT_EXISTS("07001", "表单模型不存在"), FORM_MODEL_ID_NOT_EXISTS("07002", "表单模型ID【{}】不存在"), diff --git a/workflow-engine-core/src/main/java/cn/axzo/workflow/core/constants/BpmnBtnActionConstants.java b/workflow-engine-core/src/main/java/cn/axzo/workflow/core/constants/BpmnBtnActionConstants.java new file mode 100644 index 000000000..f5995be11 --- /dev/null +++ b/workflow-engine-core/src/main/java/cn/axzo/workflow/core/constants/BpmnBtnActionConstants.java @@ -0,0 +1,57 @@ +package cn.axzo.workflow.core.constants; + + +/** + * yoke + * + * @author zuoqinbo + * @version V1.0 + * @date 2023/11/13 14:14 + */ +public interface BpmnBtnActionConstants { + + static String WORKFLOW_COMMON_URL = "/api/workflow"; + + /** + * 同意 + */ + static final String BPMN_APPROVE_URL = WORKFLOW_COMMON_URL + "/process/approval"; + + /** + * 拒绝 + */ + static final String BPMN_REJECT_URL = WORKFLOW_COMMON_URL + "/process/reject"; + + /** + * 加签 + */ + static final String BPMN_COUNTERSIGN_URL = WORKFLOW_COMMON_URL + "/process/countersign"; + + /** + * 评论 + */ + static final String BPMN_COMMENT_URL = WORKFLOW_COMMON_URL + "/process/comment"; + + /** + * 抄送 + */ + static final String BPMN_COPY_URL = WORKFLOW_COMMON_URL + "/process/copy"; + + + /** + * 转交 + */ + static final String BPMN_FORWARD_URL = WORKFLOW_COMMON_URL + "/process/forward"; + + /** + * 撤回 + */ + static final String BPMN_REVOCATION_URL = WORKFLOW_COMMON_URL + "/process/revocation"; + + + /** + * 回退 + */ + static final String BPMN_ROLLBACK_URL = WORKFLOW_COMMON_URL + "/process/rollback"; + +}