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

/**
 * BaseCACO_CONTRATO
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id_contrato
 * @property integer $id_tipo_contrato
 * @property string $descripcion
 * @property string $codigo
 * @property integer $id_anhos
 * @property timestamp $fecha_proceso
 * @property timestamp $fecha_inicial
 * @property timestamp $fecha_termina
 * @property integer $valor_compania
 * @property integer $valor_entidad
 * @property integer $valor_contrato
 * @property integer $aplica_salvedad
 * @property integer $estado
 * @property timestamp $fecha_log
 * @property string $usuario_log
 * @property timestamp $fecha_anu
 * @property string $motivo_anu
 * @property string $usuario_anu
 * @property integer $id_supervisor_cont
 * @property CACO_TIPO_CONTRATO $CACO_TIPO_CONTRATO
 * @property ANHOS $ANHOS
 * @property CACO_SUPERVISOR_CONT $CACO_SUPERVISOR_CONT
 * @property Doctrine_Collection $CACO_NOVEDAD_DESEMBOLSO
 * @property Doctrine_Collection $CACO_NOVEDAD_CONTRATO
 * @property Doctrine_Collection $CACO_MODIFICA_SUPERVISOR
 * @property Doctrine_Collection $CACO_CONTRATO_ENTIDAD
 * @property Doctrine_Collection $CACO_ALERTA_CONTRATO
 * 
 * @method integer              getIdContrato()               Returns the current record's "id_contrato" value
 * @method integer              getIdTipoContrato()           Returns the current record's "id_tipo_contrato" value
 * @method string               getDescripcion()              Returns the current record's "descripcion" value
 * @method string               getCodigo()                   Returns the current record's "codigo" value
 * @method integer              getIdAnhos()                  Returns the current record's "id_anhos" value
 * @method timestamp            getFechaProceso()             Returns the current record's "fecha_proceso" value
 * @method timestamp            getFechaInicial()             Returns the current record's "fecha_inicial" value
 * @method timestamp            getFechaTermina()             Returns the current record's "fecha_termina" value
 * @method integer              getValorCompa()               Returns the current record's "valor_compa" value
 * @method integer              getValorEntidad()             Returns the current record's "valor_entidad" value
 * @method integer              getValorContrato()            Returns the current record's "valor_contrato" value
 * @method integer              getAplicaSalvedad()           Returns the current record's "aplica_salvedad" value
 * @method integer              getEstado()                   Returns the current record's "estado" value
 * @method timestamp            getFechaLog()                 Returns the current record's "fecha_log" value
 * @method string               getUsuarioLog()               Returns the current record's "usuario_log" value
 * @method timestamp            getFechaAnu()                 Returns the current record's "fecha_anu" value
 * @method string               getMotivoAnu()                Returns the current record's "motivo_anu" value
 * @method string               getUsuarioAnu()               Returns the current record's "usuario_anu" value
 * @method integer              getIdSupervisorCont()         Returns the current record's "id_supervisor_cont" value
 * @method CACO_TIPO_CONTRATO   getCACOTIPOCONTRATO()         Returns the current record's "CACO_TIPO_CONTRATO" value
 * @method ANHOS                getANHOS()                    Returns the current record's "ANHOS" value
 * @method CACO_SUPERVISOR_CONT getCACOSUPERVISORCONT()       Returns the current record's "CACO_SUPERVISOR_CONT" value
 * @method Doctrine_Collection  getCACONOVEDADDESEMBOLSO()    Returns the current record's "CACO_NOVEDAD_DESEMBOLSO" collection
 * @method Doctrine_Collection  getCACONOVEDADCONTRATO()      Returns the current record's "CACO_NOVEDAD_CONTRATO" collection
 * @method Doctrine_Collection  getCACOMODIFICASUPERVISOR()   Returns the current record's "CACO_MODIFICA_SUPERVISOR" collection
 * @method Doctrine_Collection  getCACOCONTRATOENTIDAD()      Returns the current record's "CACO_CONTRATO_ENTIDAD" collection
 * @method Doctrine_Collection  getCACOALERTACONTRATO()       Returns the current record's "CACO_ALERTA_CONTRATO" collection
 * @method CACO_CONTRATO        setIdContrato()               Sets the current record's "id_contrato" value
 * @method CACO_CONTRATO        setIdTipoContrato()           Sets the current record's "id_tipo_contrato" value
 * @method CACO_CONTRATO        setDescripcion()              Sets the current record's "descripcion" value
 * @method CACO_CONTRATO        setCodigo()                   Sets the current record's "codigo" value
 * @method CACO_CONTRATO        setIdAnhos()                  Sets the current record's "id_anhos" value
 * @method CACO_CONTRATO        setFechaProceso()             Sets the current record's "fecha_proceso" value
 * @method CACO_CONTRATO        setFechaInicial()             Sets the current record's "fecha_inicial" value
 * @method CACO_CONTRATO        setFechaTermina()             Sets the current record's "fecha_termina" value
 * @method CACO_CONTRATO        setValorCompa()               Sets the current record's "valor_compa" value
 * @method CACO_CONTRATO        setValorEntidad()             Sets the current record's "valor_entidad" value
 * @method CACO_CONTRATO        setValorContrato()            Sets the current record's "valor_contrato" value
 * @method CACO_CONTRATO        setAplicaSalvedad()           Sets the current record's "aplica_salvedad" value
 * @method CACO_CONTRATO        setEstado()                   Sets the current record's "estado" value
 * @method CACO_CONTRATO        setFechaLog()                 Sets the current record's "fecha_log" value
 * @method CACO_CONTRATO        setUsuarioLog()               Sets the current record's "usuario_log" value
 * @method CACO_CONTRATO        setFechaAnu()                 Sets the current record's "fecha_anu" value
 * @method CACO_CONTRATO        setMotivoAnu()                Sets the current record's "motivo_anu" value
 * @method CACO_CONTRATO        setUsuarioAnu()               Sets the current record's "usuario_anu" value
 * @method CACO_CONTRATO        setIdSupervisorCont()         Sets the current record's "id_supervisor_cont" value
 * @method CACO_CONTRATO        setCACOTIPOCONTRATO()         Sets the current record's "CACO_TIPO_CONTRATO" value
 * @method CACO_CONTRATO        setANHOS()                    Sets the current record's "ANHOS" value
 * @method CACO_CONTRATO        setCACOSUPERVISORCONT()       Sets the current record's "CACO_SUPERVISOR_CONT" value
 * @method CACO_CONTRATO        setCACONOVEDADDESEMBOLSO()    Sets the current record's "CACO_NOVEDAD_DESEMBOLSO" collection
 * @method CACO_CONTRATO        setCACONOVEDADCONTRATO()      Sets the current record's "CACO_NOVEDAD_CONTRATO" collection
 * @method CACO_CONTRATO        setCACOMODIFICASUPERVISOR()   Sets the current record's "CACO_MODIFICA_SUPERVISOR" collection
 * @method CACO_CONTRATO        setCACOCONTRATOENTIDAD()      Sets the current record's "CACO_CONTRATO_ENTIDAD" collection
 * @method CACO_CONTRATO        setCACOALERTACONTRATO()       Sets the current record's "CACO_ALERTA_CONTRATO" collection
 * 
 * @package    ProyectoSchema
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7490 2010-03-29 19:53:27Z jwage $
 */
