From 370b26066c560f15f6a84caca2be149e48e86556 Mon Sep 17 00:00:00 2001 From: 田源 <tianyuan@vci-tech.com> Date: 星期二, 07 一月 2025 15:52:05 +0800 Subject: [PATCH] 系统菜单 默认显示&&系统配置、对象建模按钮权限以及按钮图标 --- Source/plt-web/plt-web-ui/src/page/index/sidebar/sidebarItem.vue | 26 ++++++++++++++++++++------ 1 files changed, 20 insertions(+), 6 deletions(-) diff --git a/Source/plt-web/plt-web-ui/src/page/index/sidebar/sidebarItem.vue b/Source/plt-web/plt-web-ui/src/page/index/sidebar/sidebarItem.vue index 2bbc1ff..d90ab50 100644 --- a/Source/plt-web/plt-web-ui/src/page/index/sidebar/sidebarItem.vue +++ b/Source/plt-web/plt-web-ui/src/page/index/sidebar/sidebarItem.vue @@ -7,8 +7,13 @@ :index="item[pathKey]" @click="open(item)"> <div style="display: flex"> - <icon-show :name="item[iconKey]" class="iconShowSpan" :style="{ height: iconSize, width: iconSize }"></icon-show> - <span slot="title" style="margin-left: 8px;" + <icon-show v-if="item[iconKey]" :name="item[iconKey]" :style="{ height: iconSize, width: iconSize }" + class="iconShowSpan"></icon-show> + <div v-else :style="{ height: iconSize, width: iconSize }" class="iconShow iconShowSpan"> + <i :style="{ fontSize: iconSize, width: iconSize,marginTop: '3px'}" class="el-icon-setting"></i> + </div> + <span slot="title" + style="margin-left: 8px" :alt="item[pathKey]" :class="{'el-menu--display':collapse && first}">{{ generateTitle(item) }}</span> </div> @@ -18,8 +23,13 @@ :index="item[pathKey]"> <template slot="title"> <div style="display: flex"> - <icon-show :name="item[iconKey]" class="iconShowSpan" :style="{ height: iconSize, width: iconSize }"></icon-show> - <span slot="title" style="margin-left: 8px;" + <icon-show v-if="item[iconKey]" :name="item[iconKey]" :style="{ height: iconSize, width: iconSize }" + class="iconShowSpan"></icon-show> + <div v-else :style="{ height: iconSize, width: iconSize }" class="iconShow iconShowSpan"> + <i :style="{ fontSize: iconSize, width: iconSize,marginTop: '3px'}" class="el-icon-setting"></i> + </div> + <span slot="title" + style="margin-left: 8px" :class="{'el-menu--display':collapse && first}">{{ generateTitle(item) }}</span> </div> </template> @@ -30,8 +40,12 @@ :index="child[pathKey],cindex" @click="open(child)"> <div style="display: flex"> - <icon-show :name="child[iconKey]" class="iconShowSpan" :style="{ height: iconSize, width: iconSize }"></icon-show> - <span slot="title" style="margin-left: 8px;">{{ generateTitle(child) }}</span> + <icon-show v-if="child[iconKey]" :name="child[iconKey]" :style="{ height: iconSize, width: iconSize }" + class="iconShowSpan"></icon-show> + <div v-else :style="{ height: iconSize, width: iconSize }" class="iconShow iconShowSpan"> + <i :style="{ fontSize: iconSize, width: iconSize,marginTop: '3px'}" class="el-icon-setting"></i> + </div> + <span slot="title" style="margin-left: 8px">{{ generateTitle(child) }}</span> </div> </el-menu-item> <sidebar-item v-else -- Gitblit v1.9.3