add order mark
This commit is contained in:
parent
a8e58ebae4
commit
f661dc0c95
@ -88,6 +88,17 @@ class LogisticsLogic extends BaseLogic
|
|||||||
//获取物流信息
|
//获取物流信息
|
||||||
$logistics = Logistics::field('id,order_id,order_sn,shop_name,shop_user,shop_phone,shop_address,shop_long,shop_lat,receiver_name,receiver_phone,receiver_address,status,create_time,qh_time,ps_time,qx_time')
|
$logistics = Logistics::field('id,order_id,order_sn,shop_name,shop_user,shop_phone,shop_address,shop_long,shop_lat,receiver_name,receiver_phone,receiver_address,status,create_time,qh_time,ps_time,qx_time')
|
||||||
->where('id', $id)->find();
|
->where('id', $id)->find();
|
||||||
|
//查找订单信息
|
||||||
|
if(empty($logistics)){
|
||||||
|
return [
|
||||||
|
'logistics' => [],
|
||||||
|
'product' => [],
|
||||||
|
'product_count' => 0,
|
||||||
|
'record' => [],
|
||||||
|
];
|
||||||
|
}
|
||||||
|
$order = Order::alias('s')->where('order_id', $logistics['order_id'])->where('order_sn', $logistics['order_sn'])->find();
|
||||||
|
$logistics['mark'] = !empty($order) ? $order['mark'] : '';
|
||||||
//获取商品信息
|
//获取商品信息
|
||||||
$product_count = 0;
|
$product_count = 0;
|
||||||
$product = Product::field('product_num,cart_info')->where('order_id', $logistics['order_id'])->select()->each(function($pro_item) use(&$product_count){
|
$product = Product::field('product_num,cart_info')->where('order_id', $logistics['order_id'])->select()->each(function($pro_item) use(&$product_count){
|
||||||
|
Loading…
x
Reference in New Issue
Block a user