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

/**
 * BaseRH_SA_NIV1
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id_sa_niv1
 * @property string $descripcion
 * @property integer $codigo
 * @property Doctrine_Collection $RH_SA_NIV2
 * 
 * @method integer             getIdSaNiv1()    Returns the current record's "id_sa_niv1" value
 * @method string              getDescripcion() Returns the current record's "descripcion" value
 * @method integer             getCodigo()      Returns the current record's "codigo" value
 * @method Doctrine_Collection getRHSANIV2()    Returns the current record's "RH_SA_NIV2" collection
 * @method RH_SA_NIV1          setIdSaNiv1()    Sets the current record's "id_sa_niv1" value
 * @method RH_SA_NIV1          setDescripcion() Sets the current record's "descripcion" value
 * @method RH_SA_NIV1          setCodigo()      Sets the current record's "codigo" value
 * @method RH_SA_NIV1          setRHSANIV2()    Sets the current record's "RH_SA_NIV2" collection
 * 
 * @package    nomina
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7691 2011-02-04 15:43:29Z jwage $
 */
abstract class BaseRH_SA_NIV1 extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('RH_SA_NIV1');
        $this->hasColumn('id_sa_niv1', 'integer', 20, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 20,
             ));
        $this->hasColumn('descripcion', 'string', 100, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 100,
             ));
        $this->hasColumn('codigo', 'integer', 20, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
    }

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