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

/**
 * BaseCOM_REINTEGRO
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id_reintegro
 * @property integer $id_pago_egreso
 * @property integer $id_anhos
 * @property timestamp $fecha_reintegro
 * @property integer $valor_total
 * @property integer $estado
 * @property timestamp $fecha_anulacion
 * @property string $motivo_anulacion
 * @property string $observaciones
 * @property COM_PAGO_EGRESO $COM_PAGO_EGRESO
 * @property Doctrine_Collection $COM_DETA_REINTEGRO
 * 
 * @method integer             getIdReintegro()        Returns the current record's "id_reintegro" value
 * @method integer             getIdPagoEgreso()       Returns the current record's "id_pago_egreso" value
 * @method integer             getIdAnhos()            Returns the current record's "id_anhos" value
 * @method timestamp           getFechaReintegro()     Returns the current record's "fecha_reintegro" value
 * @method integer             getValorTotal()         Returns the current record's "valor_total" value
 * @method integer             getEstado()             Returns the current record's "estado" value
 * @method timestamp           getFechaAnulacion()     Returns the current record's "fecha_anulacion" value
 * @method string              getMotivoAnulacion()    Returns the current record's "motivo_anulacion" value
 * @method string              getObservaciones()      Returns the current record's "observaciones" value
 * @method COM_PAGO_EGRESO     getCOMPAGOEGRESO()      Returns the current record's "COM_PAGO_EGRESO" value
 * @method Doctrine_Collection getCOMDETAREINTEGRO()   Returns the current record's "COM_DETA_REINTEGRO" collection
 * @method COM_REINTEGRO       setIdReintegro()        Sets the current record's "id_reintegro" value
 * @method COM_REINTEGRO       setIdPagoEgreso()       Sets the current record's "id_pago_egreso" value
 * @method COM_REINTEGRO       setIdAnhos()            Sets the current record's "id_anhos" value
 * @method COM_REINTEGRO       setFechaReintegro()     Sets the current record's "fecha_reintegro" value
 * @method COM_REINTEGRO       setValorTotal()         Sets the current record's "valor_total" value
 * @method COM_REINTEGRO       setEstado()             Sets the current record's "estado" value
 * @method COM_REINTEGRO       setFechaAnulacion()     Sets the current record's "fecha_anulacion" value
 * @method COM_REINTEGRO       setMotivoAnulacion()    Sets the current record's "motivo_anulacion" value
 * @method COM_REINTEGRO       setObservaciones()      Sets the current record's "observaciones" value
 * @method COM_REINTEGRO       setCOMPAGOEGRESO()      Sets the current record's "COM_PAGO_EGRESO" value
 * @method COM_REINTEGRO       setCOMDETAREINTEGRO()   Sets the current record's "COM_DETA_REINTEGRO" collection
 * 
 * @package    controlComisiones
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7691 2011-02-04 15:43:29Z jwage $
 */
abstract class BaseCOM_REINTEGRO extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('COM_REINTEGRO');
        $this->hasColumn('id_reintegro', 'integer', 20, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 20,
             ));
        $this->hasColumn('id_pago_egreso', 'integer', 20, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('id_anhos', 'integer', 20, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('fecha_reintegro', 'timestamp', 7, array(
             'notnull' => true,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('valor_total', 'integer', 20, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('estado', 'integer', 1, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '1 ',
             'primary' => false,
             'length' => 1,
             ));
        $this->hasColumn('fecha_anulacion', 'timestamp', 7, array(
             'notnull' => false,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('motivo_anulacion', 'string', 500, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 500,
             ));
        $this->hasColumn('observaciones', 'string', 500, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 500,
             ));
        $this->hasColumn('doc_siif', 'string', 20, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('id_td', 'integer', 20, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        
    }

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

        $this->hasMany('COM_DETA_REINTEGRO', array(
             'local' => 'id_reintegro',
             'foreign' => 'id_reintegro'));
    }
}