mead 2 månader sedan
förälder
incheckning
c4ab7bb001
1 ändrade filer med 2 tillägg och 1 borttagningar
  1. 2 1
      app/Console/Commands/InitCourseCommand.php

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

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