作者 lyh

gx

@@ -58,6 +58,7 @@ class VideoTask extends Command @@ -58,6 +58,7 @@ class VideoTask extends Command
58 */ 58 */
59 public function handle() 59 public function handle()
60 { 60 {
  61 + echo '开始:';
61 Log::info('开始视频推广任务'); 62 Log::info('开始视频推广任务');
62 $this->createSubTask(); 63 $this->createSubTask();
63 // $this->sendSubTask(); 64 // $this->sendSubTask();
@@ -88,6 +89,7 @@ class VideoTask extends Command @@ -88,6 +89,7 @@ class VideoTask extends Command
88 $task_project->save(); 89 $task_project->save();
89 continue; 90 continue;
90 } 91 }
  92 + echo '开始:1';
91 ProjectServer::useProject($task_project->project_id); 93 ProjectServer::useProject($task_project->project_id);
92 $keyword = $this->getProjectKeyword(); 94 $keyword = $this->getProjectKeyword();
93 // 已经没有需要生成视频的关键词 95 // 已经没有需要生成视频的关键词
@@ -96,6 +98,7 @@ class VideoTask extends Command @@ -96,6 +98,7 @@ class VideoTask extends Command
96 $task_project->save(); 98 $task_project->save();
97 continue; 99 continue;
98 } 100 }
  101 + echo '开始:2';
99 foreach ($keyword as $val) { 102 foreach ($keyword as $val) {
100 $log = KeywordVideoTaskLog::where(['project_id' => $task_project->project_id, 'keyword_id' => $val->id])->first(); 103 $log = KeywordVideoTaskLog::where(['project_id' => $task_project->project_id, 'keyword_id' => $val->id])->first();
101 if ($log){ 104 if ($log){
@@ -117,6 +120,7 @@ class VideoTask extends Command @@ -117,6 +120,7 @@ class VideoTask extends Command
117 $task_project->status = KeywordVideoTask::STATUS_CLOSE; 120 $task_project->status = KeywordVideoTask::STATUS_CLOSE;
118 $task_project->save(); 121 $task_project->save();
119 } 122 }
  123 + echo '开始:3';
120 return true; 124 return true;
121 } 125 }
122 126