hasMany(QuizAttemptAnswers::class, 'question_id'); } public function quiz() { return $this->belongsTo(Quizzes::class, "quiz_id", "id"); } }