From 63920d1bb92934520a38993d00c6768e2cefd19c Mon Sep 17 00:00:00 2001
From: 田源 <tianyuan@vci-tech.com>
Date: 星期二, 24 十二月 2024 18:02:22 +0800
Subject: [PATCH] 业务类型一致性检查未知&&默认折叠菜单&&生命周期按钮

---
 Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/lifeCycle/index.vue |   67 +++++++++++----------------------
 1 files changed, 22 insertions(+), 45 deletions(-)

diff --git a/Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/lifeCycle/index.vue b/Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/lifeCycle/index.vue
index 142b70c..fcb4e6e 100644
--- a/Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/lifeCycle/index.vue
+++ b/Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/lifeCycle/index.vue
@@ -1,21 +1,20 @@
 <template>
   <el-container>
-    <el-aside width="15.7%">
+    <el-aside style="width:333px;">
       <basic-container>
         <div ref="TreeBox" style="height: calc(100vh - 144px);!important;">
           <div class="headerCon">
-            <el-button icon="el-icon-plus" plain size="small" type="primary" @click="addClickHandler">鍒涘缓
+            <el-button v-if="permissionList.addBtn" icon="el-icon-plus" plain size="small" type="primary" @click="addClickHandler">鍒涘缓
             </el-button>
-            <el-button icon="el-icon-edit" plain size="small" type="primary" @click="editClickHandler">淇敼
+            <el-button v-if="permissionList.editBtn" icon="el-icon-edit" plain size="small" type="primary" @click="editClickHandler">淇敼
             </el-button>
-            <el-button icon="el-icon-delete" plain size="small" type="danger" @click="delClickHandler">鍒犻櫎
+            <el-button v-if="permissionList.delBtn" icon="el-icon-delete" plain size="small" type="danger" @click="delClickHandler">鍒犻櫎
             </el-button>
-            <el-button icon="el-icon-download" plain size="small" type="primary" @click="exportClickHandler">瀵煎嚭
+            <el-button v-if="permissionList.importBtn" icon="el-icon-upload2" plain size="small" type="primary" @click="uploadClickHandler">瀵煎叆
             </el-button>
-            <el-button icon="el-icon-upload2" plain size="small" type="primary" @click="uploadClickHandler">瀵煎叆
+            <el-button v-if="permissionList.exportBtn" icon="el-icon-download" plain size="small" type="primary" @click="exportClickHandler">瀵煎嚭
             </el-button>
-            <el-button class="smallBtn" plain size="small" type="primary"
-                       @click="checkViewClickHandler">鏌ョ湅浣跨敤鑼冨洿
+            <el-button v-if="permissionList.viewTheScopeBtn" icon="el-icon-view" plain size="small" type="primary" @click="checkViewClickHandler">鏌ョ湅浣跨敤鑼冨洿
             </el-button>
           </div>
           <!-- 宸︿晶鏍� -->
@@ -87,6 +86,7 @@
 import CycleFlow from "@/components/flow-cycle/flowchartEditor.vue";
 import func from "@/util/func";
 import basicOption from "@/util/basic-option";
+import {mapGetters} from "vuex";
 
 export default {
   name: "index",
@@ -100,6 +100,7 @@
         searchMenuSpan: 8,
         refreshBtn: false,
         selection: false,
+        header:false,
         column: [
           {
             label: '鍚嶇О',
@@ -149,6 +150,19 @@
         }
       },
     }
+  },
+  computed:{
+    ...mapGetters(["permission"]),
+    permissionList() {
+      return {
+        addBtn: this.vaildData(this.permission[this.$route.query.id].ADD, false),
+        delBtn: this.vaildData(this.permission[this.$route.query.id].DELETE, false),
+        editBtn: this.vaildData(this.permission[this.$route.query.id].EDIT, false),
+        exportBtn: this.vaildData(this.permission[this.$route.query.id].EXPORT, false),
+        importBtn: this.vaildData(this.permission[this.$route.query.id].IMPORT, false),
+        viewTheScopeBtn: this.vaildData(this.permission[this.$route.query.id].viewTheScope, false),
+      };
+    },
   },
   created() {
     this.createdHandler();
@@ -314,7 +328,6 @@
         this.checkViewData = this.checkViewDataSearch;
         return done();
       }
-      ;
 
       this.checkViewData = this.checkViewData.filter(item => {
         return item.source && item.source.includes(source);
@@ -421,42 +434,6 @@
   .el-scrollbar__wrap {
     overflow: auto !important;
   }
-  .headerCon{
-    .el-button {
-      width: 65px;
-      padding-left: 9.5px;
-    }
-  }
 }
-
-.headerCon {
-  display: flex;
-  flex-wrap: wrap;
-  margin-bottom: 5px;
-
-  .el-button + .el-button {
-    margin-left: 5px;
-  }
-
-  .el-button {
-    margin-top: 5px;
-  }
-}
-
-.headerCon > .el-button:nth-child(4) {
-  margin-left: 0;
-}
-
-//.headerCon > .el-button:nth-child(6) {
-//  margin-left: 0;
-//}
-
-.smallBtn {
-  width: 77px !important;
-  //font-size: 11px !important;
-  text-align: center  !important;
-  padding-left: 1px  !important;
-}
-
 </style>
 

--
Gitblit v1.9.3