feat: 更新sql文件 添加工作流样式接口

This commit is contained in:
lihao05
2025-10-24 10:13:01 +08:00
parent 0ce0ce1262
commit 73e588ac60
3 changed files with 192 additions and 99 deletions

View File

@@ -83,6 +83,17 @@ public class WorkflowController {
return R.ok(workflowService.search(keyword, isPublic, null, currentPage, pageSize));
}
/**
* 获取当前用户可访问的工作流详情
*
* @param uuid 工作流唯一标识
* @return 工作流详情
*/
@GetMapping("/{uuid}")
public R<WorkflowResp> getDetail(@PathVariable String uuid) {
return R.ok(workflowService.getDetail(uuid));
}
/**
* 搜索公开工作流
*
@@ -98,6 +109,33 @@ public class WorkflowController {
return R.ok(workflowService.searchPublic(keyword, currentPage, pageSize));
}
/**
* 搜索公开工作流
*
* @param keyword 搜索关键词
* @param currentPage 当前页数
* @param pageSize 每页数量
* @return 工作流列表
*/
@GetMapping("/search")
public R<Page<WorkflowResp>> search(@RequestParam(defaultValue = "") String keyword,
@NotNull @Min(1) Integer currentPage,
@NotNull @Min(10) Integer pageSize) {
return R.ok(workflowService.search(keyword, currentPage, pageSize));
}
/**
* 获取公开工作流详情
*
* @param uuid 工作流唯一标识
* @return 工作流详情
*/
@GetMapping("/public/{uuid}")
public R<WorkflowResp> getPublicDetail(@PathVariable String uuid) {
return R.ok(workflowService.getPublicDetail(uuid));
}
@GetMapping("/public/operators")
public R<List<Map<String, String>>> searchPublic() {
List<Map<String, String>> result = new ArrayList<>();