Fail to attach questions to quiz.
quiz_questions is a pivot table where it stores quiz_id and question_id. right now i have a QuestionRelationManager under the Quiz resource.
Quiz.php
Question.php
QuizQuestion.php
QuestionsRelationManager.php
It does shows the questions, however i cant attach it. The error is
5 Replies
Not related to your question but relation name should be camel case. quizQuestions
thank you. in your opinion do you think the error comes from the relationship naming?
it's possible
Does this setup work without Filament? I don’t think so. Is there more data attached to
QuizQuestion
. Also this seems to be a full model and not a pivot model.
I think you need a BelongsToMany
in both directions without that model in between .thanks sir, ill try