We now support @Id on @ManyToOne fields. Removed TODO and associated code.
This commit is contained in:
parent
f4d62b317e
commit
2a7364bb18
@ -44,17 +44,12 @@ class DDC192Phonenumber
|
|||||||
*/
|
*/
|
||||||
protected $phone;
|
protected $phone;
|
||||||
|
|
||||||
/**
|
|
||||||
* @Id @Column(name="userId", type="integer")
|
|
||||||
*/
|
|
||||||
protected $userId;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Id
|
* @Id
|
||||||
* @ManyToOne(targetEntity="DDC192User")
|
* @ManyToOne(targetEntity="DDC192User")
|
||||||
* @JoinColumn(name="userId", referencedColumnName="id")
|
* @JoinColumn(name="userId", referencedColumnName="id")
|
||||||
*/
|
*/
|
||||||
protected $User; // Id on this docblock is ignored!
|
protected $User;
|
||||||
|
|
||||||
|
|
||||||
public function setPhone($value) { $this->phone = $value; }
|
public function setPhone($value) { $this->phone = $value; }
|
||||||
@ -64,7 +59,6 @@ class DDC192Phonenumber
|
|||||||
public function setUser(User $user)
|
public function setUser(User $user)
|
||||||
{
|
{
|
||||||
$this->User = $user;
|
$this->User = $user;
|
||||||
$this->userId = $user->getId(); // TODO: Remove once ManyToOne supports Id annotation
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getUser() { return $this->User; }
|
public function getUser() { return $this->User; }
|
||||||
|
Loading…
Reference in New Issue
Block a user