<?php

/**
 * BaseBoard
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property string $name
 * @property integer $first_row
 * @property Doctrine_Collection $Seats
 * 
 * @method string              getName()      Returns the current record's "name" value
 * @method integer             getFirstRow()  Returns the current record's "first_row" value
 * @method Doctrine_Collection getSeats()     Returns the current record's "Seats" collection
 * @method Board               setName()      Sets the current record's "name" value
 * @method Board               setFirstRow()  Sets the current record's "first_row" value
 * @method Board               setSeats()     Sets the current record's "Seats" collection
 * 
 * @package    balsit
 * @subpackage model
 * @author     Krzysiek Wesołowski
 * @version    SVN: $Id: Builder.php 6820 2009-11-30 17:27:49Z jwage $
 */
abstract class BaseBoard extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('board');
        $this->hasColumn('name', 'string', 30, array(
             'type' => 'string',
             'notnull' => true,
             'length' => '30',
             ));
        $this->hasColumn('first_row', 'integer', 4, array(
             'type' => 'integer',
             'notnull' => false,
             'length' => '4',
             ));

        $this->option('type', 'INNODB');
        $this->option('collate', 'utf8_general_ci');
        $this->option('charset', 'utf8');
    }

    public function setUp()
    {
        parent::setUp();
        $this->hasMany('Seat as Seats', array(
             'local' => 'id',
             'foreign' => 'board_id'));
    }
}