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

26 lines
510 B
PHP

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