diff --git a/config/index.js b/config/index.js index 2de949f..9e989f1 100644 --- a/config/index.js +++ b/config/index.js @@ -11,7 +11,7 @@ module.exports = (() => { config.Timeout = 10000 // 请求超时时间,单位 ms // 基础服务器地址 - config.BASE_URL = 'http://qxk.leadfyy.com' // 开发环境 + config.BASE_URL = 'http://127.0.0.1:8000' // 开发环境 // config.BASE_URL = '' // 生产环境 diff --git a/packages/agent/agent.vue b/packages/agent/agent.vue new file mode 100644 index 0000000..c90978a --- /dev/null +++ b/packages/agent/agent.vue @@ -0,0 +1,127 @@ + + + + + \ No newline at end of file diff --git a/pages.json b/pages.json index bae921f..8f0272f 100644 --- a/pages.json +++ b/pages.json @@ -117,6 +117,12 @@ "navigationBarTitleText": "", "enablePullDownRefresh": false } + },{ + "path": "agent/agent", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": false + } }] }], "globalStyle": { diff --git a/pages/index/index.vue b/pages/index/index.vue index a036ab4..6f28aea 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -185,6 +185,7 @@ async getUserCenterDetail(){ let res = await my(); + uni.setStorageSync('userInfo', res.data.datas.user); this.user = res.data.datas.user; this.dots = res.data.datas.dots; let evaluated_order = res.data.datas.evaluated_order; diff --git a/pages/settings/settings.vue b/pages/settings/settings.vue index fcdfd9a..fdc63b0 100644 --- a/pages/settings/settings.vue +++ b/pages/settings/settings.vue @@ -10,6 +10,8 @@ + + {{ version ? 'v'+ version : '' }} @@ -36,6 +38,9 @@ uni.previewImage({ urls: [this.userInfo.avatar] }) + }, + isAgent(){ + return this.userInfo.is_agent } } } diff --git a/service/agreementArticle.js b/service/agreementArticle.js index d491e50..f946d56 100644 --- a/service/agreementArticle.js +++ b/service/agreementArticle.js @@ -38,4 +38,12 @@ export async function ratingStandard() { url: '/api/v1/content/rating_standard', method: 'post' }) +} + +//更新优惠券 +export async function couponUpdate() { + return await request({ + url: '/api/v1/coupon_update', + method: 'post' + }) } \ No newline at end of file