1.本地生活订单列表
This commit is contained in:
parent
ccda7bb2da
commit
c777332742
@ -249,7 +249,21 @@ class LocalStoreLogic extends Logic
|
||||
->where($s)
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
|
||||
$all_count = LocalGoodsStore::where('user_id',$post['user_id'])
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
$wait_count = LocalGoodsStore::where('user_id',$post['user_id'])
|
||||
->where("state",0)
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
$already_count = LocalGoodsStore::where('user_id',$post['user_id'])
|
||||
->where("state",1)
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
$cancel_count = LocalGoodsStore::where('user_id',$post['user_id'])
|
||||
->where("state",2)
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
$more = is_more($count, $post['page_no'], $post['page_size']); //是否有下一页
|
||||
|
||||
return [
|
||||
@ -257,6 +271,10 @@ class LocalStoreLogic extends Logic
|
||||
'page_no' => $post['page_no'],
|
||||
'page_size' => $post['page_size'],
|
||||
'count' => $count,
|
||||
'all_count'=>$all_count,
|
||||
'wait_count' => $wait_count,
|
||||
'already_count' => $already_count,
|
||||
'cancel_count' => $cancel_count,
|
||||
'more' => $more,
|
||||
];
|
||||
}
|
||||
@ -289,7 +307,21 @@ class LocalStoreLogic extends Logic
|
||||
->where($s)
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
|
||||
$all_count = LocalGoodsStore::where('lstore_id',$post['lstore_id'])
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
$wait_count = LocalGoodsStore::where('lstore_id',$post['lstore_id'])
|
||||
->where("state",0)
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
$already_count = LocalGoodsStore::where('lstore_id',$post['lstore_id'])
|
||||
->where("state",1)
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
$cancel_count = LocalGoodsStore::where('lstore_id',$post['lstore_id'])
|
||||
->where("state",2)
|
||||
->where("state <> 3")
|
||||
->count();
|
||||
$more = is_more($count, $post['page_no'], $post['page_size']); //是否有下一页
|
||||
|
||||
return [
|
||||
@ -297,6 +329,10 @@ class LocalStoreLogic extends Logic
|
||||
'page_no' => $post['page_no'],
|
||||
'page_size' => $post['page_size'],
|
||||
'count' => $count,
|
||||
'all_count'=>$all_count,
|
||||
'wait_count' => $wait_count,
|
||||
'already_count' => $already_count,
|
||||
'cancel_count' => $cancel_count,
|
||||
'more' => $more,
|
||||
];
|
||||
}
|
||||
|
||||
@ -660,7 +660,7 @@ class PayLogic extends Logic
|
||||
//本地商家支付
|
||||
public static function localWxPay($user_id,$post,$client){
|
||||
// $post['lid'] = 10;
|
||||
$out_trade_no = createSn('order_trade', 't_sn');
|
||||
$out_trade_no = createSn('local_goods_order', 'order_no');
|
||||
$res = WeChatPayServer::localserverWxPay($out_trade_no,$user_id,$post, $client);
|
||||
if (false === $res) {
|
||||
return JsonServer::error(WeChatPayServer::getError());
|
||||
@ -677,7 +677,7 @@ class PayLogic extends Logic
|
||||
$data['goods_id'] = $sku_num_msg['goods_id'];
|
||||
}
|
||||
$data['goods_num'] = $post['goods_num'];
|
||||
$data['order_sn'] = $out_trade_no;
|
||||
$data['order_no'] = $out_trade_no;
|
||||
$data['order_source'] = 1;
|
||||
$data['pay_way'] = 1;
|
||||
$data['pay_status'] = 0;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user