<?php
// Connection Component Binding
Doctrine_Manager::getInstance()->bindComponent('RH_SA_HIS', 'doctrine');

/**
 * BaseRH_SA_HIS
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id_sa_his
 * @property string $num_doc
 * @property integer $id_tipo_doc
 * @property timestamp $fecha_i
 * @property timestamp $fecha_f
 * @property timestamp $fecha_registro
 * @property integer $id_dp
 * @property integer $id_sa_niv2
 * @property RH_SA_NIV2 $RH_SA_NIV2
 * 
 * @method integer    getIdSaHis()        Returns the current record's "id_sa_his" value
 * @method string     getNumDoc()         Returns the current record's "num_doc" value
 * @method integer    getIdTipoDoc()      Returns the current record's "id_tipo_doc" value
 * @method timestamp  getFechaI()         Returns the current record's "fecha_i" value
 * @method timestamp  getFechaF()         Returns the current record's "fecha_f" value
 * @method timestamp  getFechaRegistro()  Returns the current record's "fecha_registro" value
 * @method integer    getIdDp()           Returns the current record's "id_dp" value
 * @method integer    getIdSaNiv2()       Returns the current record's "id_sa_niv2" value
 * @method RH_SA_NIV2 getRHSANIV2()       Returns the current record's "RH_SA_NIV2" value
 * @method RH_SA_HIS  setIdSaHis()        Sets the current record's "id_sa_his" value
 * @method RH_SA_HIS  setNumDoc()         Sets the current record's "num_doc" value
 * @method RH_SA_HIS  setIdTipoDoc()      Sets the current record's "id_tipo_doc" value
 * @method RH_SA_HIS  setFechaI()         Sets the current record's "fecha_i" value
 * @method RH_SA_HIS  setFechaF()         Sets the current record's "fecha_f" value
 * @method RH_SA_HIS  setFechaRegistro()  Sets the current record's "fecha_registro" value
 * @method RH_SA_HIS  setIdDp()           Sets the current record's "id_dp" value
 * @method RH_SA_HIS  setIdSaNiv2()       Sets the current record's "id_sa_niv2" value
 * @method RH_SA_HIS  setRHSANIV2()       Sets the current record's "RH_SA_NIV2" value
 * 
 * @package    cartera
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7691 2011-02-04 15:43:29Z jwage $
 */
abstract class BaseRH_SA_HIS extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('RH_SA_HIS');
        $this->hasColumn('id_sa_his', 'integer', 20, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 20,
             ));
        $this->hasColumn('num_doc', 'string', 20, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('id_tipo_doc', 'integer', 20, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('fecha_i', 'timestamp', 7, array(
             'notnull' => false,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('fecha_f', 'timestamp', 7, array(
             'notnull' => false,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('fecha_registro', 'timestamp', 7, array(
             'notnull' => false,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('id_dp', 'integer', 20, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('id_sa_niv2', 'integer', 20, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
    }

    public function setUp()
    {
        parent::setUp();
        $this->hasOne('RH_SA_NIV2', array(
             'local' => 'id_sa_niv2',
             'foreign' => 'id_sa_niv2'));
    }
}