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 @@