Showing
1 changed file
with
2 additions
and
1 deletions
| @@ -72,6 +72,7 @@ function rpc(host='',act,data={},fouce=false,header={},silence=true,cachetime=0, | @@ -72,6 +72,7 @@ function rpc(host='',act,data={},fouce=false,header={},silence=true,cachetime=0, | ||
| 72 | if(api.openid){ | 72 | if(api.openid){ |
| 73 | data[api.openid]=data[api.openid]||openid; | 73 | data[api.openid]=data[api.openid]||openid; |
| 74 | } | 74 | } |
| 75 | + let stime=new Date(); | ||
| 75 | wx.request({ | 76 | wx.request({ |
| 76 | url: host+act, | 77 | url: host+act, |
| 77 | method: 'POST', | 78 | method: 'POST', |
| @@ -84,7 +85,7 @@ function rpc(host='',act,data={},fouce=false,header={},silence=true,cachetime=0, | @@ -84,7 +85,7 @@ function rpc(host='',act,data={},fouce=false,header={},silence=true,cachetime=0, | ||
| 84 | 'content-type': 'application/x-www-form-urlencoded' | 85 | 'content-type': 'application/x-www-form-urlencoded' |
| 85 | }, | 86 | }, |
| 86 | success: function (res) { | 87 | success: function (res) { |
| 87 | - console.log('request.api==>',host+cache_key+'\nrequest.success',res.data); | 88 | + console.log('request.api['+(new Date()-stime)+'ms]==>',host+cache_key+'\nrequest.success',res.data); |
| 88 | // return; | 89 | // return; |
| 89 | if(res.data){ | 90 | if(res.data){ |
| 90 | if(cachetime!=0 && res.data.ret==200){ | 91 | if(cachetime!=0 && res.data.ret==200){ |
-
Please register or login to post a comment