<?php

/**
 * BaseReportGroup
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $reportGroupId
 * @property string $name
 * @property clob $core_sql
 * @property Doctrine_Collection $Report
 * @property Doctrine_Collection $FilterField
 * @property Doctrine_Collection $AbstractDisplayField
 * @property Doctrine_Collection $AvailableGroupField
 * @property Doctrine_Collection $DisplayFieldGroup
 * 
 * @method integer             getReportGroupId()        Returns the current record's "reportGroupId" value
 * @method string              getName()                 Returns the current record's "name" value
 * @method clob                getCoreSql()              Returns the current record's "core_sql" value
 * @method Doctrine_Collection getReport()               Returns the current record's "Report" collection
 * @method Doctrine_Collection getFilterField()          Returns the current record's "FilterField" collection
 * @method Doctrine_Collection getAbstractDisplayField() Returns the current record's "AbstractDisplayField" collection
 * @method Doctrine_Collection getAvailableGroupField()  Returns the current record's "AvailableGroupField" collection
 * @method Doctrine_Collection getDisplayFieldGroup()    Returns the current record's "DisplayFieldGroup" collection
 * @method ReportGroup         setReportGroupId()        Sets the current record's "reportGroupId" value
 * @method ReportGroup         setName()                 Sets the current record's "name" value
 * @method ReportGroup         setCoreSql()              Sets the current record's "core_sql" value
 * @method ReportGroup         setReport()               Sets the current record's "Report" collection
 * @method ReportGroup         setFilterField()          Sets the current record's "FilterField" collection
 * @method ReportGroup         setAbstractDisplayField() Sets the current record's "AbstractDisplayField" collection
 * @method ReportGroup         setAvailableGroupField()  Sets the current record's "AvailableGroupField" collection
 * @method ReportGroup         setDisplayFieldGroup()    Sets the current record's "DisplayFieldGroup" collection
 * 
 * @package    orangehrm
 * @subpackage model\core\base
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7490 2010-03-29 19:53:27Z jwage $
 */
abstract class BaseReportGroup extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('ohrm_report_group');
        $this->hasColumn('report_group_id as reportGroupId', 'integer', null, array(
             'type' => 'integer',
             'primary' => true,
             ));
        $this->hasColumn('name', 'string', 255, array(
             'type' => 'string',
             'notnull' => true,
             'length' => 255,
             ));
        $this->hasColumn('core_sql', 'clob', null, array(
             'type' => 'clob',
             'notnull' => true,
             ));
    }

    public function setUp()
    {
        parent::setUp();
        $this->hasMany('Report', array(
             'local' => 'reportGroupId',
             'foreign' => 'reportGroupId'));

        $this->hasMany('FilterField', array(
             'local' => 'reportGroupId',
             'foreign' => 'report_group_id'));

        $this->hasMany('AbstractDisplayField', array(
             'local' => 'reportGroupId',
             'foreign' => 'report_group_id'));

        $this->hasMany('AvailableGroupField', array(
             'local' => 'reportGroupId',
             'foreign' => 'report_group_id'));

        $this->hasMany('DisplayFieldGroup', array(
             'local' => 'reportGroupId',
             'foreign' => 'report_group_id'));
    }
}