1 2 3 4 5 6 7 8 9 10 11
| $formPer = $this->createFormBuilder($per)
->add('lName', 'text', array('label' => 'Last name', 'required' => true))
->add('fName', 'text', array('label' => 'First name', 'required' => true))
->add('bName', 'text', array('label' => 'Birth name', 'required' => false))
->add('sex', 'choice', array('expanded'=>true,'multiple'=>false,'choices' => array('M' => 'Male',
'F' => 'Female'),'required' => true,))
->add('dOH','date', array('label' => 'Hire date','empty_value' => array('year' => 'Year','month' => 'Month',
'day' => 'Day')))
->add('address', 'text', array('label' => 'Address', 'required' => true))
->add('profession', 'text', array('label' => 'Profession / Speciality', 'required' => true))
->getForm(); |
Partager