mirror of
http://git.pig4cloud.com/pig/pigx.git
synced 2026-11-13 22:09:00 +08:00
feat(flow): 适配 form-design 表单设计器
This commit is contained in:
1 parent
667cc7397f
commit
b8a4086970
41 files changed
+672
-794
No files matched your search
+2
-4
@@ -3,7 +3,6 @@ package com.pig4cloud.pigx.flow.task.api.feign;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.pig4cloud.pigx.common.core.constant.ServiceNameConstants;
|
||||
import com.pig4cloud.pigx.common.core.util.R;
|
||||
import com.pig4cloud.pigx.common.feign.annotation.NoToken;
|
||||
import com.pig4cloud.pigx.flow.task.dto.*;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
@@ -49,7 +48,6 @@ public interface RemoteFlowEngineService {
|
||||
* @param processInstanceParamDto 流程实例参数
|
||||
* @return 启动流程结果
|
||||
*/
|
||||
@NoToken
|
||||
@PostMapping("/flow/start")
|
||||
R<String> startProcess(@RequestBody ProcessInstanceParamDto processInstanceParamDto);
|
||||
|
||||
@@ -82,8 +80,8 @@ public interface RemoteFlowEngineService {
|
||||
* @param taskParamDto 任务参数
|
||||
* @return 设置负责人结果
|
||||
*/
|
||||
@PostMapping("/task/setAssignee")
|
||||
R<String> setAssignee(@RequestBody TaskParamDto taskParamDto);
|
||||
@PostMapping("/task/transferTask")
|
||||
R<String> transferTask(@RequestBody TaskParamDto taskParamDto);
|
||||
|
||||
/**
|
||||
* 停止流程实例
|
||||
|
||||
-7
@@ -2,7 +2,6 @@ package com.pig4cloud.pigx.flow.task.api.feign;
|
||||
|
||||
import com.pig4cloud.pigx.common.core.constant.ServiceNameConstants;
|
||||
import com.pig4cloud.pigx.common.core.util.R;
|
||||
import com.pig4cloud.pigx.common.feign.annotation.NoToken;
|
||||
import com.pig4cloud.pigx.flow.task.dto.*;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
@@ -23,7 +22,6 @@ public interface RemoteFlowTaskService {
|
||||
* 节点开始事件
|
||||
* @param nodeRecordParamDto
|
||||
*/
|
||||
@NoToken
|
||||
@PostMapping("/remote/startNodeEvent")
|
||||
void startNodeEvent(@RequestBody ProcessNodeRecordParamDto nodeRecordParamDto);
|
||||
|
||||
@@ -31,7 +29,6 @@ public interface RemoteFlowTaskService {
|
||||
* 节点结束事件
|
||||
* @param nodeRecordParamDto
|
||||
*/
|
||||
@NoToken
|
||||
@PostMapping("/remote/endNodeEvent")
|
||||
void endNodeEvent(@RequestBody ProcessNodeRecordParamDto nodeRecordParamDto);
|
||||
|
||||
@@ -46,7 +43,6 @@ public interface RemoteFlowTaskService {
|
||||
* 创建流程事件
|
||||
* @param processInstanceRecordParamDto
|
||||
*/
|
||||
@NoToken
|
||||
@PostMapping("/remote/createProcessEvent")
|
||||
void createProcessEvent(@RequestBody ProcessInstanceRecordParamDto processInstanceRecordParamDto);
|
||||
|
||||
@@ -77,7 +73,6 @@ public interface RemoteFlowTaskService {
|
||||
* @param nodeId 节点id
|
||||
* @return
|
||||
*/
|
||||
@NoToken
|
||||
@GetMapping("/processNodeData/getNodeData")
|
||||
R<Node> queryNodeOriData(@RequestParam("flowId") String flowId, @RequestParam("nodeId") String nodeId);
|
||||
|
||||
@@ -85,7 +80,6 @@ public interface RemoteFlowTaskService {
|
||||
* 节点开始指派用户了
|
||||
* @param processNodeRecordAssignUserParamDto
|
||||
*/
|
||||
@NoToken
|
||||
@PostMapping("/remote/startAssignUser")
|
||||
R startAssignUser(@RequestBody ProcessNodeRecordAssignUserParamDto processNodeRecordAssignUserParamDto);
|
||||
|
||||
@@ -93,7 +87,6 @@ public interface RemoteFlowTaskService {
|
||||
* 任务结束事件
|
||||
* @param processNodeRecordAssignUserParamDto
|
||||
*/
|
||||
@NoToken
|
||||
@PostMapping("/remote/taskEndEvent")
|
||||
R taskEndEvent(@RequestBody ProcessNodeRecordAssignUserParamDto processNodeRecordAssignUserParamDto);
|
||||
|
||||
|
||||
+4
-2
@@ -61,8 +61,10 @@ public interface IBaseEnum<T> {
|
||||
Objects.requireNonNull(label);
|
||||
EnumSet<E> allEnums = EnumSet.allOf(clazz); // 获取类型下的所有枚举
|
||||
String finalLabel = label;
|
||||
E matchEnum = allEnums.stream().filter(e -> ObjectUtil.equal(e.getLabel(), finalLabel)).findFirst()
|
||||
.orElse(null);
|
||||
E matchEnum = allEnums.stream()
|
||||
.filter(e -> ObjectUtil.equal(e.getLabel(), finalLabel))
|
||||
.findFirst()
|
||||
.orElse(null);
|
||||
|
||||
Object value = null;
|
||||
if (matchEnum != null) {
|
||||
|
||||
+38
-35
@@ -7,53 +7,56 @@ import java.util.Map;
|
||||
|
||||
/**
|
||||
* 任务完成参数对象
|
||||
*
|
||||
*/
|
||||
@Data
|
||||
public class TaskParamDto {
|
||||
|
||||
private String processInstanceId;
|
||||
private String processInstanceId;
|
||||
|
||||
private List<String> processInstanceIdList;
|
||||
private List<String> processInstanceIdList;
|
||||
|
||||
/**
|
||||
* 节点id
|
||||
*/
|
||||
private String nodeId;
|
||||
/**
|
||||
* 节点id
|
||||
*/
|
||||
private String nodeId;
|
||||
|
||||
/**
|
||||
* 添加子流程发起人
|
||||
*/
|
||||
private Boolean appendChildProcessRootId;
|
||||
/**
|
||||
* 添加子流程发起人
|
||||
*/
|
||||
private Boolean appendChildProcessRootId;
|
||||
|
||||
/**
|
||||
* 任务id
|
||||
*/
|
||||
private String taskId;
|
||||
/**
|
||||
* 任务id
|
||||
*/
|
||||
private String taskId;
|
||||
|
||||
/**
|
||||
* 用户id
|
||||
*/
|
||||
private String userId;
|
||||
/**
|
||||
* 用户id
|
||||
*/
|
||||
private String userId;
|
||||
|
||||
/**
|
||||
* 模板用户id
|
||||
*/
|
||||
private String targetUserId;
|
||||
/**
|
||||
* 模板用户id
|
||||
*/
|
||||
private String targetUserId;
|
||||
|
||||
/**
|
||||
* 参数
|
||||
*/
|
||||
private Map<String, Object> paramMap;
|
||||
/**
|
||||
* 参数
|
||||
*/
|
||||
private Map<String, Object> paramMap;
|
||||
|
||||
/**
|
||||
* 任务本地变量
|
||||
*/
|
||||
private Map<String, Object> taskLocalParamMap;
|
||||
/**
|
||||
* 任务本地变量
|
||||
*/
|
||||
private Map<String, Object> taskLocalParamMap;
|
||||
|
||||
/**
|
||||
* 模板节点
|
||||
*/
|
||||
private String targetNodeId;
|
||||
/**
|
||||
* 模板节点
|
||||
*/
|
||||
private String targetNodeId;
|
||||
|
||||
/**
|
||||
* 转办目标用户 ID 列表
|
||||
*/
|
||||
private List<Long> targetUserIdList;
|
||||
}
|
||||
+4
-1
@@ -2,12 +2,14 @@ package com.pig4cloud.pigx.flow.task.vo;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.experimental.FieldNameConstants;
|
||||
|
||||
/**
|
||||
* 表单
|
||||
*/
|
||||
@Data
|
||||
@NoArgsConstructor
|
||||
@FieldNameConstants
|
||||
public class FormItemVO {
|
||||
|
||||
private String id;
|
||||
@@ -26,10 +28,11 @@ public class FormItemVO {
|
||||
|
||||
private String placeholder;
|
||||
|
||||
private Props props;
|
||||
private Props props = new Props();
|
||||
|
||||
@Data
|
||||
@NoArgsConstructor
|
||||
@FieldNameConstants
|
||||
public static class Props {
|
||||
|
||||
private Object value;
|
||||
|
||||
+5
@@ -16,4 +16,9 @@ public class ProcessVO extends Process {
|
||||
|
||||
private Map<String, Object> variableMap;
|
||||
|
||||
/**
|
||||
* 发起人节点的表单权限
|
||||
*/
|
||||
private Map<String, String> formPerms;
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user