2007-09-02 18:24:49 +04:00
|
|
|
<?php
|
|
|
|
class QueryTest_Entry extends Doctrine_Record
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* Table structure.
|
|
|
|
*/
|
|
|
|
public function setTableDefinition()
|
|
|
|
{
|
|
|
|
$this->hasColumn('authorId', 'integer', 4,
|
|
|
|
array('notnull'));
|
|
|
|
$this->hasColumn('date', 'integer', 4,
|
|
|
|
array('notnull'));
|
|
|
|
}
|
2007-10-21 10:23:59 +04:00
|
|
|
|
2007-09-02 18:24:49 +04:00
|
|
|
/**
|
|
|
|
* Runtime definition of the relationships to other entities.
|
|
|
|
*/
|
|
|
|
public function setUp()
|
|
|
|
{
|
|
|
|
$this->hasOne('QueryTest_User as author', 'QueryTest_Entry.authorId');
|
|
|
|
}
|
|
|
|
}
|