From f6b61a485501f326debe52d77ea65d87fb34b37f Mon Sep 17 00:00:00 2001
From: 田源 <tianyuan@vci-tech.com>
Date: 星期三, 05 三月 2025 17:57:09 +0800
Subject: [PATCH] 完善集成日志查询

---
 Source/UBCS-WEB/src/views/flow/manager.vue |   34 +++++++++++++++++++---------------
 1 files changed, 19 insertions(+), 15 deletions(-)

diff --git a/Source/UBCS-WEB/src/views/flow/manager.vue b/Source/UBCS-WEB/src/views/flow/manager.vue
index af5c5c4..0e4db1b 100644
--- a/Source/UBCS-WEB/src/views/flow/manager.vue
+++ b/Source/UBCS-WEB/src/views/flow/manager.vue
@@ -25,19 +25,21 @@
         <el-button type="text"
                    size="small"
                    icon="el-icon-refresh"
-                   v-if="permission.flow_manager_state"
-                   @click.stop="handleState(scope.row,scope.index)">鍙樻洿鐘舵��
+                   :style="{color: scope.row.suspensionState === 1 ? '#67C23A' : '#F56C6C'}"
+                   v-if="permissionList.state"
+                   @click.stop="handleDoState(scope.row, scope.index)">
+          {{ scope.row.suspensionState === 1 ? '婵�娲�' : '鎸傝捣' }}
         </el-button>
         <el-button type="text"
                    size="small"
                    icon="el-icon-search"
-                   v-if="permission.flow_manager_image"
+                   v-if="permissionList.image"
                    @click.stop="handleImage(scope.row,scope.index)">娴佺▼鍥�
         </el-button>
         <el-button type="text"
                    size="small"
                    icon="el-icon-delete"
-                   v-if="permission.flow_manager_remove"
+                   v-if="permissionList.delBtn"
                    @click.stop="handleSlotDelete(scope.row,scope.index)">鍒犻櫎
         </el-button>
       </template>
@@ -119,7 +121,7 @@
         }],
         option: {
           height: 'auto',
-          calcHeight: 30,
+          calcHeight: 20,
           columnBtn:false,
           tip: false,
           searchShow: true,
@@ -203,7 +205,9 @@
       ...mapGetters(["permission"]),
       permissionList() {
         return {
-          delBtn: this.vaildData(this.permission.flow_manager_remove, false),
+          state:this.vaildData(this.permission.flow_manager.flow_manager_state, false),
+          image:this.vaildData(this.permission.flow_manager.flow_manager_image, false),
+          delBtn: this.vaildData(this.permission.flow_manager.flow_manager_delete, false),
         };
       },
       ids() {
@@ -290,15 +294,15 @@
         this.stateBox = true;
         this.selectionId = row.id;
       },
-      handleDoState() {
-        if (!this.flowState) {
-          this.$message({
-            type: "warn",
-            message: "璇峰厛閫夋嫨娴佺▼鐘舵��!"
-          });
-          return;
-        }
-        changeState({processId: this.selectionId, state: this.flowState}).then(res => {
+      handleDoState(row) {
+        // if (!this.flowState) {
+        //   this.$message({
+        //     type: "warn",
+        //     message: "璇峰厛閫夋嫨娴佺▼鐘舵��!"
+        //   });
+        //   return;
+        // }
+        changeState({processId: row.id, state: (row.suspensionState === 1 ? 'suspend' : 'active')}).then(res => {
           const data = res.data;
           if (data.success) {
             this.$message({

--
Gitblit v1.9.3