1
0
mirror of synced 2024-12-13 22:56:04 +03:00
doctrine2/models/Forum_Board.php

14 lines
460 B
PHP
Raw Normal View History

<?php
class Forum_Board extends Doctrine_Record {
public function setTableDefinition() {
$this->hasColumn('category_id', 'integer', 10);
$this->hasColumn('name', 'string', 100);
$this->hasColumn('description', 'string', 5000);
}
public function setUp() {
$this->hasOne('Forum_Category as Category', 'Forum_Board.category_id');
$this->ownsMany('Forum_Thread as Threads', 'Forum_Thread.board_id');
}
}