refactor:【BPM 工作流】 针对TODO 更新流程相关接口和组件,优化文档提示,调整表单字段类型
This commit is contained in:
@@ -4,6 +4,7 @@ import { requestClient } from '#/api/request';
|
||||
|
||||
/** 流程定义 */
|
||||
export namespace BpmProcessDefinitionApi {
|
||||
// 流程定义
|
||||
export interface ProcessDefinitionVO {
|
||||
id: string;
|
||||
version: number;
|
||||
|
||||
@@ -3,7 +3,7 @@ import type { PageParam, PageResult } from '@vben/request';
|
||||
import { requestClient } from '#/api/request';
|
||||
|
||||
export namespace BpmFormApi {
|
||||
// TODO @siye:注释加一个。。嘿嘿
|
||||
// 流程表单
|
||||
export interface FormVO {
|
||||
id?: number | undefined;
|
||||
name: string;
|
||||
@@ -11,7 +11,7 @@ export namespace BpmFormApi {
|
||||
fields: string[];
|
||||
status: number;
|
||||
remark: string;
|
||||
createTime: string;
|
||||
createTime: number;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,7 +23,7 @@ export async function getFormPage(params: PageParam) {
|
||||
}
|
||||
|
||||
/** 获取表单详情 */
|
||||
export async function getFormDetail(id: number) {
|
||||
export async function getFormDetail(id: number | string) {
|
||||
return requestClient.get<BpmFormApi.FormVO>(`/bpm/form/get?id=${id}`);
|
||||
}
|
||||
|
||||
|
||||
@@ -40,6 +40,7 @@ export namespace BpmProcessInstanceApi {
|
||||
tasks: ApprovalTaskInfo[];
|
||||
};
|
||||
|
||||
// 流程实例
|
||||
export type ProcessInstanceVO = {
|
||||
businessKey: string;
|
||||
category: string;
|
||||
@@ -59,6 +60,7 @@ export namespace BpmProcessInstanceApi {
|
||||
tasks?: BpmProcessInstanceApi.Task[];
|
||||
};
|
||||
|
||||
// 审批详情
|
||||
export type ApprovalDetail = {
|
||||
activityNodes: BpmProcessInstanceApi.ApprovalNodeInfo[];
|
||||
formFieldsPermission: any;
|
||||
@@ -66,6 +68,25 @@ export namespace BpmProcessInstanceApi {
|
||||
processInstance: BpmProcessInstanceApi.ProcessInstanceVO;
|
||||
status: number;
|
||||
};
|
||||
|
||||
// 抄送流程实例 VO
|
||||
export type CopyVO = {
|
||||
id: number;
|
||||
startUser: User;
|
||||
processInstanceId: string;
|
||||
processInstanceName: string;
|
||||
processInstanceStartTime: number;
|
||||
activityId: string;
|
||||
activityName: string;
|
||||
taskId: string;
|
||||
reason: string;
|
||||
createUser: User;
|
||||
createTime: number;
|
||||
summary: {
|
||||
key: string;
|
||||
value: string;
|
||||
}[];
|
||||
};
|
||||
}
|
||||
|
||||
/** 查询我的流程实例分页 */
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import type { PageParam, PageResult } from '@vben/request';
|
||||
|
||||
import type { BpmProcessInstanceApi } from '../processInstance';
|
||||
|
||||
import { requestClient } from '#/api/request';
|
||||
|
||||
export namespace BpmTaskApi {
|
||||
@@ -11,7 +13,33 @@ export namespace BpmTaskApi {
|
||||
status: number; // 监听器状态
|
||||
event: string; // 监听事件
|
||||
valueType: string; // 监听器值类型
|
||||
value: string; // 监听器值
|
||||
}
|
||||
|
||||
// 流程任务 VO
|
||||
export interface TaskManagerVO {
|
||||
id: string; // 编号
|
||||
name: string; // 任务名称
|
||||
createTime: number; // 创建时间
|
||||
endTime: number; // 结束时间
|
||||
durationInMillis: number; // 持续时间
|
||||
status: number; // 状态
|
||||
reason: string; // 原因
|
||||
ownerUser: any; // 负责人
|
||||
assigneeUser: any; // 处理人
|
||||
taskDefinitionKey: string; // 任务定义key
|
||||
processInstanceId: string; // 流程实例id
|
||||
processInstance: BpmProcessInstanceApi.ProcessInstanceVO; // 流程实例
|
||||
parentTaskId: any; // 父任务id
|
||||
children: any; // 子任务
|
||||
formId: any; // 表单id
|
||||
formName: any; // 表单名称
|
||||
formConf: any; // 表单配置
|
||||
formFields: any; // 表单字段
|
||||
formVariables: any; // 表单变量
|
||||
buttonsSetting: any; // 按钮设置
|
||||
signEnable: any; // 签名设置
|
||||
reasonRequire: any; // 原因设置
|
||||
nodeType: any; // 节点类型
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user