...
|
...
|
@@ -66,6 +66,30 @@ class PayModel |
|
|
$result['count'] = $order['payment_amount'];
|
|
|
$result['paymentType'] = ($order['payment_type'] == 1 ? '在线支付' : '货到付款');
|
|
|
|
|
|
//统计成交的skn
|
|
|
$sknList = array();
|
|
|
$skuList = array();
|
|
|
$goodsData = array();
|
|
|
$pinyouGoodsArr = array();
|
|
|
foreach ($order['order_goods'] as $val) {
|
|
|
$sknList[] = $val['product_skn'];
|
|
|
$skuList[] = $val['product_sku'];
|
|
|
$goodsData[] = array(
|
|
|
'goods_name' => $val['product_name'],
|
|
|
'product_sku' => $val['product_sku'],
|
|
|
'price' => $val['goods_price'],
|
|
|
'number' => $val['buy_number']
|
|
|
);
|
|
|
$pinyouGoodsArr[] = $val['product_id'] . ',' . $val['buy_number'];
|
|
|
}
|
|
|
$result['goodsData'] = $goodsData;
|
|
|
// skn列表
|
|
|
$result['sknList'] = implode(',', $sknList);
|
|
|
// sku列表
|
|
|
$result['skuList'] = implode(',', $skuList);
|
|
|
// 品友统计需要的商品数据
|
|
|
$result['pinyouGoods'] = implode(';', $pinyouGoodsArr);
|
|
|
|
|
|
// 货到付款的情况
|
|
|
if ($order['payment_type'] == 2) {
|
|
|
$result['finish'] = true;
|
...
|
...
|
@@ -87,26 +111,6 @@ class PayModel |
|
|
}
|
|
|
|
|
|
$result['deliveryType'] =isset($order['delivery_time']) ? $order['delivery_time'] : '';
|
|
|
|
|
|
//统计成交的skn
|
|
|
$sknList = array();
|
|
|
$skuList = array();
|
|
|
$goodsData = array();
|
|
|
foreach ($order['order_goods'] as $val) {
|
|
|
$sknList[] = $val['product_skn'];
|
|
|
$skuList[] = $val['product_sku'];
|
|
|
$goodsData[] = array(
|
|
|
'goods_name' => $val['product_name'],
|
|
|
'product_sku' => $val['product_sku'],
|
|
|
'price' => $val['goods_price'],
|
|
|
'number' => $val['buy_number']
|
|
|
);
|
|
|
}
|
|
|
$result['goodsData'] = $goodsData;
|
|
|
// skn列表
|
|
|
$result['sknList'] = implode(',', $sknList);
|
|
|
// sku列表
|
|
|
$result['skuList'] = implode(',', $skuList);
|
|
|
|
|
|
// 用户ID
|
|
|
$result['uid'] = $uid;
|
...
|
...
|
@@ -220,7 +224,6 @@ class PayModel |
|
|
$result['orderGoods'] = $order['order_goods'];
|
|
|
// 订单商品数(用于订单统计)
|
|
|
$result['ordersGoodsNums'] = count($order['order_goods']);
|
|
|
|
|
|
} while (false);
|
|
|
|
|
|
return $result;
|
...
|
...
|
|