Commit f2a53a7e by LJM

关于我们

parent bdb170b3
...@@ -35,12 +35,12 @@ ...@@ -35,12 +35,12 @@
"navigationBarTitleText": "分类列表" "navigationBarTitleText": "分类列表"
} }
}, },
{ {
"path": "pages/brand/brand", "path": "pages/brand/brand",
"style": { "style": {
"navigationBarTitleText": "品牌详情" "navigationBarTitleText": "品牌详情"
} }
}, },
{ {
"path": "pages/mine/login", "path": "pages/mine/login",
"style": { "style": {
...@@ -100,7 +100,31 @@ ...@@ -100,7 +100,31 @@
"style": { "style": {
"navigationBarTitleText": "京东卡" "navigationBarTitleText": "京东卡"
} }
} },
{
"path": "pages/mine/zqsx",
"style": {
"navigationBarTitleText": "账期服务"
}
},
{
"path": "pages/mine/news",
"style": {
"navigationBarTitleText": "新闻"
}
},
{
"path": "pages/mine/article",
"style": {
"navigationBarTitleText": "新闻详情"
}
},
{
"path": "pages/mine/about",
"style": {
"navigationBarTitleText": "关于我们"
}
},
], ],
"globalStyle": { "globalStyle": {
......
<template>
<view class="page-user">账期服务</view>
</template>
<script>
import { Api_Url } from '@/util/api.js';
export default {
data() {
return {};
},
onShow() {
this.getData();
},
methods: {
getData() {
this.request(Api_Url + '/user/getUserType', 'POST', {}, true, true).then(res => {
if (res.err_code === 0) {
this.userInfo = res.data;
}
});
}
}
};
</script>
<style lang="scss">
@import '@/assets/css/mine/zqsx.scss';
</style>
<template>
<view class="page-user">新闻</view>
</template>
<script>
import { Api_Url } from '@/util/api.js';
export default {
data() {
return {};
},
onShow() {
this.getData();
},
methods: {
getData() {
this.request(Api_Url + '/user/getUserType', 'POST', {}, true, true).then(res => {
if (res.err_code === 0) {
this.userInfo = res.data;
}
});
}
}
};
</script>
<style lang="scss">
@import '@/assets/css/mine/zqsx.scss';
</style>
<template>
<view class="page-user">新闻</view>
</template>
<script>
import { Api_Url } from '@/util/api.js';
export default {
data() {
return {};
},
onShow() {
this.getData();
},
methods: {
getData() {
this.request(Api_Url + '/user/getUserType', 'POST', {}, true, true).then(res => {
if (res.err_code === 0) {
this.userInfo = res.data;
}
});
}
}
};
</script>
<style lang="scss">
@import '@/assets/css/mine/zqsx.scss';
</style>
...@@ -77,10 +77,10 @@ ...@@ -77,10 +77,10 @@
<text class="iconfont icon-a-juxingbeifen142"></text> <text class="iconfont icon-a-juxingbeifen142"></text>
<text class="tt">京东卡</text> <text class="tt">京东卡</text>
</navigator> </navigator>
<view class="box column rowCenter verCenter"> <!-- <view class="box column rowCenter verCenter">
<text class="iconfont icon-a-juxingbeifen143"></text> <text class="iconfont icon-a-juxingbeifen143"></text>
<text class="tt">我的物料库</text> <text class="tt">我的物料库</text>
</view> </view> -->
<view class="box column rowCenter verCenter"> <view class="box column rowCenter verCenter">
<text class="iconfont icon-a-juxingbeifen144"></text> <text class="iconfont icon-a-juxingbeifen144"></text>
<text class="tt">询价记录</text> <text class="tt">询价记录</text>
......
<template>
<view class="page-user">账期服务</view>
</template>
<script>
import { Api_Url } from '@/util/api.js';
export default {
data() {
return {};
},
onShow() {
this.getData();
},
methods: {
getData() {
this.request(Api_Url + '/user/getUserType', 'POST', {}, true, true).then(res => {
if (res.err_code === 0) {
this.userInfo = res.data;
}
});
}
}
};
</script>
<style lang="scss">
@import '@/assets/css/mine/zqsx.scss';
</style>
// router/index.js // router/index.js
import Vue from 'vue' import Vue from 'vue'
import Router from 'uni-simple-router' import Router from 'uni-simple-router'
import {Ichunt_Api,Api_Url} from '@/util/api.js'; import { Ichunt_Api, Api_Url } from '@/util/api.js';
import { request,getCookie,setCookie} from '@/util/util.js' import { request, getCookie, setCookie } from '@/util/util.js'
Vue.use(Router) Vue.use(Router)
//初始化 //初始化
const router = new Router({ const router = new Router({
...@@ -58,13 +58,13 @@ const router = new Router({ ...@@ -58,13 +58,13 @@ const router = new Router({
title: '分类列表' title: '分类列表'
} }
}, },
{ {
path: '/pages/brand/brand', path: '/pages/brand/brand',
aliasPath: '/brand/:brand_id', aliasPath: '/brand/:brand_id',
meta: { meta: {
title: '品牌详情' title: '品牌详情'
} }
}, },
{ {
path: '/pages/mine/login', path: '/pages/mine/login',
aliasPath: '/login', aliasPath: '/login',
...@@ -134,23 +134,51 @@ const router = new Router({ ...@@ -134,23 +134,51 @@ const router = new Router({
meta: { meta: {
title: '京东卡' title: '京东卡'
} }
},
{
path: '/pages/mine/zqsx',
aliasPath: '/activity/zqsx',
meta: {
title: '账期服务'
}
},
{
path: '/pages/mine/news',
aliasPath: '/news',
meta: {
title: '新闻'
}
},
{
path: '/pages/mine/article',
aliasPath: '/article',
meta: {
title: '新闻详情'
}
},
{
path: '/pages/mine/about',
aliasPath: '/about',
meta: {
title: '关于我们'
}
} }
] ]
}); });
//全局路由前置守卫 //全局路由前置守卫
router.beforeEach((to, from, next) => { router.beforeEach((to, from, next) => {
//写入 Yo4teW_gid Yo4teW_csrf //写入 Yo4teW_gid Yo4teW_csrf
if (!getCookie("Yo4teW_gid")) { if (!getCookie("Yo4teW_gid")) {
request(Api_Url + "/public/apiInit", 'get', {}).then(res => { request(Api_Url + "/public/apiInit", 'get', {}).then(res => {
if (res.err_code === 0) { if (res.err_code === 0) {
setCookie('Yo4teW_gid', res.data.Yo4teW_gid, 15); setCookie('Yo4teW_gid', res.data.Yo4teW_gid, 15);
setCookie('Yo4teW_csrf', res.data.Yo4teW_csrf, 15); setCookie('Yo4teW_csrf', res.data.Yo4teW_csrf, 15);
next() next()
} }
}); });
return return
} }
next() next()
}) })
// 全局路由后置守卫 // 全局路由后置守卫
......
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 sign in to comment