* @version SVN: $Id: sfDoctrineFormTemplate.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $ */ class PersonProfileForm extends ProfileForm { public function configure() { parent::configure(); unset($this['prepayment_type_id']); unset($this['prepayment_count']); unset($this['prepayment_from']); unset($this['prepayment_to']); unset($this['web']); unset($this['name']); unset($this['filename']); unset($this['filename_delete']); unset($this['text']); unset($this['ic']); unset($this['bank_account']); unset($this['representant_id']); $this->widgetSchema['type_id'] = new sfWidgetFormInputHidden(); $this->validatorSchema['first_name']->setOption('required', true); $this->validatorSchema['last_name']->setOption('required', true); $this->setDefault('type_id', ProfileType::PERSON); if($page = Doctrine::getTable('Page')->findOneById(13)) { $this->widgetSchema['agree']->setOption('message', $page->getText()); } commonFormFunctions::setJqUiFormater($this); commonFormFunctions::addClasses($this); } public function bind(array $taintedValues = null, array $taintedFiles = null) { $taintedValues['type_id'] = ProfileType::PERSON; parent::bind($taintedValues, $taintedFiles); } }