Merge remote-tracking branch 'origin/codeCheck' into codeCheck

This commit is contained in:
chenjinsong
2020-07-06 19:49:12 +08:00
10 changed files with 75 additions and 12 deletions

View File

@@ -7,6 +7,18 @@
active="1"
unique-opened
>
<el-submenu :index="'-3'" popper-class="nz-submenu" class="icon-menu-item">
<template slot="title">
<i class="nz-icon-navmore nz-icon"></i>
</template>
<template v-for="(item, index) in $store.state.linkData">
<el-menu-item :index="'0-' + index">
<div>
<span><a :href='item.url' class="nz-a" target="_blank" :title="item.url">{{item.name}}</a></span>
</div>
</el-menu-item>
</template>
</el-submenu>
<el-submenu :index="'-1'" class="icon-menu-item" popper-class="display-none">
<div slot="title" class="el-submenu__title" @click="cli()" >
<i class="nz-icon nz-icon-cli"></i>
@@ -496,12 +508,22 @@
console.info(this.activeIndex)
//this.$router.go(-1);
},
getLinkData(){
console.log('aaa');
this.$get('link').then(response=>{
console.log(response);
// this.linkData=response.data;
this.$store.commit('setLinkData',response.data);
console.log(this.$store)
});
},
},
mounted() {
this.$i18n.locale = this.language;
this.getUserData();
this.getAssetData();
this.getProjectList();
this.getLinkData();
// 刷新后有高亮
let activePath = this.$route.path.slice(1);
this.activeIndex = activePath;
@@ -517,7 +539,7 @@
if (window.history && window.history.pushState) {
history.pushState(null, null, document.URL);
window.addEventListener('popstate', this.cancel, false);
}
};
},
computed: {
projectListReloadWatch() {
@@ -555,7 +577,7 @@
currentProjectWatch(n,o){
this.currentProject=n;
this.activeItemIndex=n.id;
}
},
},
destroyed() {
window.removeEventListener('popstate', this.cancel, false);
@@ -745,6 +767,10 @@
.menu-create-title {
font-size: 14px;
}
a.nz-a{
color: inherit;
text-decoration:none;
}
.header {
position: relative;
box-sizing: border-box;