I'm trying to map a Milestones to a Project but when I try to reference the relation it's always returning null.
The database looks perfect, the targetEntity paths are correct and the scheme is validating by using
doctrine:scheme:validate project.php
/** * @ORM\OneToMany(targetEntity="Planning\Readmodel\Project\Milestone\Milestone", mappedBy="project", cascade={"persist", "remove"}) */ private $milestones; milestone.php
/** * @ORM\ManyToOne(targetEntity="Planning\Readmodel\Project\Project", inversedBy="milestones", cascade={"persist", "remove"}) * @ORM\JoinColumn(name="projectId", referencedColumnName="projectId") */ private $project; But when I try to get the milestone I get null using:
$this->milestones; Any idea what I might be doing wrong? Thank you.