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

/**
 * BaseCA_CREDITO_DETALLE
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id_credito_detalle
 * @property integer $id_credito
 * @property integer $id_vencimiento
 * @property decimal $valor_bruto
 * @property decimal $valor_retenciones
 * @property decimal $valor_abono
 * @property integer $id_tip_mon
 * @property decimal $valor_total_moneda
 * @property decimal $trm_credito
 * @property decimal $diferencia_cambio
 * @property string $observaciones
 * @property CA_CREDITO $CA_CREDITO
 * @property CA_TIP_MON $CA_TIP_MON
 * @property CA_VENCIMIENTOS $CA_VENCIMIENTOS
 * 
 * @method integer            getIdCreditoDetalle()   Returns the current record's "id_credito_detalle" value
 * @method integer            getIdCredito()          Returns the current record's "id_credito" value
 * @method integer            getIdVencimiento()      Returns the current record's "id_vencimiento" value
 * @method decimal            getValorBruto()         Returns the current record's "valor_bruto" value
 * @method decimal            getValorRetenciones()   Returns the current record's "valor_retenciones" value
 * @method decimal            getValorAbono()         Returns the current record's "valor_abono" value
 * @method integer            getIdTipMon()           Returns the current record's "id_tip_mon" value
 * @method decimal            getValorTotalMoneda()   Returns the current record's "valor_total_moneda" value
 * @method decimal            getTrmCredito()         Returns the current record's "trm_credito" value
 * @method decimal            getDiferenciaCambio()   Returns the current record's "diferencia_cambio" value
 * @method string             getObservaciones()      Returns the current record's "observaciones" value
 * @method CA_CREDITO         getCACREDITO()          Returns the current record's "CA_CREDITO" value
 * @method CA_TIP_MON         getCATIPMON()           Returns the current record's "CA_TIP_MON" value
 * @method CA_VENCIMIENTOS    getCAVENCIMIENTOS()     Returns the current record's "CA_VENCIMIENTOS" value
 * @method CA_CREDITO_DETALLE setIdCreditoDetalle()   Sets the current record's "id_credito_detalle" value
 * @method CA_CREDITO_DETALLE setIdCredito()          Sets the current record's "id_credito" value
 * @method CA_CREDITO_DETALLE setIdVencimiento()      Sets the current record's "id_vencimiento" value
 * @method CA_CREDITO_DETALLE setValorBruto()         Sets the current record's "valor_bruto" value
 * @method CA_CREDITO_DETALLE setValorRetenciones()   Sets the current record's "valor_retenciones" value
 * @method CA_CREDITO_DETALLE setValorAbono()         Sets the current record's "valor_abono" value
 * @method CA_CREDITO_DETALLE setIdTipMon()           Sets the current record's "id_tip_mon" value
 * @method CA_CREDITO_DETALLE setValorTotalMoneda()   Sets the current record's "valor_total_moneda" value
 * @method CA_CREDITO_DETALLE setTrmCredito()         Sets the current record's "trm_credito" value
 * @method CA_CREDITO_DETALLE setDiferenciaCambio()   Sets the current record's "diferencia_cambio" value
 * @method CA_CREDITO_DETALLE setObservaciones()      Sets the current record's "observaciones" value
 * @method CA_CREDITO_DETALLE setCACREDITO()          Sets the current record's "CA_CREDITO" value
 * @method CA_CREDITO_DETALLE setCATIPMON()           Sets the current record's "CA_TIP_MON" value
 * @method CA_CREDITO_DETALLE setCAVENCIMIENTOS()     Sets the current record's "CA_VENCIMIENTOS" value
 * 
 * @package    nomina
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7691 2011-02-04 15:43:29Z jwage $
 */
abstract class BaseCA_CREDITO_DETALLE extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('CA_CREDITO_DETALLE');
        $this->hasColumn('id_credito_detalle', 'integer', 20, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 20,
             ));
        $this->hasColumn('id_credito', 'integer', 20, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('id_vencimiento', 'integer', 20, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('valor_bruto', 'decimal', 18, array(
             'notnull' => true,
             'type' => 'decimal',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0',
             'primary' => false,
             'length' => 18,
             ));
        $this->hasColumn('valor_retenciones', 'decimal', 18, array(
             'notnull' => true,
             'type' => 'decimal',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0',
             'primary' => false,
             'length' => 18,
             ));
        $this->hasColumn('valor_abono', 'decimal', 18, array(
             'notnull' => true,
             'type' => 'decimal',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0',
             'primary' => false,
             'length' => 18,
             ));
        $this->hasColumn('id_tip_mon', 'integer', 20, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('valor_total_moneda', 'decimal', 18, array(
             'notnull' => true,
             'type' => 'decimal',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0',
             'primary' => false,
             'length' => 18,
             ));
        $this->hasColumn('trm_credito', 'decimal', 18, array(
             'notnull' => true,
             'type' => 'decimal',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0',
             'primary' => false,
             'length' => 18,
             ));
        $this->hasColumn('diferencia_cambio', 'decimal', 18, array(
             'notnull' => true,
             'type' => 'decimal',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0',
             'primary' => false,
             'length' => 18,
             ));
        $this->hasColumn('observaciones', 'string', 4000, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 4000,
             ));
    }

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

        $this->hasOne('CA_TIP_MON', array(
             'local' => 'id_tip_mon',
             'foreign' => 'id_tip_mon'));

        $this->hasOne('CA_VENCIMIENTOS', array(
             'local' => 'id_vencimiento',
             'foreign' => 'id_vencimiento'));
    }
}