|
...
|
...
|
@@ -339,7 +339,8 @@ class GeoQuestionRes extends Command |
|
|
|
$key = 'geo_task_list';
|
|
|
|
$task_id = Redis::rpop($key);
|
|
|
|
if(empty($task_id)){
|
|
|
|
$project_ids = GeoQuestion::where('status', GeoQuestion::STATUS_OPEN)->where('next_time', '<=', date('Y-m-d'))->orderBy('next_time', 'asc')->groupBy('project_id')->pluck('project_id');
|
|
|
|
$project_ids = GeoQuestion::where('status', GeoQuestion::STATUS_OPEN)->where('next_time', '<=', date('Y-m-d'))
|
|
|
|
->orderBy('next_time', 'asc')->pluck('project_id')->unique()->values()->toArray();
|
|
|
|
if(!empty($project_ids)){
|
|
|
|
foreach ($project_ids as $project_id){
|
|
|
|
$ids = GeoQuestion::where(['project_id' => $project_id, 'status' => GeoQuestion::STATUS_OPEN])->where('next_time', '<=', date('Y-m-d'))->pluck('id');
|
...
|
...
|
|