fix 修复 一些问题
This commit is contained in:
parent
e8d42a5434
commit
df129b08bf
@ -53,6 +53,7 @@ export const deleteDefinition = (id: string | string[]) => {
|
|||||||
/**
|
/**
|
||||||
* 挂起/激活
|
* 挂起/激活
|
||||||
* @param definitionId 流程定义id
|
* @param definitionId 流程定义id
|
||||||
|
* @param activityStatus 状态
|
||||||
* @returns
|
* @returns
|
||||||
*/
|
*/
|
||||||
export const active = (definitionId: string, activityStatus: boolean) => {
|
export const active = (definitionId: string, activityStatus: boolean) => {
|
||||||
@ -60,7 +61,7 @@ export const active = (definitionId: string, activityStatus: boolean) => {
|
|||||||
url: `/workflow/definition/active/${definitionId}`,
|
url: `/workflow/definition/active/${definitionId}`,
|
||||||
method: 'put',
|
method: 'put',
|
||||||
params: {
|
params: {
|
||||||
activityStatus: activityStatus
|
active: activityStatus
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
@ -11,7 +11,7 @@ export interface FlowDefinitionVo {
|
|||||||
flowCode: string;
|
flowCode: string;
|
||||||
version: string;
|
version: string;
|
||||||
isPublish: number;
|
isPublish: number;
|
||||||
activityStatus: boolean;
|
activityStatus: number;
|
||||||
createTime: Date;
|
createTime: Date;
|
||||||
updateTime: Date;
|
updateTime: Date;
|
||||||
}
|
}
|
||||||
|
@ -16,7 +16,7 @@ export interface FlowInstanceVO extends BaseEntity {
|
|||||||
flowCode: string;
|
flowCode: string;
|
||||||
version: string;
|
version: string;
|
||||||
businessId: string;
|
businessId: string;
|
||||||
activityStatus?: any;
|
activityStatus: number;
|
||||||
tenantId: string;
|
tenantId: string;
|
||||||
createTime: string;
|
createTime: string;
|
||||||
createBy: string;
|
createBy: string;
|
||||||
|
@ -224,7 +224,7 @@ const handleCancelProcessApply = async (id: string) => {
|
|||||||
loading.value = true;
|
loading.value = true;
|
||||||
let data = {
|
let data = {
|
||||||
businessId: id,
|
businessId: id,
|
||||||
message: '撤销流程!'
|
message: '申请人撤销流程!'
|
||||||
};
|
};
|
||||||
await cancelProcessApply(data).finally(() => (loading.value = false));
|
await cancelProcessApply(data).finally(() => (loading.value = false));
|
||||||
await getList();
|
await getList();
|
||||||
|
@ -71,7 +71,7 @@
|
|||||||
<el-tag v-else-if="scope.row.activityStatus == 1" type="success">激活</el-tag>
|
<el-tag v-else-if="scope.row.activityStatus == 1" type="success">激活</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column align="center" prop="isPublish" label="发布状态" width="80">
|
<el-table-column align="center" prop="isPublish" label="发布状态" width="100">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tag v-if="scope.row.isPublish == 0" type="danger">未发布</el-tag>
|
<el-tag v-if="scope.row.isPublish == 0" type="danger">未发布</el-tag>
|
||||||
<el-tag v-else-if="scope.row.isPublish == 1" type="success">已发布</el-tag>
|
<el-tag v-else-if="scope.row.isPublish == 1" type="success">已发布</el-tag>
|
||||||
@ -86,10 +86,10 @@
|
|||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
size="small"
|
size="small"
|
||||||
:icon="!scope.row.activityStatus ? 'Lock' : 'Unlock'"
|
:icon="scope.row.activityStatus == 0 ? 'Lock' : 'Unlock'"
|
||||||
@click="handleProcessDefState(scope.row)"
|
@click="handleProcessDefState(scope.row)"
|
||||||
>
|
>
|
||||||
{{ scope.row.activityStatus ? '挂起流程' : '激活流程' }}
|
{{ scope.row.activityStatus == 0 ? '激活流程' : '挂起流程' }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="1.5">
|
<el-col :span="1.5">
|
||||||
@ -423,14 +423,14 @@ const handlePublish = async (row?: FlowDefinitionVo) => {
|
|||||||
/** 挂起/激活 */
|
/** 挂起/激活 */
|
||||||
const handleProcessDefState = async (row: FlowDefinitionVo) => {
|
const handleProcessDefState = async (row: FlowDefinitionVo) => {
|
||||||
let msg: string;
|
let msg: string;
|
||||||
if (row.activityStatus) {
|
if (row.activityStatus == 1) {
|
||||||
msg = `暂停后,此流程下的所有任务都不允许往后流转,您确定挂起【${row.flowName || row.flowCode}】吗?`;
|
msg = `暂停后,此流程下的所有任务都不允许往后流转,您确定挂起【${row.flowName || row.flowCode}】吗?`;
|
||||||
} else {
|
} else {
|
||||||
msg = `启动后,此流程下的所有任务都允许往后流转,您确定激活【${row.flowName || row.flowCode}】吗?`;
|
msg = `启动后,此流程下的所有任务都允许往后流转,您确定激活【${row.flowName || row.flowCode}】吗?`;
|
||||||
}
|
}
|
||||||
await proxy?.$modal.confirm(msg);
|
await proxy?.$modal.confirm(msg);
|
||||||
loading.value = true;
|
loading.value = true;
|
||||||
await active(row.id, row.activityStatus).finally(() => (loading.value = false));
|
await active(row.id, row.activityStatus == 0).finally(() => (loading.value = false));
|
||||||
await getList();
|
await getList();
|
||||||
proxy?.$modal.msgSuccess('操作成功');
|
proxy?.$modal.msgSuccess('操作成功');
|
||||||
};
|
};
|
||||||
|
@ -232,7 +232,7 @@ const handleCancelProcessApply = async (businessId: string) => {
|
|||||||
if ('running' === tab.value) {
|
if ('running' === tab.value) {
|
||||||
let data = {
|
let data = {
|
||||||
businessId: businessId,
|
businessId: businessId,
|
||||||
message: '撤销流程!'
|
message: '申请人撤销流程!'
|
||||||
};
|
};
|
||||||
await cancelProcessApply(data).finally(() => (loading.value = false));
|
await cancelProcessApply(data).finally(() => (loading.value = false));
|
||||||
getList();
|
getList();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user