1
0
mirror of synced 2025-01-19 15:01:40 +03:00

11 lines
339 B
PHP

<?php
class Rec2 extends Doctrine_Entity
{
public static function initMetadata($class)
{
$class->setColumn('user_id', 'integer', 10, array ( 'unique' => true,));
$class->setColumn('address', 'string', 150, array ());
$class->hasOne('Rec1 as User', array('local' => 'user_id', 'foreign' => 'id'));
}
}