Commit be89fdb8 authored by wuwangwolihui's avatar wuwangwolihui

营地2.0

parent f4f77e76
......@@ -12,7 +12,7 @@
<el-menu :default-active="$store.state.activeIndex"
@select="handleSelect"
mode="horizontal">
<el-menu-item index="/home">首页</el-menu-item>
<el-menu-item index="/">首页</el-menu-item>
<el-menu-item index="/active">活动中心</el-menu-item>
</el-menu>
<el-button v-if="type==2" @click="toSignUp" class="sign-up">立即报名</el-button>
......@@ -183,7 +183,7 @@
}
if (this.type == 4) {
if (previousPath &&
(previousPath == '/home' ||
(previousPath == '/' ||
previousPath == '/active' ||
previousPath.indexOf('/active/') != -1)) {
await this.$router.replace({
......
......@@ -17,14 +17,14 @@
// export const SERVER_WS_URL = "wss://apiy.thuers.com"; // websocket
// 测试
export const SERVER_URL = "https://tgwapi.campcenter.cn/modules-campsite"; // 正式环境
export const DEVELOPMENT_SERVER_URL = "https://tgwapi.campcenter.cn/modules-campsite"; //开发环境
export const SERVER_WS_URL = "wss://tgwapi.campcenter.cn"; // websocket
// export const SERVER_URL = "https://tgwapi.campcenter.cn/modules-campsite"; // 正式环境
// export const DEVELOPMENT_SERVER_URL = "https://tgwapi.campcenter.cn/modules-campsite"; //开发环境
// export const SERVER_WS_URL = "wss://tgwapi.campcenter.cn"; // websocket
// 正式
// export const SERVER_URL = "https://gwapi.campcenter.cn/modules-campsite"; // 正式环境
// export const DEVELOPMENT_SERVER_URL = "https://gwapi.campcenter.cn/modules-campsite"; //开发环境
// export const SERVER_WS_URL = "wss://gwapi.campcenter.cn"; // websocket
export const SERVER_URL = "https://gwapi.campcenter.cn/modules-campsite"; // 正式环境
export const DEVELOPMENT_SERVER_URL = "https://gwapi.campcenter.cn/modules-campsite"; //开发环境
export const SERVER_WS_URL = "wss://gwapi.campcenter.cn"; // websocket
// 测试
// export const SERVER_URL = "http:// 8088/modules-campsite"; // 正式环境
......
export default [
{
path: '/home',
path: '/',
name: 'base-home',
component: () => import(/* webpackChunkName: "login" */ 'v/base/home/Home.vue'),
meta: {
......
......@@ -25,7 +25,6 @@ const routes = [
meta: {
title: ''
},
redirect: '/home',
component: () => import('v/base/Index.vue'),
children: [...indexHome, ...indexActive]
},
......@@ -197,11 +196,10 @@ function checkCam(code, cb) {
}
router.beforeEach((to, from, next) => {
console.log(from)
if (from.path != '/' &&
from.path != '/baseLogin' &&
from.path != '/baseRegister' &&
from.path != '/baseReset') {
if (!(from.path == '/' && from.name == null) &&
(from.path != '/baseLogin' &&
from.path != '/baseRegister' &&
from.path != '/baseReset')) {
store.commit('setPreviousPath', from.path);
}
if (to.query && to.query.disCode) {
......@@ -214,7 +212,7 @@ router.beforeEach((to, from, next) => {
toBaseLogin = "/baseLogin",
toBaseRegister = "/baseRegister",
toBaseReset = "/baseReset",
toHome = "/home",
toHome = "/",
toActive = "/active",
toInfo = "/myInfo";
let code = false;
......
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