1
0
mirror of synced 2024-12-15 07:36:03 +03:00
doctrine2/tests/Doctrine/Tests/Models/CMS/CmsPhonenumber.php

27 lines
523 B
PHP

<?php
namespace Doctrine\Tests\Models\CMS;
/**
* @DoctrineEntity
* @DoctrineTable(name="cms_phonenumbers")
*/
class CmsPhonenumber
{
/**
* @DoctrineColumn(type="varchar", length=50)
* @DoctrineId
*/
public $phonenumber;
/**
* @DoctrineManyToOne(targetEntity="CmsUser")
* @DoctrineJoinColumn(name="user_id", referencedColumnName="id")
*/
public $user;
public function setUser(CmsUser $user) {
$this->user = $user;
$user->addPhonenumber($this);
}
}