mirror of
https://gitee.com/orangeform/orange-admin.git
synced 2026-01-17 10:36:31 +08:00
Merge branch 'master' of https://gitee.com/orangeform/orange-admin
This commit is contained in:
@@ -532,6 +532,30 @@ public class FlowOperationController {
|
|||||||
return ResponseResult.success(StreamUtils.copyToString(in, StandardCharsets.UTF_8));
|
return ResponseResult.success(StreamUtils.copyToString(in, StandardCharsets.UTF_8));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取指定流程定义的指定任务Id的formKey。
|
||||||
|
*
|
||||||
|
* @param processInstanceId 流程实例Id。
|
||||||
|
* @param taskId 流程任务Id。
|
||||||
|
* @return formKey数据。
|
||||||
|
*/
|
||||||
|
@GetMapping("/viewTaskFormKey")
|
||||||
|
public ResponseResult<String> viewTaskFormKey(
|
||||||
|
@RequestParam String processInstanceId, @RequestParam String taskId) throws IOException {
|
||||||
|
TaskInfo task = flowApiService.getTaskById(taskId);
|
||||||
|
if (task == null) {
|
||||||
|
task = flowApiService.getHistoricTaskInstance(processInstanceId, taskId);
|
||||||
|
if (task == null) {
|
||||||
|
return ResponseResult.error(ErrorCodeEnum.DATA_NOT_EXIST);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
UserTask userTask = flowApiService.getUserTask(task.getProcessDefinitionId(), task.getTaskDefinitionKey());
|
||||||
|
if (userTask == null) {
|
||||||
|
return ResponseResult.error(ErrorCodeEnum.DATA_NOT_EXIST);
|
||||||
|
}
|
||||||
|
return ResponseResult.success(userTask.getFormKey());
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取流程图高亮数据。
|
* 获取流程图高亮数据。
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -532,6 +532,30 @@ public class FlowOperationController {
|
|||||||
return ResponseResult.success(StreamUtils.copyToString(in, StandardCharsets.UTF_8));
|
return ResponseResult.success(StreamUtils.copyToString(in, StandardCharsets.UTF_8));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取指定流程定义的指定任务Id的formKey。
|
||||||
|
*
|
||||||
|
* @param processInstanceId 流程实例Id。
|
||||||
|
* @param taskId 流程任务Id。
|
||||||
|
* @return formKey数据。
|
||||||
|
*/
|
||||||
|
@GetMapping("/viewTaskFormKey")
|
||||||
|
public ResponseResult<String> viewTaskFormKey(
|
||||||
|
@RequestParam String processInstanceId, @RequestParam String taskId) throws IOException {
|
||||||
|
TaskInfo task = flowApiService.getTaskById(taskId);
|
||||||
|
if (task == null) {
|
||||||
|
task = flowApiService.getHistoricTaskInstance(processInstanceId, taskId);
|
||||||
|
if (task == null) {
|
||||||
|
return ResponseResult.error(ErrorCodeEnum.DATA_NOT_EXIST);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
UserTask userTask = flowApiService.getUserTask(task.getProcessDefinitionId(), task.getTaskDefinitionKey());
|
||||||
|
if (userTask == null) {
|
||||||
|
return ResponseResult.error(ErrorCodeEnum.DATA_NOT_EXIST);
|
||||||
|
}
|
||||||
|
return ResponseResult.success(userTask.getFormKey());
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取流程图高亮数据。
|
* 获取流程图高亮数据。
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user