|
|
|
@ -203,7 +203,8 @@ select combo_id as c_id,count(*) as count from orders where status in(2,4) group
|
|
|
|
$combo_info=[];//套餐信息
|
|
|
|
$combo_info=[];//套餐信息
|
|
|
|
$pay_item_count=0;//需自费项目个数
|
|
|
|
$pay_item_count=0;//需自费项目个数
|
|
|
|
$all_original_price=0;
|
|
|
|
$all_original_price=0;
|
|
|
|
if(isset($combo_id)){
|
|
|
|
$true_price=0;
|
|
|
|
|
|
|
|
if(isset($combo_id) and $combo_id!=0){
|
|
|
|
// $combo=DB::table('combos')->where(['hospital_id'=>$hospital_id,'combo_id'=>$combo_id,'status'=>1])->first();
|
|
|
|
// $combo=DB::table('combos')->where(['hospital_id'=>$hospital_id,'combo_id'=>$combo_id,'status'=>1])->first();
|
|
|
|
$combo=DB::select("select a.*,b.*,c.name as crowd_name from combos as a LEFT JOIN (
|
|
|
|
$combo=DB::select("select a.*,b.*,c.name as crowd_name from combos as a LEFT JOIN (
|
|
|
|
select combo_id as c_id,count(*) as sale_count from orders where status in(2,4) group by combo_id
|
|
|
|
select combo_id as c_id,count(*) as sale_count from orders where status in(2,4) group by combo_id
|
|
|
|
@ -251,6 +252,7 @@ select combo_id as c_id,count(*) as sale_count from orders where status in(2,4)
|
|
|
|
];
|
|
|
|
];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$pay_item_count+=$combo->item_count;
|
|
|
|
$pay_item_count+=$combo->item_count;
|
|
|
|
|
|
|
|
$true_price+=$combo_info['price'];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$items_info=[];//自选项目信息
|
|
|
|
$items_info=[];//自选项目信息
|
|
|
|
if(isset($item_ids) and !empty($item_ids)){
|
|
|
|
if(isset($item_ids) and !empty($item_ids)){
|
|
|
|
@ -286,7 +288,7 @@ select combo_id as c_id,count(*) as sale_count from orders where status in(2,4)
|
|
|
|
$save_money = 150;//预存款抵扣金额
|
|
|
|
$save_money = 150;//预存款抵扣金额
|
|
|
|
$coupon_money=50;//优惠券抵扣金额
|
|
|
|
$coupon_money=50;//优惠券抵扣金额
|
|
|
|
|
|
|
|
|
|
|
|
$true_price=$combo_info['price']+$items_info['price']; //用户真实支付价格,应减去抵扣(二期实现)
|
|
|
|
$true_price+=$items_info['price']; //用户真实支付价格,应减去抵扣(二期实现)
|
|
|
|
$data=[
|
|
|
|
$data=[
|
|
|
|
'combo_info'=>$combo_info,
|
|
|
|
'combo_info'=>$combo_info,
|
|
|
|
'items_info'=>$items_info,
|
|
|
|
'items_info'=>$items_info,
|
|
|
|
|