abstract class BaseCACO_CONTRATO extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('CACO_CONTRATO');
        $this->hasColumn('id_contrato', 'integer', 8, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 8,
             ));
        $this->hasColumn('id_tipo_contrato', 'integer', 8, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 8,
             ));
        $this->hasColumn('descripcion', 'string', 200, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 200,
             ));
        $this->hasColumn('codigo', 'string', 20, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('id_anhos', 'integer', 8, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 8,
             ));
        $this->hasColumn('fecha_proceso', 'timestamp', 7, array(
             'notnull' => true,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('fecha_inicial', 'timestamp', 7, array(
             'notnull' => true,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('fecha_termina', 'timestamp', 7, array(
             'notnull' => true,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('valor_compania', 'integer', 8, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0 ',
             'primary' => false,
             'length' => 8,
             ));
        $this->hasColumn('valor_entidad', 'integer', 8, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0 ',
             'primary' => false,
             'length' => 8,
             ));
        $this->hasColumn('valor_contrato', 'integer', 8, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0 ',
             'primary' => false,
             'length' => 8,
             ));
        $this->hasColumn('aplica_salvedad', 'integer', 1, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0 ',
             'primary' => false,
             'length' => 1,
             ));
        $this->hasColumn('estado', 'integer', 1, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '1 ',
             'primary' => false,
             'length' => 1,
             ));
        $this->hasColumn('fecha_log', 'timestamp', 7, array(
             'notnull' => true,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('usuario_log', 'string', 20, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('fecha_anu', 'timestamp', 7, array(
             'notnull' => false,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('motivo_anu', 'string', 4000, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 4000,
             ));
        $this->hasColumn('usuario_anu', 'string', 20, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('id_supervisor_cont', 'integer', 8, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 8,
             ));
        $this->hasColumn('fecha_caculo_int_banc', 'timestamp', 7, array(
             'notnull' => true,
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 7,
             ));
        $this->hasColumn('aplica_interes_banco', 'integer', 1, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0 ',
             'primary' => false,
             'length' => 1,
             ));
        $this->hasColumn('aplica_interes_mora', 'integer', 1, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0 ',
             'primary' => false,
             'length' => 1,
             ));
        $this->hasColumn('aplica_indexacion', 'integer', 1, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0 ',
             'primary' => false,
             'length' => 1,
             ));
    }

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

        $this->hasOne('ANHOS', array(
             'local' => 'id_anhos',
             'foreign' => 'id_anhos'));

        $this->hasOne('CACO_SUPERVISOR_CONT', array(
             'local' => 'id_supervisor_cont',
             'foreign' => 'id_supervisor_cont'));

        $this->hasMany('CACO_NOVEDAD_DESEMBOLSO', array(
             'local' => 'id_contrato',
             'foreign' => 'id_contrato'));

        $this->hasMany('CACO_NOVEDAD_CONTRATO', array(
             'local' => 'id_contrato',
             'foreign' => 'id_contrato'));

        $this->hasMany('CACO_MODIFICA_SUPERVISOR', array(
             'local' => 'id_contrato',
             'foreign' => 'id_contrato'));

        $this->hasMany('CACO_CONTRATO_ENTIDAD', array(
             'local' => 'id_contrato',
             'foreign' => 'id_contrato'));

        $this->hasMany('CACO_ALERTA_CONTRATO', array(
             'local' => 'id_contrato',
             'foreign' => 'id_contrato'));
    }
}