Hello, I have a problem when designing my models related to users and their relationships. In my application, I have three types of users: Admin, Manager and team of competitors. The models that I have thought to create so far are:
It should be mentioned that the attribute "competition_id" in the user table refers to a team of competitors participating in a certain competition, a manager can configure a single competition and an administrator can configure all competitions (set to null for admin) .
My problem arises when I want to relate these models to each other, where I have read that it can be done with polymorphic relationships, but I am not sure about it. I would appreciate any help regarding a new way of designing these models and their relationships or how to design relationships between these models.
Thank you very much for your time.
Did you know that, in addition to the forum, Laracasts includes well over 1000 lessons on modern web development? All for the price of one lunch out per month.