From 14483493c2a292ef46fbb0bc7521427a627c0d78 Mon Sep 17 00:00:00 2001 From: Enzo <1284707383@qq.com> Date: Tue, 27 Jul 2021 18:20:34 +0800 Subject: [PATCH] =?UTF-8?q?=E6=88=91=E7=9A=84=E8=AE=A2=E5=8D=95=20?= =?UTF-8?q?=E5=95=86=E5=93=81=E8=AF=A6=E6=83=85=20=E9=A6=96=E9=A1=B5?= =?UTF-8?q?=E4=B8=93=E9=A2=98=E5=88=97=E8=A1=A8=20=E4=B8=93=E9=A2=98?= =?UTF-8?q?=E8=AF=A6=E6=83=85=20=E6=88=91=E7=9A=84=E6=8E=A8=E8=8D=90?= =?UTF-8?q?=E5=88=97=E8=A1=A8=20=E5=8F=96=E6=B6=88=E6=94=B6=E8=97=8F=20?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=94=B6=E8=97=8F=20=E5=95=86=E5=93=81?= =?UTF-8?q?=E5=88=97=E8=A1=A8=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- App.vue | 2 +- common/api.js | 10 ++ common/http.js | 4 +- components/lf-waterfall/lf-waterfall.vue | 8 +- pages/activityList/index.vue | 43 ++++---- pages/collect/index.vue | 106 ++++++++++++------- pages/goodsDetail/index.vue | 104 ++++++------------- pages/goodsList/index.vue | 34 +++--- pages/index/index.vue | 33 +++--- pages/message/index.vue | 4 +- pages/order/order.vue | 125 ++++++++++++++++++----- pages/user/user.vue | 107 ++++++------------- 12 files changed, 312 insertions(+), 268 deletions(-) diff --git a/App.vue b/App.vue index 1cefd21..39caf38 100644 --- a/App.vue +++ b/App.vue @@ -11,7 +11,7 @@ onLaunch: function() { this.disableConsole(); this.getSystemInfo(); - // this.getUserInfo(); + this.getUserInfo(); }, onShow: function() { // #ifdef MP-WEIXIN diff --git a/common/api.js b/common/api.js index bb4377f..4a61a53 100644 --- a/common/api.js +++ b/common/api.js @@ -22,14 +22,24 @@ export const API_ADVICELIST = '/api/agent_product/list'; //推荐列表 export const API_CATEGORYLIST = '/api/category/list'; //推荐分类 export const API_ADVICEDETAILS = '/api/agent_product/show'; //推荐列表详情 +export const API_PRODUCTLIST = '/api/channel/product'; //频道产品列表 +export const API_SPECIALLIST = '/api/special/show'; //专题列表 + + export const API_MESSAGELIST = '/api/message/list'; //消息列表 export const API_MESSAGEDETAILS = '/api/message/show'; //消息详情 export const API_CHECKNEWS = '/api/message/read'; //消息标记为已读 +export const API_RECOMMOND = '/api/agent_product/recommend'; //我的推荐列表 + +//订单 +export const API_ORDERLIST = '/api/order/list'; //订单列表 //系统 export const API_ABOUTUS = '/api/agent_info/about'; //关于我们 export const API_COLLECT_LIST = '/api/fav/list'; //收藏列表 +export const API_ADDCOLLECT = '/api/fav/create'; //添加收藏 +export const API_DELCOLLECT = '/api/fav/delete'; //删除收藏 diff --git a/common/http.js b/common/http.js index c59a91b..0ce021a 100644 --- a/common/http.js +++ b/common/http.js @@ -92,7 +92,9 @@ function $http(url, data = {}, options = {}){ //商户id options.appid = 'wx0e8ebcd9ca9e4b97' - options.Authentication = 'c4ca4238a0b923820dcc509a6f75849b' + let user_info = uni.getStorageSync('userinfo') + let user_token = user_info.token + options.Authentication = user_token // 发起请求 that.$u.post(url, data, options).then(res => { resolve(res); diff --git a/components/lf-waterfall/lf-waterfall.vue b/components/lf-waterfall/lf-waterfall.vue index 9c9fba4..60e294c 100644 --- a/components/lf-waterfall/lf-waterfall.vue +++ b/components/lf-waterfall/lf-waterfall.vue @@ -2,7 +2,7 @@