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

/**
 * BaseCN_MAE_TER
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id_mae_ter
 * @property integer $id_cia
 * @property string $nitocc
 * @property string $nombre
 * @property string $email
 * @property string $reciproca
 * @property CN_CIA $CN_CIA
 * @property Doctrine_Collection $CN_TABLA_LOG
 * @property Doctrine_Collection $CN_TABLA_LOG_2
 * @property Doctrine_Collection $CN_TABLA_LOG_3
 * @property Doctrine_Collection $CN_TABLA_LOG_4
 * @property Doctrine_Collection $CN_MOVIMIENTO_CONTABLE
 * @property Doctrine_Collection $CN_MOVIMIENTO_CONTABLE_6
 * @property Doctrine_Collection $CN_MOVIMIENTO_CONTABLE_7
 * @property Doctrine_Collection $CN_MOVIMIENTO_CONTABLE_8
 * @property Doctrine_Collection $CN_DOCUMENTO
 * @property Doctrine_Collection $CN_DOCUMENTO_3
 * @property Doctrine_Collection $CN_DOCUMENTO_4
 * @property Doctrine_Collection $CN_DOCUMENTO_5
 * @property Doctrine_Collection $CNI_TS_IM
 * @property Doctrine_Collection $CNI_TS_IM_2
 * @property Doctrine_Collection $CNI_TS_IM_3
 * @property Doctrine_Collection $CNI_TS_IM_4
 * @property Doctrine_Collection $CNI_RUTA
 * @property Doctrine_Collection $CNI_RUTA_10
 * @property Doctrine_Collection $CNI_RUTA_11
 * @property Doctrine_Collection $CNI_RUTA_12
 * @property Doctrine_Collection $CN_MOVIMIENTO_CONTABLE_39
 * @property Doctrine_Collection $CN_MOVIMIENTO_CONTABLE_40
 * @property Doctrine_Collection $CN_MOVIMIENTO_CONTABLE_41
 * 
 * @method integer             getIdMaeTer()                  Returns the current record's "id_mae_ter" value
 * @method integer             getIdCia()                     Returns the current record's "id_cia" value
 * @method string              getNitocc()                    Returns the current record's "nitocc" value
 * @method string              getNombre()                    Returns the current record's "nombre" value
 * @method string              getEmail()                     Returns the current record's "email" value
 * @method string              getReciproca()                 Returns the current record's "reciproca" value
 * @method CN_CIA              getCNCIA()                     Returns the current record's "CN_CIA" value
 * @method Doctrine_Collection getCNTABLALOG()                Returns the current record's "CN_TABLA_LOG" collection
 * @method Doctrine_Collection getCNTABLALOG2()               Returns the current record's "CN_TABLA_LOG_2" collection
 * @method Doctrine_Collection getCNTABLALOG3()               Returns the current record's "CN_TABLA_LOG_3" collection
 * @method Doctrine_Collection getCNTABLALOG4()               Returns the current record's "CN_TABLA_LOG_4" collection
 * @method Doctrine_Collection getCNMOVIMIENTOCONTABLE()      Returns the current record's "CN_MOVIMIENTO_CONTABLE" collection
 * @method Doctrine_Collection getCNMOVIMIENTOCONTABLE6()     Returns the current record's "CN_MOVIMIENTO_CONTABLE_6" collection
 * @method Doctrine_Collection getCNMOVIMIENTOCONTABLE7()     Returns the current record's "CN_MOVIMIENTO_CONTABLE_7" collection
 * @method Doctrine_Collection getCNMOVIMIENTOCONTABLE8()     Returns the current record's "CN_MOVIMIENTO_CONTABLE_8" collection
 * @method Doctrine_Collection getCNDOCUMENTO()               Returns the current record's "CN_DOCUMENTO" collection
 * @method Doctrine_Collection getCNDOCUMENTO3()              Returns the current record's "CN_DOCUMENTO_3" collection
 * @method Doctrine_Collection getCNDOCUMENTO4()              Returns the current record's "CN_DOCUMENTO_4" collection
 * @method Doctrine_Collection getCNDOCUMENTO5()              Returns the current record's "CN_DOCUMENTO_5" collection
 * @method Doctrine_Collection getCNITSIM()                   Returns the current record's "CNI_TS_IM" collection
 * @method Doctrine_Collection getCNITSIM2()                  Returns the current record's "CNI_TS_IM_2" collection
 * @method Doctrine_Collection getCNITSIM3()                  Returns the current record's "CNI_TS_IM_3" collection
 * @method Doctrine_Collection getCNITSIM4()                  Returns the current record's "CNI_TS_IM_4" collection
 * @method Doctrine_Collection getCNIRUTA()                   Returns the current record's "CNI_RUTA" collection
 * @method Doctrine_Collection getCNIRUTA10()                 Returns the current record's "CNI_RUTA_10" collection
 * @method Doctrine_Collection getCNIRUTA11()                 Returns the current record's "CNI_RUTA_11" collection
 * @method Doctrine_Collection getCNIRUTA12()                 Returns the current record's "CNI_RUTA_12" collection
 * @method Doctrine_Collection getCNMOVIMIENTOCONTABLE39()    Returns the current record's "CN_MOVIMIENTO_CONTABLE_39" collection
 * @method Doctrine_Collection getCNMOVIMIENTOCONTABLE40()    Returns the current record's "CN_MOVIMIENTO_CONTABLE_40" collection
 * @method Doctrine_Collection getCNMOVIMIENTOCONTABLE41()    Returns the current record's "CN_MOVIMIENTO_CONTABLE_41" collection
 * @method CN_MAE_TER          setIdMaeTer()                  Sets the current record's "id_mae_ter" value
 * @method CN_MAE_TER          setIdCia()                     Sets the current record's "id_cia" value
 * @method CN_MAE_TER          setNitocc()                    Sets the current record's "nitocc" value
 * @method CN_MAE_TER          setNombre()                    Sets the current record's "nombre" value
 * @method CN_MAE_TER          setEmail()                     Sets the current record's "email" value
 * @method CN_MAE_TER          setReciproca()                 Sets the current record's "reciproca" value
 * @method CN_MAE_TER          setCNCIA()                     Sets the current record's "CN_CIA" value
 * @method CN_MAE_TER          setCNTABLALOG()                Sets the current record's "CN_TABLA_LOG" collection
 * @method CN_MAE_TER          setCNTABLALOG2()               Sets the current record's "CN_TABLA_LOG_2" collection
 * @method CN_MAE_TER          setCNTABLALOG3()               Sets the current record's "CN_TABLA_LOG_3" collection
 * @method CN_MAE_TER          setCNTABLALOG4()               Sets the current record's "CN_TABLA_LOG_4" collection
 * @method CN_MAE_TER          setCNMOVIMIENTOCONTABLE()      Sets the current record's "CN_MOVIMIENTO_CONTABLE" collection
 * @method CN_MAE_TER          setCNMOVIMIENTOCONTABLE6()     Sets the current record's "CN_MOVIMIENTO_CONTABLE_6" collection
 * @method CN_MAE_TER          setCNMOVIMIENTOCONTABLE7()     Sets the current record's "CN_MOVIMIENTO_CONTABLE_7" collection
 * @method CN_MAE_TER          setCNMOVIMIENTOCONTABLE8()     Sets the current record's "CN_MOVIMIENTO_CONTABLE_8" collection
 * @method CN_MAE_TER          setCNDOCUMENTO()               Sets the current record's "CN_DOCUMENTO" collection
 * @method CN_MAE_TER          setCNDOCUMENTO3()              Sets the current record's "CN_DOCUMENTO_3" collection
 * @method CN_MAE_TER          setCNDOCUMENTO4()              Sets the current record's "CN_DOCUMENTO_4" collection
 * @method CN_MAE_TER          setCNDOCUMENTO5()              Sets the current record's "CN_DOCUMENTO_5" collection
 * @method CN_MAE_TER          setCNITSIM()                   Sets the current record's "CNI_TS_IM" collection
 * @method CN_MAE_TER          setCNITSIM2()                  Sets the current record's "CNI_TS_IM_2" collection
 * @method CN_MAE_TER          setCNITSIM3()                  Sets the current record's "CNI_TS_IM_3" collection
 * @method CN_MAE_TER          setCNITSIM4()                  Sets the current record's "CNI_TS_IM_4" collection
 * @method CN_MAE_TER          setCNIRUTA()                   Sets the current record's "CNI_RUTA" collection
 * @method CN_MAE_TER          setCNIRUTA10()                 Sets the current record's "CNI_RUTA_10" collection
 * @method CN_MAE_TER          setCNIRUTA11()                 Sets the current record's "CNI_RUTA_11" collection
 * @method CN_MAE_TER          setCNIRUTA12()                 Sets the current record's "CNI_RUTA_12" collection
 * @method CN_MAE_TER          setCNMOVIMIENTOCONTABLE39()    Sets the current record's "CN_MOVIMIENTO_CONTABLE_39" collection
 * @method CN_MAE_TER          setCNMOVIMIENTOCONTABLE40()    Sets the current record's "CN_MOVIMIENTO_CONTABLE_40" collection
 * @method CN_MAE_TER          setCNMOVIMIENTOCONTABLE41()    Sets the current record's "CN_MOVIMIENTO_CONTABLE_41" collection
 * 
 * @package    Sofhouse
 * @subpackage model
 * @author     Software House
 * @version    SVN: $Id: Builder.php 7691 2011-02-04 15:43:29Z jwage $
 */
