protected function setupInheritance() { parent::setupInheritance(); $this->widgetSchema['username'] = new sfWidgetFormInputText(); $this->validatorSchema['username'] = new sfValidatorString(array('max_length' => 128)); $this->widgetSchema['algorithm'] = new sfWidgetFormInputText(); $this->validatorSchema['algorithm'] = new sfValidatorString(array('max_length' => 128, 'required' => false)); $this->widgetSchema['salt'] = new sfWidgetFormInputText(); $this->validatorSchema['salt'] = new sfValidatorString(array('max_length' => 128, 'required' => false)); $this->widgetSchema['password'] = new sfWidgetFormInputText(); $this->validatorSchema['password'] = new sfValidatorString(array('max_length' => 128, 'required' => false)); $this->widgetSchema['is_active'] = new sfWidgetFormInputCheckbox(); $this->validatorSchema['is_active'] = new sfValidatorBoolean(array('required' => false)); $this->widgetSchema['is_super_admin'] = new sfWidgetFormInputCheckbox(); $this->validatorSchema['is_super_admin'] = new sfValidatorBoolean(array('required' => false)); $this->widgetSchema['last_login'] = new sfWidgetFormDateTime(); $this->validatorSchema['last_login'] = new sfValidatorDateTime(array('required' => false)); $this->widgetSchema['created_at'] = new sfWidgetFormDateTime(); $this->validatorSchema['created_at'] = new sfValidatorDateTime(); $this->widgetSchema['updated_at'] = new sfWidgetFormDateTime(); $this->validatorSchema['updated_at'] = new sfValidatorDateTime(); $this->widgetSchema['groups_list'] = new sfWidgetFormDoctrineChoice(array('multiple' => true, 'model' => 'sfGuardGroup')); $this->validatorSchema['groups_list'] = new sfValidatorDoctrineChoice(array('multiple' => true, 'model' => 'sfGuardGroup', 'required' => false)); $this->widgetSchema['permissions_list'] = new sfWidgetFormDoctrineChoice(array('multiple' => true, 'model' => 'sfGuardPermission')); $this->validatorSchema['permissions_list'] = new sfValidatorDoctrineChoice(array('multiple' => true, 'model' => 'sfGuardPermission', 'required' => false)); $this->widgetSchema->setNameFormat('sf_guard_user[%s]'); }
protected function setupInheritance() { parent::setupInheritance(); $this->widgetSchema['cedula'] = new sfWidgetFormInputText(); $this->validatorSchema['cedula'] = new sfValidatorString(array('max_length' => 10)); $this->widgetSchema['licencia'] = new sfWidgetFormInputText(); $this->validatorSchema['licencia'] = new sfValidatorString(array('max_length' => 20, 'required' => false)); $this->widgetSchema->setNameFormat('propietario[%s]'); }
protected function setupInheritance() { parent::setupInheritance(); $this->widgetSchema->setNameFormat('cliente[%s]'); }