Silent 6 gadi atpakaļ
vecāks
revīzija
dd909cd067
1 mainītis faili ar 2 papildinājumiem un 5 dzēšanām
  1. 2 5
      app/Models/Student.php

+ 2 - 5
app/Models/Student.php

xqd
@@ -110,14 +110,11 @@ class Student extends Model
         }
         $this_week_begin = $today->toDateTimeString();
         $this_week_end = $today->addDays(7)->toDateTimeString();
-        Log::info($this_week_begin);
-        Log::info($this_week_end);
         $tmp = Remark::where([
             ['student_id', '=', $this['id']],
-            ['created_at', '>=', $this_week_begin],
-            ['created_at', '<', $this_week_end],
+            ['updated_at', '>=', $this_week_begin],
+            ['updated_at', '<', $this_week_end],
         ])->first();
-        Log::info($tmp);
         return empty($tmp) ? true : false;
     }