Commit 7cd66b07c58e6143cceade2a92ffbda6012569f7

Authored by yvan.ni
1 parent 87bfec95

1. 在调用接口获取会员信息的时候,要用随机码,避免接口的缓存

Showing 1 changed file with 2 additions and 0 deletions
utils/auth.js
@@ -128,6 +128,7 @@ module.exports = { @@ -128,6 +128,7 @@ module.exports = {
128 var app_d = this.app().globalData, oo = app_d.setting; 128 var app_d = this.app().globalData, oo = app_d.setting;
129 var ab = this.app().request; 129 var ab = this.app().request;
130 ab.get("/api/weshop/users/get/" + oo.stoid + "/" + app_d.user_id, { 130 ab.get("/api/weshop/users/get/" + oo.stoid + "/" + app_d.user_id, {
  131 + data:{r:Math.random()},
131 success: function (e) { 132 success: function (e) {
132 app_d.userInfo = e.data.data; 133 app_d.userInfo = e.data.data;
133 "function" == typeof t && t(e.data.data); 134 "function" == typeof t && t(e.data.data);
@@ -140,6 +141,7 @@ module.exports = { @@ -140,6 +141,7 @@ module.exports = {
140 if (app_d.user_id != "" && app_d.user_id != null ){ 141 if (app_d.user_id != "" && app_d.user_id != null ){
141 var ab = this.app().request; 142 var ab = this.app().request;
142 ab.get("/api/weshop/users/get/" + oo.stoid+"/"+app_d.user_id, { 143 ab.get("/api/weshop/users/get/" + oo.stoid+"/"+app_d.user_id, {
  144 + data:{r:Math.random()},
143 success: function (e) { 145 success: function (e) {
144 app_d.userInfo = e.data.data; 146 app_d.userInfo = e.data.data;
145 "function" == typeof t && t(e.data.data); 147 "function" == typeof t && t(e.data.data);