...
|
...
|
@@ -67,7 +67,8 @@ class Coupons extends Api |
|
|
}
|
|
|
|
|
|
$flag = config('verify.flag');
|
|
|
$where = ['is_new'=>$flag[0],'end_time'=>['>',time()]];
|
|
|
$current_time = time();
|
|
|
$where = ['is_new'=>$flag[0],'start_time'=>['<',$current_time],'end_time'=>['>',$current_time]];
|
|
|
//查询已经领取过
|
|
|
$receive = Common::selectWhereData('rcoupon',['uid'=>$this->uid],'id,c_id');
|
|
|
$receive_s = array_column($receive,'c_id');
|
...
|
...
|
@@ -181,7 +182,8 @@ class Coupons extends Api |
|
|
}
|
|
|
|
|
|
$flag = config('verify.flag');
|
|
|
$where = ['is_new'=>$flag[0],'type'=>$flag[1],'bg_id'=>$b_id,'end_time'=>['>',time()]];
|
|
|
$current_time = time();
|
|
|
$where = ['is_new'=>$flag[0],'type'=>$flag[1],'bg_id'=>$b_id,'start_time'=>['<',$current_time],'end_time'=>['>',$current_time]];
|
|
|
//查询已经领取过
|
|
|
$receive = Common::selectWhereData('rcoupon',['uid'=>$this->uid],'id,c_id');
|
|
|
$receive_s = array_column($receive,'c_id');
|
...
|
...
|
@@ -279,7 +281,8 @@ class Coupons extends Api |
|
|
}
|
|
|
|
|
|
$type = config('verify.type');
|
|
|
$where = ['type'=>$type[2],'bg_id'=>$goods_id,'end_time'=>['>',time()]];
|
|
|
$current_time = time();
|
|
|
$where = ['type'=>$type[2],'bg_id'=>$goods_id,'start_time'=>['<',$current_time],'end_time'=>['>',$current_time]];
|
|
|
//查询已经领取过
|
|
|
$receive = Common::selectWhereData('rcoupon',['uid'=>$this->uid],'id,c_id');
|
|
|
$receive_s = array_column($receive,'c_id');
|
...
|
...
|
|