Commit e68ec36f by liwk

commit

1 parent 47e15e16
import Vue from 'vue'
import VueRouter from 'vue-router'
import routes from './routes'
import { Toast } from 'vant'
Vue.use(VueRouter)
const router = new VueRouter({
routes
})
import {
Toast,
Notify
} from 'vant'
import store from '@/store'
import { common } from '../api/api'
Vue.use(VueRouter)
const router = new VueRouter({
routes
})
router.beforeEach((to, from, next) => {
let { meta: { authBase } } = to
if (to.name != 'common.phoneLogin') store.commit('jumpPath', to.name)
if (to.matched.some(recode => recode.meta.hasAuth)) {
if (to.matched.some(recode => recode.meta.wxAuth)) {
const ua = navigator.userAgent.toLowerCase()
const params = getParams(window.location.href)
if (window.__wxjs_environment === 'miniprogram') {
......
const pages = {
equity: [{ name: 'index', hasAuth: true }, { name: 'road', title: '道路救援' }],
equity: [{ name: 'index', wxAuth: true }, { name: 'road', title: '道路救援' }],
common: [
{ name: 'index', hasAuth: true },
{ name: 'index', wxAuth: true },
{ name: 'activate', title: '激活权益' },
{ name: 'explain', title: '常见疑问' },
{ name: 'phoneLogin', title: '登录' },
......@@ -11,12 +11,12 @@ const pages = {
title: '绑定挪车码'
}, {
name: 'index',
hasAuth: true,
wxAuth: true,
title: '绑定挪车码'
}],
device: [{
name: 'index',
hasAuth: true,
wxAuth: true,
authBase: true,
title: '设备关联'
},
......
......@@ -115,7 +115,8 @@ export default {
},
methods: {
jump () {
window.location.href = `${window.location.href.split('#')[0]}/#/car/index`
const appId = sessionStorage.getItem('GL_WX_APPID')
window.location.href = `${window.location.href.split('#')[0]}/#/car/index?appId=${appId}`
}
}
}
......
......@@ -45,6 +45,9 @@
<div class="add">
<div class="sprite-icon icon-device-add"></div>
上传安装设备的车辆VIN码
<div class="tips">
注:<div>VIN码是车辆车架号,通常位于<br>汽车前挡风玻璃左/右下角</div>
</div>
</div>
</template>
</div>
......@@ -318,9 +321,21 @@ export default {
.add {
font-size: 16px;
color: #999999;
text-align: center;
.icon-device-add {
margin: 0 auto 10px;
}
.tips {
margin-top: 12px;
color: #c6c6c6;
font-size: 10px;
display: flex;
align-items: flex-start;
justify-content: center;
div {
text-align: left;
}
}
}
}
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!