Commit 1d8444cf29c2af39ba9a5352826f95141c70fe54

Authored by WXD-SEASON\season
1 parent 6b8227e5

支付增加日志

Showing 1 changed file with 8 additions and 2 deletions
utils/pay.js
... ... @@ -41,6 +41,7 @@ module.exports = {
41 41 n.post(this.url, {
42 42 data: dd,
43 43 success: function(t) {
  44 + console.log('======', t)
44 45 wx.hideLoading();
45 46 if(t.data.code==0){
46 47  
... ... @@ -51,12 +52,16 @@ module.exports = {
51 52 reqType:"11",//必填 01-商户模式,11-机构模式
52 53 reqData:t.data.data.reqData,//必填 富友加密参数
53 54 }
  55 + console.log(plugin, plugin.fuioupay)
54 56 plugin.fuioupay(parseInt(t.data.data.amt),paramsJson,function (res){
  57 + console.log(res);
55 58 wx_paying=0;
56 59 getApp().showSuccess("支付成功!", e);
57 60  
58   - },function (){
  61 + },function (error){
  62 + console.log("插件支付错误",error);
59 63 //支付失败的时候
  64 + getApp().confirmBox(error.code+error.message);
60 65 setTimeout(function(){
61 66 wx.redirectTo({
62 67 url: "/pages/user/order_list/order_list",
... ... @@ -82,7 +87,8 @@ module.exports = {
82 87 return false;
83 88 },
84 89 fail: function() {
85   - wx.hideLoading();
  90 + console.log('======fail', )
  91 + wx.hideLoading();
86 92 wx_paying=0;
87 93 "function" == typeof a && a();
88 94 },
... ...