Commit 0c04363c authored by 张俊's avatar 张俊

[feat](路由): 路由跳转调整

parent 0dc540a1
...@@ -164,8 +164,6 @@ steps: ...@@ -164,8 +164,6 @@ steps:
path: /var/run/docker.sock path: /var/run/docker.sock
pull: always pull: always
environment: environment:
http_proxy: http://10.11.92.33:1282
https_proxy: http://10.11.92.33:1282
REGISTRY_USER: REGISTRY_USER:
from_secret: REGISTRY_USER from_secret: REGISTRY_USER
REGISTRY_PASSWORD: REGISTRY_PASSWORD:
...@@ -182,8 +180,6 @@ steps: ...@@ -182,8 +180,6 @@ steps:
path: /var/run/docker.sock path: /var/run/docker.sock
pull: always pull: always
environment: environment:
http_proxy: http://10.11.92.33:1282
https_proxy: http://10.11.92.33:1282
REGISTRY_USER: REGISTRY_USER:
from_secret: REGISTRY_USER from_secret: REGISTRY_USER
REGISTRY_PASSWORD: REGISTRY_PASSWORD:
...@@ -200,8 +196,6 @@ steps: ...@@ -200,8 +196,6 @@ steps:
path: /var/run/docker.sock path: /var/run/docker.sock
pull: always pull: always
environment: environment:
http_proxy: http://10.11.92.33:1282
https_proxy: http://10.11.92.33:1282
REGISTRY_USER: REGISTRY_USER:
from_secret: REGISTRY_USER from_secret: REGISTRY_USER
REGISTRY_PASSWORD: REGISTRY_PASSWORD:
...@@ -218,8 +212,6 @@ steps: ...@@ -218,8 +212,6 @@ steps:
path: /var/run/docker.sock path: /var/run/docker.sock
pull: always pull: always
environment: environment:
http_proxy: http://10.11.92.33:1282
https_proxy: http://10.11.92.33:1282
REGISTRY_USER: REGISTRY_USER:
from_secret: REGISTRY_USER from_secret: REGISTRY_USER
REGISTRY_PASSWORD: REGISTRY_PASSWORD:
......
<template> <template>
<div id="app" @click="readFlag = false"> <div id="app" @click="readFlag = false">
<el-config-provider> <el-config-provider>
<bg-menu :path="nowParent.path" v-if="menuShow" @openMsg="openMsg"></bg-menu> <bg-menu :path="nowParent.path" @openMsg="openMsg"></bg-menu>
<div class="container" :class="menuShow ? '' : 'full_screen'" v-if="pageShow"> <div class="container" v-if="pageShow">
<!-- <bg-nav :highlightParentRule="highlightParentRule" :title="nowParent.menuName" width="208px" :list="nowParent.children" v-show="navShow" class="con-nav" /> --> <!-- <bg-nav :highlightParentRule="highlightParentRule" :title="nowParent.menuName" width="208px" :list="nowParent.children" v-show="navShow" class="con-nav" /> -->
<bg-nav <bg-nav
v-if="nowParent.children" v-if="nowParent.children"
...@@ -91,9 +91,6 @@ export default { ...@@ -91,9 +91,6 @@ export default {
return ""; return "";
} }
}, },
menuShow() {
return false || !["/ui-example"].includes(this.$route.path);
},
}, },
watch: { watch: {
msgBoxFlag(n, o) { msgBoxFlag(n, o) {
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
}"> }">
<!-- LOGO --> <!-- LOGO -->
<router-link to="/" class="bg-logo"> <router-link to="/" class="bg-logo">
<img style="width: 140px; height: 22px" src="../assets/imgs/img_logo.png" /> <span>智能运维管理平台</span>
</router-link> </router-link>
<!-- 菜单 --> <!-- 菜单 -->
...@@ -162,7 +162,7 @@ export default { ...@@ -162,7 +162,7 @@ export default {
...mapState({ ...mapState({
fontMenu(state) { fontMenu(state) {
let temp = []; let temp = [];
state.menu.forEach((e) => { state.menu?.forEach((e) => {
if (e.dict_group_id == "2cb4f767-fad7-44f2-afa3-f055e15dd2b6") { if (e.dict_group_id == "2cb4f767-fad7-44f2-afa3-f055e15dd2b6") {
//font //font
temp.push(e); temp.push(e);
...@@ -172,7 +172,7 @@ export default { ...@@ -172,7 +172,7 @@ export default {
}, },
managerMenu(state) { managerMenu(state) {
let temp = []; let temp = [];
state.menu.forEach((e) => { state.menu?.forEach((e) => {
if (e.dict_group_id == "64c156e0-bfff-4bfc-a63a-56effe130a25") { if (e.dict_group_id == "64c156e0-bfff-4bfc-a63a-56effe130a25") {
temp.push(e); temp.push(e);
} }
...@@ -182,7 +182,7 @@ export default { ...@@ -182,7 +182,7 @@ export default {
systemMenu(state) { systemMenu(state) {
const { is_admin } = state.userInfo; const { is_admin } = state.userInfo;
let temp = []; let temp = [];
state.menu.forEach((e) => { state.menu?.forEach((e) => {
if (e.dict_group_id == "26d3903a-863e-4efc-b53e-0fb8772ddaa4") { if (e.dict_group_id == "26d3903a-863e-4efc-b53e-0fb8772ddaa4") {
// 业务系统用户和组织管理员配置了后台管理,将其隐藏 // 业务系统用户和组织管理员配置了后台管理,将其隐藏
if (is_admin < 3 && e.menuName === "管理中心") { if (is_admin < 3 && e.menuName === "管理中心") {
......
...@@ -81,7 +81,7 @@ function getMenuObj(menu, parentRowPath, menuObj) { ...@@ -81,7 +81,7 @@ function getMenuObj(menu, parentRowPath, menuObj) {
} }
}); });
} }
store.commit("setWhiteList", ["/", "/login", "/register", "/password"]); store.commit("setWhiteList", ["/login", "/register", "/password"]);
Promise.all([getUser(), getMenu("79a8f214-db78-4db7-9c28-db66276b4be2")]) Promise.all([getUser(), getMenu("79a8f214-db78-4db7-9c28-db66276b4be2")])
.then((res) => { .then((res) => {
if (res[0].data.code == 200 && res[1].data.code == 200) { if (res[0].data.code == 200 && res[1].data.code == 200) {
......
<template> <template>
<div style="width:100%;height:calc(100% - 10px);background-color:#fff;text-align:center;"> <div style="width:100%;height:calc(100% - 10px);background-color:#fff;text-align:center;">
<img src="../assets/imgs/welcom.png" alt="" style="margin-top:150px;"> <img src="../assets/imgs/welcom.png" alt="" style="margin-top:150px;">
<p style="font-size:18px;">欢迎进入BD-Apaas5系统~</p> <p style="font-size:18px;">欢迎进入智能运维管理平台系统~</p>
</div> </div>
</template> </template>
......
...@@ -59,11 +59,11 @@ function inWhiteList(toPath) { ...@@ -59,11 +59,11 @@ function inWhiteList(toPath) {
router.beforeEach((to, from, next) => { router.beforeEach((to, from, next) => {
const userInfo = store.state.userInfo; const userInfo = store.state.userInfo;
//已登录不可跳转登陆页 //已登录不可跳转登陆页 || to.path == "/" 去除首页跳转判断
if (userInfo && (to.path == "/login" || to.path == "/")) { if (userInfo && (to.path == "/login" )) {
next({ return next({
path: "/develop/account", path: "/",
}); })
} }
// 检查to.path是否存在于免登陆白名单 // 检查to.path是否存在于免登陆白名单
...@@ -74,7 +74,7 @@ router.beforeEach((to, from, next) => { ...@@ -74,7 +74,7 @@ router.beforeEach((to, from, next) => {
// 根据配置判断是否跳转第三方登录,跳转第三方登录则不跳login // 根据配置判断是否跳转第三方登录,跳转第三方登录则不跳login
// axios封装中也需要对是否登录过期进行判断,如果登录过期,则跳转登录页,具体跳转地址根据配置来· // axios封装中也需要对是否登录过期进行判断,如果登录过期,则跳转登录页,具体跳转地址根据配置来·
if (!userInfo) { if (!userInfo) {
next({ return next({
path: "/login", path: "/login",
}); });
} else { } else {
...@@ -83,7 +83,7 @@ router.beforeEach((to, from, next) => { ...@@ -83,7 +83,7 @@ router.beforeEach((to, from, next) => {
//判读是否匹配,否则跳转404 //判读是否匹配,否则跳转404
if (to.matched.length !== 0) { if (to.matched.length !== 0) {
next(); return next();
} else { } else {
return next({ return next({
path: "/404", path: "/404",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment