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

/**
 * BaseAREA
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id_area
 * @property string $descripcion
 * @property string $sigla
 * @property integer $id_dependencia
 * @property string $codigo
 * @property integer $id_nivel
 * @property NIVEL_ORGANIZACIONAL $NIVEL_ORGANIZACIONAL
 * @property Doctrine_Collection $RH_SA_SL
 * @property Doctrine_Collection $RH_SA_NOMBRAMIENTO
 * @property Doctrine_Collection $RH_NP_LEY_AREA
 * @property Doctrine_Collection $RH_EN_REGISTRO_ENCUESTA
 * @property Doctrine_Collection $RH_DP
 * @property Doctrine_Collection $RH_AP_DEN_EMP
 * @property Doctrine_Collection $NECESIDAD
 * @property Doctrine_Collection $IN_SOLI_COMPRA
 * @property Doctrine_Collection $DATOS_FUNCIONARIO
 * @property Doctrine_Collection $AREA_INVITADA
 * 
 * @method integer              getIdArea()                  Returns the current record's "id_area" value
 * @method string               getDescripcion()             Returns the current record's "descripcion" value
 * @method string               getSigla()                   Returns the current record's "sigla" value
 * @method integer              getIdDependencia()           Returns the current record's "id_dependencia" value
 * @method string               getCodigo()                  Returns the current record's "codigo" value
 * @method integer              getIdNivel()                 Returns the current record's "id_nivel" value
 * @method NIVEL_ORGANIZACIONAL getNIVELORGANIZACIONAL()     Returns the current record's "NIVEL_ORGANIZACIONAL" value
 * @method Doctrine_Collection  getRHSASL()                  Returns the current record's "RH_SA_SL" collection
 * @method Doctrine_Collection  getRHSANOMBRAMIENTO()        Returns the current record's "RH_SA_NOMBRAMIENTO" collection
 * @method Doctrine_Collection  getRHNPLEYAREA()             Returns the current record's "RH_NP_LEY_AREA" collection
 * @method Doctrine_Collection  getRHENREGISTROENCUESTA()    Returns the current record's "RH_EN_REGISTRO_ENCUESTA" collection
 * @method Doctrine_Collection  getRHDP()                    Returns the current record's "RH_DP" collection
 * @method Doctrine_Collection  getRHAPDENEMP()              Returns the current record's "RH_AP_DEN_EMP" collection
 * @method Doctrine_Collection  getNECESIDAD()               Returns the current record's "NECESIDAD" collection
 * @method Doctrine_Collection  getINSOLICOMPRA()            Returns the current record's "IN_SOLI_COMPRA" collection
 * @method Doctrine_Collection  getDATOSFUNCIONARIO()        Returns the current record's "DATOS_FUNCIONARIO" collection
 * @method Doctrine_Collection  getAREAINVITADA()            Returns the current record's "AREA_INVITADA" collection
 * @method AREA                 setIdArea()                  Sets the current record's "id_area" value
 * @method AREA                 setDescripcion()             Sets the current record's "descripcion" value
 * @method AREA                 setSigla()                   Sets the current record's "sigla" value
 * @method AREA                 setIdDependencia()           Sets the current record's "id_dependencia" value
 * @method AREA                 setCodigo()                  Sets the current record's "codigo" value
 * @method AREA                 setIdNivel()                 Sets the current record's "id_nivel" value
 * @method AREA                 setNIVELORGANIZACIONAL()     Sets the current record's "NIVEL_ORGANIZACIONAL" value
 * @method AREA                 setRHSASL()                  Sets the current record's "RH_SA_SL" collection
 * @method AREA                 setRHSANOMBRAMIENTO()        Sets the current record's "RH_SA_NOMBRAMIENTO" collection
 * @method AREA                 setRHNPLEYAREA()             Sets the current record's "RH_NP_LEY_AREA" collection
 * @method AREA                 setRHENREGISTROENCUESTA()    Sets the current record's "RH_EN_REGISTRO_ENCUESTA" collection
 * @method AREA                 setRHDP()                    Sets the current record's "RH_DP" collection
 * @method AREA                 setRHAPDENEMP()              Sets the current record's "RH_AP_DEN_EMP" collection
 * @method AREA                 setNECESIDAD()               Sets the current record's "NECESIDAD" collection
 * @method AREA                 setINSOLICOMPRA()            Sets the current record's "IN_SOLI_COMPRA" collection
 * @method AREA                 setDATOSFUNCIONARIO()        Sets the current record's "DATOS_FUNCIONARIO" collection
 * @method AREA                 setAREAINVITADA()            Sets the current record's "AREA_INVITADA" collection
 * 
 * @package    nomina
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7691 2011-02-04 15:43:29Z jwage $
 */
abstract class BaseAREA extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('AREA');
        $this->hasColumn('id_area', 'integer', 20, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 20,
             ));
        $this->hasColumn('descripcion', 'string', 1000, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 1000,
             ));
        $this->hasColumn('sigla', 'string', 100, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 100,
             ));
        $this->hasColumn('id_dependencia', 'integer', 20, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('codigo', 'string', 100, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 100,
             ));
        $this->hasColumn('id_nivel', 'integer', 8, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 8,
             ));
    }

    public function setUp()
    {
        parent::setUp();
        $this->hasOne('NIVEL_ORGANIZACIONAL', array(
             'local' => 'id_nivel',
             'foreign' => 'id_niv_org'));

        $this->hasMany('RH_SA_SL', array(
             'local' => 'id_area',
             'foreign' => 'id_area'));

        $this->hasMany('RH_SA_NOMBRAMIENTO', array(
             'local' => 'id_area',
             'foreign' => 'id_area'));

        $this->hasMany('RH_NP_LEY_AREA', array(
             'local' => 'id_area',
             'foreign' => 'id_area'));

        $this->hasMany('RH_EN_REGISTRO_ENCUESTA', array(
             'local' => 'id_area',
             'foreign' => 'id_area'));

        $this->hasMany('RH_DP', array(
             'local' => 'id_area',
             'foreign' => 'id_ea'));

        $this->hasMany('RH_AP_DEN_EMP', array(
             'local' => 'id_area',
             'foreign' => 'id_area'));

        $this->hasMany('NECESIDAD', array(
             'local' => 'id_area',
             'foreign' => 'id_area'));

        $this->hasMany('IN_SOLI_COMPRA', array(
             'local' => 'id_area',
             'foreign' => 'id_area'));

        $this->hasMany('DATOS_FUNCIONARIO', array(
             'local' => 'id_area',
             'foreign' => 'id_area'));

        $this->hasMany('AREA_INVITADA', array(
             'local' => 'id_area',
             'foreign' => 'id_area'));
    }
}