<?php

/**
 * BaseEmployeeStatus
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property string $id
 * @property string $name
 * @property Doctrine_Collection $employees
 * @property Doctrine_Collection $JobTitleEmployeeStatus
 * 
 * @method string              getId()                     Returns the current record's "id" value
 * @method string              getName()                   Returns the current record's "name" value
 * @method Doctrine_Collection getEmployees()              Returns the current record's "employees" collection
 * @method Doctrine_Collection getJobTitleEmployeeStatus() Returns the current record's "JobTitleEmployeeStatus" collection
 * @method EmployeeStatus      setId()                     Sets the current record's "id" value
 * @method EmployeeStatus      setName()                   Sets the current record's "name" value
 * @method EmployeeStatus      setEmployees()              Sets the current record's "employees" collection
 * @method EmployeeStatus      setJobTitleEmployeeStatus() Sets the current record's "JobTitleEmployeeStatus" collection
 * 
 * @package    orangehrm
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7490 2010-03-29 19:53:27Z jwage $
 */
abstract class BaseEmployeeStatus extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('hs_hr_empstat');
        $this->hasColumn('estat_code as id', 'string', 13, array(
             'type' => 'string',
             'primary' => true,
             'length' => 13,
             ));
        $this->hasColumn('estat_name as name', 'string', 50, array(
             'type' => 'string',
             'length' => 50,
             ));
    }

    public function setUp()
    {
        parent::setUp();
        $this->hasMany('Employee as employees', array(
             'local' => 'estat_code',
             'foreign' => 'emp_status'));

        $this->hasMany('JobTitleEmployeeStatus', array(
             'local' => 'id',
             'foreign' => 'estat_code'));
    }
}