Authored by 周少峰

order point unionKey

@@ -866,7 +866,7 @@ $('.to-play input.submit').click(function() { @@ -866,7 +866,7 @@ $('.to-play input.submit').click(function() {
866 productSkn.push($(this).attr('data-skn')); 866 productSkn.push($(this).attr('data-skn'));
867 productSku.push($(this).attr('data-sku')); 867 productSku.push($(this).attr('data-sku'));
868 }); 868 });
869 - window.addPoint('YB_SC_TOPAY_CLICK', {ORDER_CODE: d.data.order_code, PRD_NUM: productNum, ORDER_AMOUNT: d.data.order_amount, PRO_SKN: productSkn.join(','), PRO_SKU:productSku.join(','), UNIONCOOKIE: d.data.unionKey}); 869 + window.addPoint('YB_SC_TOPAY_CLICK', {ORDER_CODE: d.data.order_code, PRD_NUM: productNum, ORDER_AMOUNT: d.data.order_amount, PRO_SKN: productSkn.join(','), PRO_SKU:productSku.join(','), UNIONCOOKIE: encodeURIComponent(d.data.unionKey + '') || ''});
870 window.location.href = d.data.payUrl; 870 window.location.href = d.data.payUrl;
871 } 871 }
872 } else { 872 } else {
@@ -1080,7 +1080,9 @@ class CartModel @@ -1080,7 +1080,9 @@ class CartModel
1080 1080
1081 $orderSubRes = CartData::orderSub($uid, $addressId, $cartType, $deliveryTimeId, $deliveryWayId, $invoiceType, $invoiceTitle, $invoiceContent, $receiverMobile, $paymentId, $paymentType, $remark, $couponCode, $promotionCode, $yohoCoin, $isPreContact, $isPrintPrice, $unionKey, $userAgent, $redEnvelopes, $isContinueBuy); 1081 $orderSubRes = CartData::orderSub($uid, $addressId, $cartType, $deliveryTimeId, $deliveryWayId, $invoiceType, $invoiceTitle, $invoiceContent, $receiverMobile, $paymentId, $paymentType, $remark, $couponCode, $promotionCode, $yohoCoin, $isPreContact, $isPrintPrice, $unionKey, $userAgent, $redEnvelopes, $isContinueBuy);
1082 if ($orderSubRes && isset($orderSubRes['code'])) { 1082 if ($orderSubRes && isset($orderSubRes['code'])) {
1083 - $orderSubRes['data']['unionKey'] = $unionKey; 1083 + $before = array(" "," ","\t","\n","\r");
  1084 + $after = array("","","","","");
  1085 + $orderSubRes['data']['unionKey'] = str_replace($before, $after, json_encode($unionKey));
1084 $result = $orderSubRes; 1086 $result = $orderSubRes;
1085 } 1087 }
1086 } while (false); 1088 } while (false);