|
@@ -3,12 +3,21 @@
|
|
|
<!-- <hamburger :is-active="sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" /> -->
|
|
|
|
|
|
<!-- <breadcrumb class="breadcrumb-container" /> -->
|
|
|
- <div class="left-menu">
|
|
|
+ <div class="indexlayout-top-menu">
|
|
|
+ <!-- :class="{'active': getTopMenuActive === route.path}" -->
|
|
|
+ <el-scrollbar class="horizontal-scrollbar">
|
|
|
+ <template v-for="route in permission_routes">
|
|
|
+ <app-link v-if="!route.hidden" :to="route.path" :key="route.path" class="indexlayout-top-menu-li" :class="{'active': getTopMenuActive === route.path}">
|
|
|
+ <span>{{ route.meta.title }}</span>
|
|
|
+ </app-link>
|
|
|
+ </template>
|
|
|
+ </el-scrollbar>
|
|
|
+ </div>
|
|
|
+ <!-- <div class="left-menu">
|
|
|
<i class="el-icon-location-information topIcon"></i>
|
|
|
|
|
|
<el-popover placement="top-start" width="300" trigger="hover">
|
|
|
<div class="popover-container">
|
|
|
- <!-- <p style="color: red">{{ organName }}</p> -->
|
|
|
<el-tag
|
|
|
class="navbar_tag"
|
|
|
type="info"
|
|
@@ -21,9 +30,9 @@
|
|
|
organName.length > 10 ? organName.substr(0, 10) + "..." : organName
|
|
|
}}</span>
|
|
|
</el-popover>
|
|
|
- </div>
|
|
|
+ </div> -->
|
|
|
<div class="right-menu">
|
|
|
- <div class="msginfo" v-permission="'/journals'" @click="gotoRecode">
|
|
|
+ <div class="msginfo" v-permission="'/journal'" @click="gotoRecode">
|
|
|
<img src="@/assets/images/base/base-bell.svg" />
|
|
|
<!-- <div class="active"></div> -->
|
|
|
</div>
|
|
@@ -53,6 +62,25 @@
|
|
|
</el-dropdown-item>
|
|
|
</el-dropdown-menu>
|
|
|
</el-dropdown>
|
|
|
+
|
|
|
+ <div class="left-menu">
|
|
|
+ <i class="el-icon-location-information topIcon"></i>
|
|
|
+
|
|
|
+ <el-popover placement="top-start" width="300" trigger="hover">
|
|
|
+ <div class="popover-container">
|
|
|
+ <el-tag
|
|
|
+ class="navbar_tag"
|
|
|
+ type="info"
|
|
|
+ v-for="item in organNameList"
|
|
|
+ :key="item"
|
|
|
+ >{{ item }}</el-tag
|
|
|
+ >
|
|
|
+ </div>
|
|
|
+ <span slot="reference">{{
|
|
|
+ organName.length > 10 ? organName.substr(0, 10) + "..." : organName
|
|
|
+ }}</span>
|
|
|
+ </el-popover>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
<el-dialog
|
|
|
title="修改密码"
|
|
@@ -140,6 +168,8 @@ import { mapGetters } from "vuex";
|
|
|
// import Breadcrumb from '@/components/Breadcrumb'
|
|
|
// import Hamburger from '@/components/Hamburger'
|
|
|
import { resetPassword } from "@/api/buildTeam";
|
|
|
+import AppLink from './Sidebar/Link';
|
|
|
+import { getBelongTopMenuPath } from '@/utils/permission';
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
@@ -159,11 +189,17 @@ export default {
|
|
|
};
|
|
|
},
|
|
|
components: {
|
|
|
+ AppLink
|
|
|
// Breadcrumb,
|
|
|
// Hamburger
|
|
|
},
|
|
|
computed: {
|
|
|
- ...mapGetters(["sidebar", "avatar"]),
|
|
|
+ ...mapGetters(["sidebar", "avatar", "permission_routes"]),
|
|
|
+ getTopMenuActive() {
|
|
|
+ let route = this.$route;
|
|
|
+ // console.log(route, getBelongTopMenuPath(route))
|
|
|
+ return getBelongTopMenuPath(route);
|
|
|
+ }
|
|
|
},
|
|
|
mounted() {
|
|
|
// 手动加入
|
|
@@ -262,6 +298,48 @@ export default {
|
|
|
.navbar_tag {
|
|
|
margin: 0 5px 8px;
|
|
|
}
|
|
|
+
|
|
|
+.indexlayout-top-menu{
|
|
|
+ padding-left: 20px;
|
|
|
+ height: 60px;
|
|
|
+ line-height: 60px;
|
|
|
+ flex: 1;
|
|
|
+ display: flex;
|
|
|
+ overflow: hidden;
|
|
|
+ /* overflow-x: auto; */
|
|
|
+ .indexlayout-top-menu-li{
|
|
|
+ display: inline-block;
|
|
|
+ padding: 0 15px;
|
|
|
+ height: 57px;
|
|
|
+ text-decoration: none;
|
|
|
+ color: #fff;
|
|
|
+ font-size: 15px;
|
|
|
+ transition: all .3s ease;
|
|
|
+ span {
|
|
|
+ border-bottom: solid 3px transparent;
|
|
|
+ height: 57px;
|
|
|
+ line-height: 57px;
|
|
|
+ display: block;
|
|
|
+ }
|
|
|
+ &:hover,
|
|
|
+ &.active{
|
|
|
+ span {
|
|
|
+ border-bottom-color: #209e91;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ &.active {
|
|
|
+ background-color: #2C3246;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .breadcrumb{
|
|
|
+ line-height: 60px;
|
|
|
+ margin-left: 10px;
|
|
|
+ .el-breadcrumb__item{
|
|
|
+ display: inline-block;
|
|
|
+ float: none;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
.popover-container {
|
|
|
max-height: 350px;
|
|
|
overflow-y: scroll;
|
|
@@ -273,7 +351,7 @@ export default {
|
|
|
height: 60px;
|
|
|
overflow: hidden;
|
|
|
position: relative;
|
|
|
- background: #fff;
|
|
|
+ background: #363d55;
|
|
|
box-shadow: 0px 8px 20px 0px rgba(0, 0, 0, 0.1);
|
|
|
h2 {
|
|
|
font-size: 18px;
|
|
@@ -299,16 +377,16 @@ export default {
|
|
|
}
|
|
|
.left-menu {
|
|
|
line-height: 60px;
|
|
|
- padding-left: 22px;
|
|
|
+ padding-right: 42px;
|
|
|
font-size: 16px;
|
|
|
- color: #444;
|
|
|
+ color: #fff;
|
|
|
.topIcon {
|
|
|
width: 20px;
|
|
|
height: 25px;
|
|
|
}
|
|
|
}
|
|
|
.right-menu {
|
|
|
- min-width: 204px;
|
|
|
+ min-width: 154px;
|
|
|
float: right;
|
|
|
height: 100%;
|
|
|
line-height: 60px;
|
|
@@ -323,7 +401,7 @@ export default {
|
|
|
flex-direction: row;
|
|
|
justify-content: flex-start;
|
|
|
align-items: center;
|
|
|
- margin-right: 34px;
|
|
|
+ margin-right: 20px;
|
|
|
position: relative;
|
|
|
cursor: pointer;
|
|
|
img {
|
|
@@ -360,7 +438,7 @@ export default {
|
|
|
|
|
|
.avatar-container {
|
|
|
height: 60px;
|
|
|
- margin-right: 42px;
|
|
|
+ margin-right: 12px;
|
|
|
cursor: pointer;
|
|
|
|
|
|
.avatar-wrapper {
|
|
@@ -370,10 +448,11 @@ export default {
|
|
|
justify-content: flex-start;
|
|
|
align-items: center;
|
|
|
span {
|
|
|
- margin-left: 15px;
|
|
|
+ margin-left: 8px;
|
|
|
font-size: 14px;
|
|
|
font-weight: 500;
|
|
|
- color: rgba(68, 68, 68, 1);
|
|
|
+ // color: rgba(68, 68, 68, 1);
|
|
|
+ color: #fff;
|
|
|
}
|
|
|
|
|
|
.user-avatar {
|