...
|
...
|
@@ -128,16 +128,15 @@ class MeGuaranteeController extends WeChatBaseController |
|
|
// $where['o.order_about_time'] = ['>',$time];
|
|
|
$whereor = "o.status = 1 and c.insurer = "."'".$insurer."'"." and o.order_about_time < $time and o.order_about_time > ".($time-30*24*60*60);
|
|
|
}else if($param['status'] == 3){
|
|
|
$where['o.status'] = ['eq',2];
|
|
|
$where['c.insurer'] = ['eq',$param['insurer']];
|
|
|
if(!empty($param['application']) && !empty($param['agent_phone'])){
|
|
|
$whereor = "o.status = 1 and c.insurer ="."'"."$insurer"."'"." and o.order_expire_time < $time and o.order_about_time < ".($time-24*30*60*60)." or o.status = 3 and o.order_expire_time < $time and c.application = "."'"."$param[application]"."'"." and c.agent_phone = $param[agent_phone] and c.insurer ="."'"."$insurer"."'"."or o.status = 3 and o.order_about_time < ".($time-24*30*60*60)." and c.insurer ="."'"."$insurer"."'";
|
|
|
$whereor = "o.status = 2 or o.status = 1 and c.insurer ="."'"."$insurer"."'"." and o.order_expire_time < $time and o.order_about_time < ".($time-24*30*60*60)." or o.status = 3 and o.order_expire_time < $time and c.application = "."'"."$param[application]"."'"." and c.agent_phone = $param[agent_phone] and c.insurer ="."'"."$insurer"."'"."or o.status = 3 and o.order_about_time < ".($time-24*30*60*60)." and c.insurer ="."'"."$insurer"."'";
|
|
|
}else if(!empty($param['application'])){
|
|
|
$whereor = "o.status = 1 and c.insurer ="."'"."$insurer"."'"." and o.order_expire_time < $time and o.order_about_time < ".($time-24*30*60*60)." or o.status = 3 and o.order_expire_time < $time and c.application = "."'"."$param[application]"."'"." and c.insurer ="."'"."$insurer"."'"."or o.status = 3 and o.order_about_time < ".($time-24*30*60*60)." and c.insurer ="."'"."$insurer"."'";
|
|
|
$whereor = "o.status = 2 or o.status = 1 and c.insurer ="."'"."$insurer"."'"." and o.order_expire_time < $time and o.order_about_time < ".($time-24*30*60*60)." or o.status = 3 and o.order_expire_time < $time and c.application = "."'"."$param[application]"."'"." and c.insurer ="."'"."$insurer"."'"."or o.status = 3 and o.order_about_time < ".($time-24*30*60*60)." and c.insurer ="."'"."$insurer"."'";
|
|
|
}else if(!empty($param['agent_phone'])){
|
|
|
$whereor = "o.status = 1 and c.insurer ="."'"."$insurer"."'"." and o.order_expire_time < $time and o.order_about_time < ".($time-24*30*60*60)." or o.status = 3 and o.order_expire_time < $time and c.agent_phone = $param[agent_phone] and c.insurer ="."'"."$insurer"."'"."or o.status = 3 and o.order_about_time < ".($time-24*30*60*60)." and c.insurer ="."'"."$insurer"."'";
|
|
|
$whereor = "o.status = 2 or o.status = 1 and c.insurer ="."'"."$insurer"."'"." and o.order_expire_time < $time and o.order_about_time < ".($time-24*30*60*60)." or o.status = 3 and o.order_expire_time < $time and c.agent_phone = $param[agent_phone] and c.insurer ="."'"."$insurer"."'"."or o.status = 3 and o.order_about_time < ".($time-24*30*60*60)." and c.insurer ="."'"."$insurer"."'";
|
|
|
}else{
|
|
|
$whereor = "o.status = 1 and c.insurer ="."'"."$insurer"."'"." and o.order_expire_time < $time and o.order_about_time < ".($time-24*30*60*60)." or o.status = 3 and o.order_expire_time < $time and c.insurer ="."'"."$insurer"."'"."or o.status = 3 and o.order_about_time < ".($time-24*30*60*60)." and c.insurer ="."'"."$insurer"."'";
|
|
|
$whereor = "o.status = 2 or o.status = 1 and c.insurer ="."'"."$insurer"."'"." and o.order_expire_time < $time and o.order_about_time < ".($time-24*30*60*60)." or o.status = 3 and o.order_expire_time < $time and c.insurer ="."'"."$insurer"."'"."or o.status = 3 and o.order_about_time < ".($time-24*30*60*60)." and c.insurer ="."'"."$insurer"."'";
|
|
|
}
|
|
|
}
|
|
|
}
|
...
|
...
|
|