<?php

/**
 * Regionales form base class.
 *
 * @package    form
 * @subpackage regionales
 * @version    SVN: $Id: sfPropelFormGeneratedTemplate.php 15484 2009-02-13 13:13:51Z fabien $
 */
class BaseRegionalesForm extends BaseFormPropel
{
  public function setup()
  {
    $this->setWidgets(array(
      'codreg'    => new sfWidgetFormInputHidden(),
      'desreg'    => new sfWidgetFormInput(),
      'ciuced'    => new sfWidgetFormInput(),
      'departa'   => new sfWidgetFormInput(),
      'direccion' => new sfWidgetFormInput(),
      'coddep'    => new sfWidgetFormInput(),
      'codmun'    => new sfWidgetFormInput(),
      'nitcaja'   => new sfWidgetFormInput(),
      'codcaj'    => new sfWidgetFormInput(),
      'razsoc'    => new sfWidgetFormInput(),
    ));

    $this->setValidators(array(
      'codreg'    => new sfValidatorPropelChoice(array('model' => 'Regionales', 'column' => 'codreg', 'required' => false)),
      'desreg'    => new sfValidatorString(array('max_length' => 100, 'required' => false)),
      'ciuced'    => new sfValidatorString(array('max_length' => 100, 'required' => false)),
      'departa'   => new sfValidatorString(array('max_length' => 100, 'required' => false)),
      'direccion' => new sfValidatorString(array('max_length' => 100, 'required' => false)),
      'coddep'    => new sfValidatorString(array('max_length' => 20, 'required' => false)),
      'codmun'    => new sfValidatorString(array('max_length' => 20, 'required' => false)),
      'nitcaja'   => new sfValidatorString(array('max_length' => 50, 'required' => false)),
      'codcaj'    => new sfValidatorString(array('max_length' => 20, 'required' => false)),
      'razsoc'    => new sfValidatorString(array('max_length' => 100, 'required' => false)),
    ));

    $this->widgetSchema->setNameFormat('regionales[%s]');

    $this->errorSchema = new sfValidatorErrorSchema($this->validatorSchema);

    parent::setup();
  }

  public function getModelName()
  {
    return 'Regionales';
  }


}
