|
@@ -53,7 +53,7 @@ class CheckOrderStatus extends Command
|
|
|
if($uid) {
|
|
|
$this->checkOne($uid);
|
|
|
}else{
|
|
|
- $sql_format = 'SELECT uid FROM user_month_sign WHERE created_at >= DATE_ADD(NOW(),INTERVAL -1 hour) and
|
|
|
+ $sql_format = 'SELECT uid FROM user_month_sign WHERE created_at >= DATE_ADD(NOW(),INTERVAL -1 hour) and `type`="MONTH" and
|
|
|
NOT EXISTS (SELECT id FROM user_month_order WHERE user_month_order.uid =user_month_sign.uid and created_at BETWEEN "%s" and "%s" )';
|
|
|
$sql = sprintf($sql_format,date('Y-m-01'),date('Y-m-01',strtotime('+1 month')));
|
|
|
$result = DB::select($sql);
|