|
@@ -122,9 +122,14 @@ App({ |
|
@@ -122,9 +122,14 @@ App({ |
|
122
|
'content-type': 'application/x-www-form-urlencoded'
|
122
|
'content-type': 'application/x-www-form-urlencoded'
|
|
123
|
},
|
123
|
},
|
|
124
|
success: function (res) {
|
124
|
success: function (res) {
|
|
125
|
- let openid=res.data.data.openid;
|
|
|
|
126
|
- wx.setStorage({key:'customer_openid',data:openid});
|
|
|
|
127
|
- success(openid);
|
125
|
+ try{
|
|
|
|
126
|
+ let openid=res.data.data.openid;
|
|
|
|
127
|
+ wx.setStorage({key:'customer_openid',data:openid});
|
|
|
|
128
|
+ success(openid);
|
|
|
|
129
|
+ }catch(e){
|
|
|
|
130
|
+ console.log(res);
|
|
|
|
131
|
+ fail(res);
|
|
|
|
132
|
+ }
|
|
128
|
},
|
133
|
},
|
|
129
|
fail: function (res) {
|
134
|
fail: function (res) {
|
|
130
|
console.log(res);
|
135
|
console.log(res);
|