Browse Source

订单详情支付

qihanjiao 7 years ago
parent
commit
06ebf3e93e
1 changed files with 9 additions and 1 deletions
  1. 9 1
      aiberle/order-details.html

+ 9 - 1
aiberle/order-details.html

@@ -334,6 +334,10 @@
         $.ajax(base_path+'/wechat/cart/orderPay', { // 提交订单,准备支付
             data: dataArgs,
             dataType: 'json',
+            xhrFields: {
+				withCredentials: true
+			},
+			crossDomain: true,
             type: 'POST',
             timeout: 15000,
             success: function(dt) {
@@ -354,6 +358,10 @@
                             $.ajax(base_path+'/wechat/order/checkOrderPaySuccess', { // 校验订单状态
                                 data: orderIds,
                                 dataType: 'json',
+                                xhrFields: {
+                                	withCredentials: true
+                                },
+                                crossDomain: true,
                                 type: 'post',
                                 timeout: 15000,
                                 success: function(dt) {
@@ -374,7 +382,7 @@
                         } else {
                             isPay = true;
                             mui.alert("对不起,支付失败!请稍后重试!" + dt.data.orderId + "支付失败!");
-                            window.location.href = "order-details.html?orderId=" + dt.data.orderId; // 前往订单详情
+                            //window.location.href = "order-details.html?orderId=" + dt.data.orderId; // 前往订单详情
                         }
                     });
                 } else {