Team and team members
Usually, projects consist of several tasks and cannot be done by a single person. So, we need to introduce the concept of team and define relationships between Team, User, and Project entities in our application. The simplest definition for the Team entity could be: all the people who work on the same project. This means that we need to modify our current User entity and add a new property that defines the relationship between Team and User.
The Team entity
The following image shows the relationship between Team, Project, and User entities. To keep it simple, let's say that each User can be a member of one Team only and there is only one team for each project:
With the MVP approach in mind and considering the preceding image, the Team entity can be defined as follows:
<?php class Team { /** * @var integer * @ORM\Column(name="id", type="integer") * @ORM\Id * @ORM\GeneratedValue(strategy="AUTO") */ private $id; /** * @var string...