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

/**
 * BaseTS_TD
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id
 * @property string $documento
 * @property string $descripcion
 * @property string $desccorta
 * @property integer $codigosiif
 * @property Doctrine_Collection $TS_MOV_BANC
 * @property Doctrine_Collection $TS_NOT_TESO
 * @property Doctrine_Collection $CM_MOV_BANC
 * @property Doctrine_Collection $CA_NOVEDAD_CARTERA
 * @property Doctrine_Collection $CA_CREDITO
 * @property Doctrine_Collection $RE_RECAUDO
 * 
 * @method integer             getId()                 Returns the current record's "id" value
 * @method string              getDocumento()          Returns the current record's "documento" value
 * @method string              getDescripcion()        Returns the current record's "descripcion" value
 * @method string              getDesccorta()          Returns the current record's "desccorta" value
 * @method integer             getCodigosiif()         Returns the current record's "codigosiif" value
 * @method Doctrine_Collection getTSMOVBANC()          Returns the current record's "TS_MOV_BANC" collection
 * @method Doctrine_Collection getTSNOTTESO()          Returns the current record's "TS_NOT_TESO" collection
 * @method Doctrine_Collection getCMMOVBANC()          Returns the current record's "CM_MOV_BANC" collection
 * @method Doctrine_Collection getCANOVEDADCARTERA()   Returns the current record's "CA_NOVEDAD_CARTERA" collection
 * @method Doctrine_Collection getCACREDITO()          Returns the current record's "CA_CREDITO" collection
 * @method Doctrine_Collection getRERECAUDO()          Returns the current record's "RE_RECAUDO" collection
 * @method TS_TD               setId()                 Sets the current record's "id" value
 * @method TS_TD               setDocumento()          Sets the current record's "documento" value
 * @method TS_TD               setDescripcion()        Sets the current record's "descripcion" value
 * @method TS_TD               setDesccorta()          Sets the current record's "desccorta" value
 * @method TS_TD               setCodigosiif()         Sets the current record's "codigosiif" value
 * @method TS_TD               setTSMOVBANC()          Sets the current record's "TS_MOV_BANC" collection
 * @method TS_TD               setTSNOTTESO()          Sets the current record's "TS_NOT_TESO" collection
 * @method TS_TD               setCMMOVBANC()          Sets the current record's "CM_MOV_BANC" collection
 * @method TS_TD               setCANOVEDADCARTERA()   Sets the current record's "CA_NOVEDAD_CARTERA" collection
 * @method TS_TD               setCACREDITO()          Sets the current record's "CA_CREDITO" collection
 * @method TS_TD               setRERECAUDO()          Sets the current record's "RE_RECAUDO" collection
 * 
 * @package    cartera
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7691 2011-02-04 15:43:29Z jwage $
 */
abstract class BaseTS_TD extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('TS_TD');
        $this->hasColumn('id', 'integer', 20, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 20,
             ));
        $this->hasColumn('documento', 'string', 20, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('descripcion', 'string', 1000, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 1000,
             ));
        $this->hasColumn('desccorta', 'string', 500, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 500,
             ));
        $this->hasColumn('codsiif', 'integer', 2, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 2,
             ));
    }

    public function setUp()
    {
        parent::setUp();
        $this->hasMany('TS_MOV_BANC', array(
             'local' => 'id',
             'foreign' => 'id_ts_td'));

        $this->hasMany('TS_NOT_TESO', array(
             'local' => 'id',
             'foreign' => 'id_tip_doc'));

        $this->hasMany('CM_MOV_BANC', array(
             'local' => 'id',
             'foreign' => 'id_ts_td'));

        $this->hasMany('CA_NOVEDAD_CARTERA', array(
             'local' => 'id',
             'foreign' => 'id_ts_td'));

        $this->hasMany('CA_CREDITO', array(
             'local' => 'id',
             'foreign' => 'id_ts_td'));

        $this->hasMany('RE_RECAUDO', array(
             'local' => 'id',
             'foreign' => 'id_ts_td'));
    }
}