fix:添加指挥部大屏需要免登录跳转的页面
This commit is contained in:
parent
2f15f42eeb
commit
208d436e7f
@ -1224,7 +1224,30 @@ export default {
|
||||
if (!this.$store.state.userInfo.personMail && this.company == 'agjt' && isHaveUserCenterMenu) {
|
||||
this.checkInfoComplete();
|
||||
}
|
||||
if(window.location.href.indexOf("command") != -1){
|
||||
// 用 split 方法取出 pathItem 参数
|
||||
var params = window.location.href.split('?')[1]; // 获取 ? 后面的参数部分
|
||||
var keyValuePairs = params.split('&'); // 通过 & 符号分割参数
|
||||
var pathItem;
|
||||
for (var i = 0; i < keyValuePairs.length; i++) {
|
||||
var pair = keyValuePairs[i].split('=');
|
||||
if (pair[0] === 'pathItem') {
|
||||
pathItem = decodeURIComponent(pair[1]); // 解码参数值
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
console.log("22222222222222222222222222222222222222222222222222")
|
||||
console.log(window.location.href)
|
||||
console.log(pathItem)
|
||||
|
||||
localStorage.setItem('lageToBackend',pathItem)
|
||||
|
||||
this.$router.push("projectIndex");
|
||||
}else{
|
||||
this.$router.push("/workSpace");
|
||||
}
|
||||
// this.$router.push("/workSpace");
|
||||
} else {
|
||||
this.$router.push("/supplierIndex");
|
||||
}
|
||||
|
||||
@ -344,6 +344,24 @@ export default {
|
||||
console.log("all111", all);
|
||||
// this.list = all;
|
||||
this.list = all.filter(item => item.plugin != 'contractors');//承包商模块不需要在后台显示,以此过滤掉该后台模块
|
||||
|
||||
|
||||
let pathItem = localStorage.getItem('lageToBackend')
|
||||
|
||||
if(pathItem.length > 0){
|
||||
localStorage.removeItem('lageToBackend')
|
||||
let path = pathItem
|
||||
let moduleList = this.list;
|
||||
moduleList.map((item) => {
|
||||
item.menuList.map((item2) => {
|
||||
if (item2.path == path) {
|
||||
this.$store.commit("setMenuList", item.menuList);
|
||||
}
|
||||
});
|
||||
});
|
||||
this.$router.push(path);
|
||||
}
|
||||
|
||||
}
|
||||
});
|
||||
} else {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user