fix:居中导航栏图标 以及 解决切换后project 列表依旧被的选择的问题

This commit is contained in:
zhangyu
2021-01-13 18:58:50 +08:00
parent 0504296213
commit 1b75ab629c
17 changed files with 65 additions and 18 deletions

View File

@@ -226,6 +226,11 @@
facade,
'delete-button':deleteButton,
},
computed:{
currentProjectChange() {
return this.$store.state.currentProject;
}
},
data(){
return {
rightBox:{
@@ -844,13 +849,21 @@
if (n.length === 0 && this.endpointPageObj.pageNo > 1) {
this.endpointPageNo(this.endpointPageObj.pageNo-1);
}
if(!this.delFlag){ // 不是删除时回到顶部 以及修改时
if(!this.delFlag&&this.pageType==='endpoint'){ // 不是删除时回到顶部 以及修改时
this.$refs.endpointTable.bodyWrapper.scrollTop = 0
}else{
this.delFlag=false;
}
}
}
},
currentProject: {
handler(n, o) {
console.log(n);
if (n && o.id != this.currentProject.id) {
this.pageType='project';
}
},
},
},
beforeDestroy() {
bus.$off("project-page-type");
@@ -860,7 +873,9 @@
bus.$off("module-list-change");
bus.$off("endpoint-list-change");
bus.$off('alert-message-change');
this.scrollbarWrap.removeEventListener('scroll', bus.debounce);
if(this.scrollbarWrap){
this.scrollbarWrap.removeEventListener('scroll', bus.debounce);
};
},
}
</script>