diff --git a/app/Event.php b/app/Event.php index 1c7748fd..c2d52808 100644 --- a/app/Event.php +++ b/app/Event.php @@ -94,8 +94,18 @@ class Event extends Model return $c; } } - - return false; + $error = new \App\Course(); + $error->name = "Cours manquant dans la BD"; + $error->ocom = "ERROR"; + $error->periode = $p; + $error->level = $l; + $error->location = ""; + $error->desc = ""; + $error->comment = "Le cours est manquant dans la base de données"; + $error->comment_officier = "Le cours est manquant dans la base de données"; + $error->event_id = $this->id; + $error->user_id = 1; + return $error; } public function logs()