1
0
mirror of synced 2024-12-14 23:26:04 +03:00
doctrine2/tests_old/models/Forum_Thread.php
2008-02-08 17:41:01 +00:00

12 lines
491 B
PHP

<?php
class Forum_Thread extends Doctrine_Record {
public static function initMetadata($class) {
$class->setColumn('board_id', 'integer', 10);
$class->setColumn('updated', 'integer', 10);
$class->setColumn('closed', 'integer', 1);
$class->hasOne('Forum_Board as Board', array('local' => 'board_id', 'foreign' => 'id', 'onDelete' => 'CASCADE'));
$class->hasMany('Forum_Entry as Entries', array('local' => 'id', 'foreign' => 'thread_id'));
}
}