mead 2 месяцев назад
Родитель
Сommit
f71585d8bd
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      app/Console/Commands/InitCourseCommand.php

+ 2 - 2
app/Console/Commands/InitCourseCommand.php

@@ -203,8 +203,8 @@ class InitCourseCommand extends Command
         foreach ($data['Videos'] as $k => $v) {
             $sort = $t - $k;
             $this->line("{$v['name']}==>{$sort}");
-            $aa = Video::query()->whereIn('course_id', $courses)->where('title', $v['name'])->get();
-            dd($aa);
+            Video::query()->whereIn('course_id', $courses)->where('title', $v['name'])->update(['sort' => $sort]);
+//            dd($aa);
         }
 //        }