1
0
mirror of synced 2024-12-13 14:56:01 +03:00
doctrine2/tests_old/models/Forum_Thread.php

12 lines
491 B
PHP
Raw Normal View History

<?php
class Forum_Thread extends Doctrine_Entity {
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'));
}
}