From 404966637eda6881a0f17683c5aacc7c1c34aed8 Mon Sep 17 00:00:00 2001 From: 田源 <tianyuan@vci-tech.com> Date: 星期四, 16 一月 2025 16:18:34 +0800 Subject: [PATCH] 增加操作类型 --- Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/linkType/index.vue | 80 +++++++++++++++++++++++++++------------ 1 files changed, 55 insertions(+), 25 deletions(-) diff --git a/Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/linkType/index.vue b/Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/linkType/index.vue index 745838b..2a6af8a 100644 --- a/Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/linkType/index.vue +++ b/Source/plt-web/plt-web-ui/src/views/modelingMenu/modeling/linkType/index.vue @@ -7,7 +7,7 @@ <div style="height: calc(100vh - 190px);"> <avue-tree :data="treeData" :option="treeOption" @node-click="nodeClick"> <span slot-scope="{ node, data }" class="el-tree-node__label"> - <span style="font-size: 15px"> + <span> <i class="el-icon-s-promotion"></i> {{ (node || {}).label }} </span> @@ -21,13 +21,35 @@ <el-main> <basic-container> <div> - <el-button 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> - <el-button icon="el-icon-delete" plain size="small" type="danger" @click="deleteClickHandler">鍒犻櫎</el-button> - <el-button icon="el-icon-download" plain size="small" type="primary" @click="exportClickHandler">瀵煎嚭</el-button> - <el-button icon="el-icon-upload2" plain size="small" type="primary" @click="upLoadClickHandler">瀵煎叆</el-button> - <el-button icon="el-icon-circle-plus-outline" plain size="small" type="primary" @click="createViewClickHandler">鍒涘缓瑙嗗浘</el-button> - <el-button icon="el-icon-menu" plain size="small" type="primary" @click="checkClickHandler">涓�鑷存�ф鏌�</el-button> + <el-button v-if="permissionList.addBtn" class="button-custom-icon" plain size="small" type="primary" + @click="addClickHandler"> + <icon-show :name="permissionList.addBtn.source"></icon-show> + 鍒涘缓 + </el-button> + <el-button v-if="permissionList.editBtn" class="button-custom-icon" plain size="small" type="primary" @click="editClickHandler"> + <icon-show :name="permissionList.editBtn.source"></icon-show> + 淇敼 + </el-button> + <el-button v-if="permissionList.delBtn" class="button-custom-icon" plain size="small" type="danger" @click="deleteClickHandler"> + <icon-show :name="permissionList.delBtn.source"></icon-show> + 鍒犻櫎 + </el-button> + <el-button v-if="permissionList.importBtn" class="button-custom-icon" plain size="small" type="primary" @click="upLoadClickHandler"> + <icon-show :name="permissionList.importBtn.source"></icon-show> + 瀵煎叆 + </el-button> + <el-button v-if="permissionList.exportBtn" class="button-custom-icon" plain size="small" type="primary" @click="exportClickHandler"> + <icon-show :name="permissionList.exportBtn.source"></icon-show> + 瀵煎嚭 + </el-button> + <el-button v-if="permissionList.createViewBtn" class="button-custom-icon" plain size="small" type="primary" @click="createViewClickHandler"> + <icon-show :name="permissionList.createViewBtn.source"></icon-show> + 鍒涘缓瑙嗗浘 + </el-button> + <el-button v-if="permissionList.consistencyCheckBtn" class="button-custom-icon" plain size="small" type="primary" @click="checkClickHandler"> + <icon-show :name="permissionList.consistencyCheckBtn.source"></icon-show> + 涓�鑷存�ф鏌� + </el-button> </div> <el-descriptions style="margin: 10px 0 20px" :column="2" border class="margin-top" size="medium"> <el-descriptions-item :contentStyle="descriptionOption.contentStyle" @@ -188,7 +210,6 @@ prop="name"> </el-table-column> <el-table-column - fixed="right" label="鎿嶄綔" width="60"> <template slot-scope="scope"> @@ -229,7 +250,6 @@ prop="name"> </el-table-column> <el-table-column - fixed="right" label="鎿嶄綔" width="60"> <template slot-scope="scope"> @@ -274,8 +294,8 @@ </avue-crud> </div> <span slot="footer" class="dialog-footer"> - <el-button type="primary" @click="addDialogSavaHandler">纭� 瀹�</el-button> - <el-button @click="addDialogClose">鍙� 娑�</el-button> + <el-button size="small" type="primary" @click="addDialogSavaHandler">纭� 瀹�</el-button> + <el-button size="small" @click="addDialogClose">鍙� 娑�</el-button> </span> <!-- 灞炴�ф睜鍒楄〃 --> @@ -304,8 +324,8 @@ > </avue-crud> <span slot="footer" class="dialog-footer"> - <el-button type="primary" @click="dialogAttrAddClickHandler">纭� 瀹�</el-button> - <el-button @click="dialogAttrClose">鍙� 娑�</el-button> + <el-button size="small" type="primary" @click="dialogAttrAddClickHandler">纭� 瀹�</el-button> + <el-button size="small" @click="dialogAttrClose">鍙� 娑�</el-button> </span> </el-dialog> </el-dialog> @@ -325,8 +345,8 @@ :table-loading="conCheckLoading"> </avue-crud> <span slot="footer" class="dialog-footer"> - <el-button @click="conCheckVisible = false">鍙� 娑�</el-button> - <el-button type="primary" @click="repairClickHandler">淇� 澶�</el-button> + <el-button size="small" @click="conCheckVisible = false">鍙� 娑�</el-button> + <el-button size="small" type="primary" @click="repairClickHandler">淇� 澶�</el-button> </span> </el-dialog> @@ -352,8 +372,8 @@ </avue-crud> <span slot="footer" class="dialog-footer"> - <el-button @click="bizTypeVisible = false">鍙� 娑�</el-button> - <el-button type="primary" @click="bizTypeAddHandler">纭� 瀹�</el-button> + <el-button size="small" type="primary" @click="bizTypeAddHandler">纭� 瀹�</el-button> + <el-button size="small" @click="bizTypeVisible = false">鍙� 娑�</el-button> </span> </el-dialog> @@ -378,6 +398,7 @@ import basicOption from '@/util/basic-option' import {gridAttribute} from "@/api/modeling/attributePool/api"; import func from "@/util/func"; +import {mapGetters} from "vuex"; export default { name: "index", @@ -650,8 +671,19 @@ created() { this.getTreeList(); }, - mounted() { - + 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), + consistencyCheckBtn: this.vaildData(this.permission[this.$route.query.id].USE, false), + createViewBtn: this.vaildData(this.permission[this.$route.query.id].ADD2, false), + }; + }, }, methods: { // 鏍憃nLoad璇锋眰 @@ -660,9 +692,7 @@ const data = res.data.data; this.treeData = data; this.tableLoading = false; - }).catch(err => { - this.$message.error(err); - }); + }) }, // 瀵煎叆 @@ -883,7 +913,7 @@ this.attrLastIndex = newIndex; }, () => { - this.selectList = []; + this.dialogAttrSelectList = [row]; } ); }, @@ -1007,7 +1037,7 @@ this.bizLastIndex = newIndex; }, () => { - this.selectList = []; + this.bizTypeList = [row]; } ); }, -- Gitblit v1.9.3