Now that user can take quizzes we need to save results in the DB which we will do in this tutorial.
For this we will need two Eloquent Models:
-
Testwhere we will save information about user, which test (another word for "quiz" but it's broader) he took, how much time it took him. -
TestAnswerwhere we will store the information about which answers user chose during the quiz.