【update】-去掉原来的大屏路由,对首页的路由做相关的判断
This commit is contained in:
@@ -64,10 +64,10 @@ export const constantRouterMap = [
|
|||||||
component: SignUpPage,
|
component: SignUpPage,
|
||||||
hidden: true,
|
hidden: true,
|
||||||
},
|
},
|
||||||
{
|
// {
|
||||||
path: "/screen",
|
// path: "/screen",
|
||||||
name: 'HomePage',
|
// name: 'HomePage',
|
||||||
component: () => import(/* webpackChunkName: "user" */ "@/views/screen/HomePage"),
|
// component: () => import(/* webpackChunkName: "user" */ "@/views/screen/HomePage"),
|
||||||
hidden: true,
|
// hidden: true,
|
||||||
},
|
// },
|
||||||
];
|
];
|
||||||
|
|||||||
+2
-1
@@ -75,7 +75,8 @@ router.beforeEach(async (to, from, next) => {
|
|||||||
console.log('redirect--------', redirect)
|
console.log('redirect--------', redirect)
|
||||||
console.log('to.path--------', to.path)
|
console.log('to.path--------', to.path)
|
||||||
// const redirect = decodeURIComponent(from.query.redirect || to.path)
|
// const redirect = decodeURIComponent(from.query.redirect || to.path)
|
||||||
if (to.path === redirect || to.path === '/screen') {
|
// 大屏的路由跳转 to.path === redirect || to.path === '/screen'
|
||||||
|
if (to.path === redirect) {
|
||||||
// hack方法 确保addRoutes已完成 ,set the replace: true so the navigation will not leave a history record
|
// hack方法 确保addRoutes已完成 ,set the replace: true so the navigation will not leave a history record
|
||||||
next({ ...to, replace: true })
|
next({ ...to, replace: true })
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -16,19 +16,19 @@
|
|||||||
</a-dropdown>
|
</a-dropdown>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="screen-btn">
|
<!--<div class="screen-btn">-->
|
||||||
<!-- v-has="'dashboard:screen'"-->
|
<!-- <!– v-has="'dashboard:screen'"–>-->
|
||||||
<a-button type="primary" @click="goScreen">大屏</a-button>
|
<!-- <a-button type="primary" @click="goScreen">大屏</a-button>-->
|
||||||
</div>
|
<!--</div>-->
|
||||||
<!--只是单纯的用于定位-->
|
<!--只是单纯的用于定位-->
|
||||||
<div id="income"></div>
|
<div id="income"></div>
|
||||||
<!-- 其他人展示消息-->
|
<!-- 其他人展示消息-->
|
||||||
<template v-if="roleCoe">
|
<template v-if="roleCoe">
|
||||||
<user-announcement-list :is-show-seach="true"></user-announcement-list>
|
<user-announcement-list :is-show-seach="true"></user-announcement-list>
|
||||||
<div class="download">
|
<!--<div class="download">-->
|
||||||
点击下载<span class="primary-color" @click="downloadManual">管理端使用手册</span>
|
<!-- 点击下载<span class="primary-color" @click="downloadManual">管理端使用手册</span>-->
|
||||||
<span style="margin-left: 10px">技术支持电话:022-84379290</span>
|
<!-- <span style="margin-left: 10px">技术支持电话:022-84379290</span>-->
|
||||||
</div>
|
<!--</div>-->
|
||||||
</template>
|
</template>
|
||||||
<!-- 所领导 部门领导展示统计图 -->
|
<!-- 所领导 部门领导展示统计图 -->
|
||||||
<template v-else>
|
<template v-else>
|
||||||
@@ -92,6 +92,14 @@
|
|||||||
<w-p-screen></w-p-screen>
|
<w-p-screen></w-p-screen>
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<!-- 其他人展示消息-->
|
||||||
|
<template v-if="roleCoe">
|
||||||
|
<div class="download">
|
||||||
|
点击下载<span class="primary-color" @click="downloadManual">管理端使用手册</span>
|
||||||
|
<span style="margin-left: 10px">技术支持电话:022-84379290</span>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -219,7 +227,7 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.download {
|
.download {
|
||||||
margin-top: 8px;
|
margin: 8px 0 12px;
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user