Commit 6bd625e2 by zhangxw

新窗口打开 菜单header隐藏判断修改

1 parent 9d54a072
......@@ -53,7 +53,8 @@ export default {
Common.noHiddenMenu.map(val => {
if (window.location.hash.indexOf(val) > -1) flag = false
})
if (flag) {
console.log(flag)
if (!flag) {
const store = useStore()
store.state.collapsed = true
store.dispatch('app/setCollapsed', true)
......
......@@ -118,6 +118,6 @@ export const Common = {
return true;
}
},
// 不隐藏菜单和header的路由
noHiddenMenu: ['/alarmCenter/alarmLog', '/alarmCenter/alarm/detail', '/alarmCenter/tamper']
// 隐藏菜单和header的路由
noHiddenMenu: ['/monitor/activeLocation', '/monitor/resident', '/monitor/monitor', '/monitor/fence', '/monitor/replay', '/monitor/historyLocation']
}
......@@ -41,9 +41,9 @@ export default {
let flag = true
// 新窗口打开 非地图页面
Common.noHiddenMenu.map(val => {
if (window.location.hash.indexOf(val) > -1) flag = false
if (window.location.hash.indexOf(val) <= -1) flag = false
})
if (flag) state.isShowTopSider = false
if (!flag) state.isShowTopSider = false
}
const getCollapsed = (data) => {
console.log(data);
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!