Sto tentando di aggiungere Doctrine su un database esistente. Lascia che Doctrine generi entità annotate e aggiustato da lì. Quando provo a caricare l'entità sotto ho l'errore PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Property Users\\User::$resellerID does not exist'
La proprietà Doctrine ReflectionException non esiste
class User
{
/* ... */
/**
* @var \Doctrine\Common\Collections\Collection
*
* @ORM\ManyToOne(targetEntity="\Resellers\Reseller")
* @ORM\JoinTable(name="reseller",
* joinColumns={
* @ORM\JoinColumn(name="resellerID", referencedColumnName="resellerID")
* },
* inverseJoinColumns={
* @ORM\JoinColumn(name="resellerID", referencedColumnName="resellerID")
* }
*)
*/
private $reseller;
/* ... */
}
Sia i user
e reseller
tabelle hanno resellerID
colonne. La mia comprensione è che per unire le colonne ID non si aggiungono le colonne ID come proprietà nella classe entità. Quindi, qual è la causa del ReflectionException?
Svuotare la cache è la prima cosa che faccio ogni volta che ho un errore in Symfony ... – user276648