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

/**
 * BaseCN_FIRMA
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id_firma
 * @property integer $id_cia
 * @property string $nombre
 * @property integer $documento
 * @property string $cargo
 * @property integer $numero
 * @property string $anexo
 * @property integer $activo
 * @property integer $orden
 * @property CN_CIA $CN_CIA
 * @property Doctrine_Collection $CN_INFORME_FIRMA
 * @property Doctrine_Collection $CN_INFORME_FIRMA_3
 * @property Doctrine_Collection $CN_INFORME_FIRMA_4
 * @property Doctrine_Collection $CN_INFORME_FIRMA_5
 * 
 * @method integer             getIdFirma()            Returns the current record's "id_firma" value
 * @method integer             getIdCia()              Returns the current record's "id_cia" value
 * @method string              getNombre()             Returns the current record's "nombre" value
 * @method integer             getDocumento()          Returns the current record's "documento" value
 * @method string              getCargo()              Returns the current record's "cargo" value
 * @method integer             getNumero()             Returns the current record's "numero" value
 * @method string              getAnexo()              Returns the current record's "anexo" value
 * @method integer             getActivo()             Returns the current record's "activo" value
 * @method integer             getOrden()              Returns the current record's "orden" value
 * @method CN_CIA              getCNCIA()              Returns the current record's "CN_CIA" value
 * @method Doctrine_Collection getCNINFORMEFIRMA()     Returns the current record's "CN_INFORME_FIRMA" collection
 * @method Doctrine_Collection getCNINFORMEFIRMA3()    Returns the current record's "CN_INFORME_FIRMA_3" collection
 * @method Doctrine_Collection getCNINFORMEFIRMA4()    Returns the current record's "CN_INFORME_FIRMA_4" collection
 * @method Doctrine_Collection getCNINFORMEFIRMA5()    Returns the current record's "CN_INFORME_FIRMA_5" collection
 * @method CN_FIRMA            setIdFirma()            Sets the current record's "id_firma" value
 * @method CN_FIRMA            setIdCia()              Sets the current record's "id_cia" value
 * @method CN_FIRMA            setNombre()             Sets the current record's "nombre" value
 * @method CN_FIRMA            setDocumento()          Sets the current record's "documento" value
 * @method CN_FIRMA            setCargo()              Sets the current record's "cargo" value
 * @method CN_FIRMA            setNumero()             Sets the current record's "numero" value
 * @method CN_FIRMA            setAnexo()              Sets the current record's "anexo" value
 * @method CN_FIRMA            setActivo()             Sets the current record's "activo" value
 * @method CN_FIRMA            setOrden()              Sets the current record's "orden" value
 * @method CN_FIRMA            setCNCIA()              Sets the current record's "CN_CIA" value
 * @method CN_FIRMA            setCNINFORMEFIRMA()     Sets the current record's "CN_INFORME_FIRMA" collection
 * @method CN_FIRMA            setCNINFORMEFIRMA3()    Sets the current record's "CN_INFORME_FIRMA_3" collection
 * @method CN_FIRMA            setCNINFORMEFIRMA4()    Sets the current record's "CN_INFORME_FIRMA_4" collection
 * @method CN_FIRMA            setCNINFORMEFIRMA5()    Sets the current record's "CN_INFORME_FIRMA_5" collection
 * 
 * @package    Sofhouse
 * @subpackage model
 * @author     Software House
 * @version    SVN: $Id: Builder.php 7691 2011-02-04 15:43:29Z jwage $
 */
abstract class BaseCN_FIRMA extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('CN_FIRMA');
        $this->hasColumn('id_firma', '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('nombre', 'string', 128, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 128,
             ));
        $this->hasColumn('documento', 'integer', 8, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 8,
             ));
        $this->hasColumn('cargo', 'string', 128, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 128,
             ));
        $this->hasColumn('numero', 'integer', 8, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 8,
             ));
        $this->hasColumn('anexo', 'string', 128, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 128,
             'default' => '(Ver anexo) ',
             ));
        $this->hasColumn('activo', 'integer', 1, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '1 ',
             'primary' => false,
             'length' => 1,
             ));
        $this->hasColumn('orden', 'integer', 8, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 8,
             'default' => 0,
             ));
    }

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

        $this->hasMany('CN_INFORME_FIRMA', array(
             'local' => 'id_firma',
             'foreign' => 'id_cia'));

        $this->hasMany('CN_INFORME_FIRMA as CN_INFORME_FIRMA_3', array(
             'local' => 'id_firma',
             'foreign' => 'id_firma'));

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

        $this->hasMany('CN_INFORME_FIRMA as CN_INFORME_FIRMA_5', array(
             'local' => 'id_cia',
             'foreign' => 'id_firma'));
    }
}