From f262d0f0d5b5f94a482d036cc356ec2599131392 Mon Sep 17 00:00:00 2001
From: xiangpei <xiangpei@timesnew.cn>
Date: 星期五, 29 十一月 2024 20:06:34 +0800
Subject: [PATCH] 项目启动流程、变更流程逻辑调整
---
src/views/projectProcess/components/RunProcess.vue | 18 +++++++++++++-----
src/views/projectProcess/index.vue | 8 +++++++-
2 files changed, 20 insertions(+), 6 deletions(-)
diff --git a/src/views/projectProcess/components/RunProcess.vue b/src/views/projectProcess/components/RunProcess.vue
index 7dbee95..92c6530 100644
--- a/src/views/projectProcess/components/RunProcess.vue
+++ b/src/views/projectProcess/components/RunProcess.vue
@@ -10,7 +10,7 @@
<div>
<div style="display: flex; flex-direction: row; justify-content: center; align-items: center;font-size: 24px">
<div>褰撳墠娴佺▼锛�</div>
- <div v-if="nowProcessDefId">{{selectProcessName}}</div>
+ <div v-if="nowProcessDefId">{{selectProcessName}}<span v-if="nowProcessInsId" style="color: red">锛堣繍琛屼腑锛�</span></div>
<div v-else>鏈粦瀹氭祦绋�</div>
</div>
</div>
@@ -74,8 +74,8 @@
</el-table>
</div>
<span slot="footer" class="dialog-footer">
- <el-button type="danger" @click="startProcess" :disable="!this.selectProcessDefId">鍚姩娴佺▼</el-button>
- <el-button type="primary" @click="changeProcess">鍙樻洿</el-button>
+ <el-button type="danger" @click="startProcess" :disabled="(nowProcessInsId !== '') || (selectProcessDefId === '')">鍚姩娴佺▼</el-button>
+ <el-button type="primary" @click="changeProcess" :disabled="((nowProcessDefId === selectProcessDefId) && nowProcessInsId !== '') || selectProcessDefId === '' || nowProcessInsId === ''">娴佺▼鍙樻洿</el-button>
</span>
</el-dialog>
</div>
@@ -100,10 +100,14 @@
required: true,
type: Array
},
- nowProcessDefId: { // 褰撳墠椤圭洰缁戝畾鐨勬祦绋媔d
+ nowProcessDefId: { // 褰撳墠椤圭洰缁戝畾鐨勫畾涔塱d
required: true,
type: String
- }
+ },
+ nowProcessInsId: { // 褰撳墠椤圭洰缁戝畾鐨勫疄渚媔d
+ required: true,
+ type: String
+ },
},
watch: {
// 鐩戝惉鍥炴樉鍊�
@@ -120,6 +124,9 @@
selectProcessDefId: '', // 缁勪欢鍐呴儴閫変腑鐨勬祦绋媔d
selectProcessName: '', // 缁勪欢鍐呴儴閫変腑鐨勬祦绋媔d
}
+ },
+ created() {
+ console.log(this.nowProcessInsId, typeof this.nowProcessInsId, "wwwww")
},
methods: {
setSelect(value) {
@@ -150,6 +157,7 @@
startProcess() {
startProcess(this.projectInfo.projectId, this.selectProcessDefId).then(res => {
this.$message.success(res.msg);
+ this.handleClose()
})
},
// 鍙樻洿娴佺▼
diff --git a/src/views/projectProcess/index.vue b/src/views/projectProcess/index.vue
index e087e8d..675c7bb 100644
--- a/src/views/projectProcess/index.vue
+++ b/src/views/projectProcess/index.vue
@@ -230,6 +230,7 @@
size="medium"
type="text"
icon="el-icon-view"
+ v-if="scope.row.processInsId"
@click="lookProcessDetail(scope.row)"
>
</el-button>
@@ -272,6 +273,7 @@
<RunProcess ref="runProcess" :show="showRunProcess"
:now-process-def-id="nowProcessDefId"
+ :now-process-ins-id="nowProcessInsId"
:project-info="projectRunFrom"
:process-list="processList"
@close="closeRunProcess">
@@ -305,6 +307,7 @@
processList: [],
showRunProcess: false,
nowProcessDefId: '',
+ nowProcessInsId: '',
isImportOrExport: false,
fileDialogVisible: false,
//鏄惁闇�瑕佹柊澧炴寜閽�(鍌ㄨ搫椤圭洰闇�瑕�)
@@ -403,6 +406,8 @@
projectId: null,
projectName: ''
}
+ this.nowProcessDefId = "";
+ this.nowProcessInsId = "";
this.showRunProcess = false
this.getList()
},
@@ -411,7 +416,8 @@
// 鎷垮埌娴佺▼鍒楄〃 TODO 鏍规嵁椤圭洰绫诲瀷鍋氱瓫閫�
getProcessConfigInfoList().then(response => {
this.processList = response.data;
- this.nowProcessDefId = row.processDefId;
+ this.nowProcessDefId = row.processDefId ? row.processDefId : '';
+ this.nowProcessInsId = row.processInsId ? row.processInsId : '';
// // 闃叉锛歩d娌″彉涓嶈Е鍙戠洃鍚�
// this.$refs.runProcess.setSelect(row.flowableProcessId);
this.projectRunFrom.projectId = row.id;
--
Gitblit v1.8.0