abstract class BaseCN_MAE_TER extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('CN_MAE_TER');
        $this->hasColumn('id_mae_ter', 'integer', 8, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 8,
             ));
        $this->hasColumn('id_cia', 'integer', 8, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 8,
             ));
        $this->hasColumn('nitocc', 'string', 32, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 32,
             ));
        $this->hasColumn('nombre', 'string', 128, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 128,
             ));
        $this->hasColumn('email', 'string', 128, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 128,
             ));
        $this->hasColumn('reciproca', 'string', 20, array(
             'notnull' => false,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 20,
             ));
        $this->hasColumn('activo', 'integer', 1, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '1 ',
             'primary' => false,
             'length' => 1,
             ));
    }

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

        $this->hasMany('CN_TABLA_LOG', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_cia'));

        $this->hasMany('CN_TABLA_LOG as CN_TABLA_LOG_2', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CN_TABLA_LOG as CN_TABLA_LOG_3', array(
             'local' => 'id_cia',
             'foreign' => 'id_cia'));

        $this->hasMany('CN_TABLA_LOG as CN_TABLA_LOG_4', array(
             'local' => 'id_cia',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CN_MOVIMIENTO_CONTABLE', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_cia'));

        $this->hasMany('CN_MOVIMIENTO_CONTABLE as CN_MOVIMIENTO_CONTABLE_6', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CN_MOVIMIENTO_CONTABLE as CN_MOVIMIENTO_CONTABLE_7', array(
             'local' => 'id_cia',
             'foreign' => 'id_cia'));

        $this->hasMany('CN_MOVIMIENTO_CONTABLE as CN_MOVIMIENTO_CONTABLE_8', array(
             'local' => 'id_cia',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CN_DOCUMENTO', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_cia'));

        $this->hasMany('CN_DOCUMENTO as CN_DOCUMENTO_3', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CN_DOCUMENTO as CN_DOCUMENTO_4', array(
             'local' => 'id_cia',
             'foreign' => 'id_cia'));

        $this->hasMany('CN_DOCUMENTO as CN_DOCUMENTO_5', array(
             'local' => 'id_cia',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CNI_TS_IM', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_cia'));

        $this->hasMany('CNI_TS_IM as CNI_TS_IM_2', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CNI_TS_IM as CNI_TS_IM_3', array(
             'local' => 'id_cia',
             'foreign' => 'id_cia'));

        $this->hasMany('CNI_TS_IM as CNI_TS_IM_4', array(
             'local' => 'id_cia',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CNI_RUTA', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_ruta'));

        $this->hasMany('CNI_RUTA as CNI_RUTA_10', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CNI_RUTA as CNI_RUTA_11', array(
             'local' => 'id_cia',
             'foreign' => 'id_ruta'));

        $this->hasMany('CNI_RUTA as CNI_RUTA_12', array(
             'local' => 'id_cia',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CN_MOVIMIENTO_CONTABLE as CN_MOVIMIENTO_CONTABLE_39', array(
             'local' => 'id_cia',
             'foreign' => 'id_cia'));

        $this->hasMany('CN_MOVIMIENTO_CONTABLE as CN_MOVIMIENTO_CONTABLE_40', array(
             'local' => 'id_mae_ter',
             'foreign' => 'id_mae_ter'));

        $this->hasMany('CN_MOVIMIENTO_CONTABLE as CN_MOVIMIENTO_CONTABLE_41', array(
             'local' => 'id_cia',
             'foreign' => 'id_mae_ter'));
    }
}