From 1d3efb6ed52ef43c6184cfaa2ff11d5cc78565c9 Mon Sep 17 00:00:00 2001
From: fuliqi <fuliqi@qq.com>
Date: 星期日, 08 十二月 2024 19:24:21 +0800
Subject: [PATCH] 新增故障类型
---
src/layout/components/Navbar.vue | 30 ++++++++++++++++--------------
1 files changed, 16 insertions(+), 14 deletions(-)
diff --git a/src/layout/components/Navbar.vue b/src/layout/components/Navbar.vue
index a122c07..90c59ec 100644
--- a/src/layout/components/Navbar.vue
+++ b/src/layout/components/Navbar.vue
@@ -1,7 +1,7 @@
<template>
<div class="navbar">
<hamburger id="hamburger-container" :is-active="sidebar.opened" class="hamburger-container"
- @toggleClick="toggleSideBar" />
+ @toggleClick="toggleSideBar" />
<breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!topNav" />
<top-nav id="topmenu-container" class="topmenu-container" v-if="topNav" />
@@ -38,15 +38,14 @@
</el-dropdown>
</div>
- <div class="test-container">
- <el-button-group style="vertical-align: text-bottom;">
- <el-button @click="exchange(100)">鐪佸巺瑙掕壊</el-button>
- <el-button @click="exchange(103)">鍖哄幙瑙掕壊</el-button>
- <el-button @click="exchange(2)">杩愮淮瑙掕壊</el-button>
- </el-button-group>
+ <div class="button-container">
+ <el-button v-if="roles.includes('admin') || roles.includes('county_leader') || roles.includes('city_leader')" type="primary" @click="toScreen" size="small">鍙鍖栧ぇ灞�</el-button>
</div>
<div class="button-container">
- <el-button type="primary" @click="toScreen">鍙鍖栧ぇ灞�</el-button>
+ <el-button type="primary" @click="toSystemB" size="small">璺宠浆B绯荤粺</el-button>
+ </div>
+ <div class="button-container">
+ <el-button type="primary" @click="toSystemA" size="small">璺宠浆A绯荤粺</el-button>
</div>
</div>
</template>
@@ -77,7 +76,8 @@
...mapGetters([
'sidebar',
'avatar',
- 'device'
+ 'device',
+ 'roles'
]),
setting: {
get() {
@@ -97,11 +97,6 @@
}
},
methods: {
- exchange(roleId) {
- exchangeRole(roleId).then(response => {
- this.$modal.msgSuccess("淇敼鎴愬姛");
- }).catch(() => { });
- },
toggleSideBar() {
this.$store.dispatch('app/toggleSideBar')
},
@@ -121,6 +116,13 @@
this.$router.push({
path: '/screen'
})
+ },
+
+ toSystemA() {
+ window.open('https://www.baidu.com/')
+ },
+ toSystemB() {
+ window.open('https://www.baidu.com/')
}
}
}
--
Gitblit v1.8.0