Exemple #1
0
 public function buildForm(FormBuilderInterface $builder, array $options)
 {
     $builder->add('category');
     $builder->add('type', 'choice', array('choices' => Job::getTypes(), 'expanded' => true));
     $builder->add('company');
     $builder->add('file', 'file', array('label' => 'Company logo', 'required' => false));
     $builder->add('url');
     $builder->add('position');
     $builder->add('location');
     $builder->add('description');
     $builder->add('how_to_apply', null, array('label' => 'How to apply?'));
     $builder->add('is_public', null, array('label' => 'Public?'));
     $builder->add('email');
 }
Exemple #2
0
 protected function configureFormFields(FormMapper $formMapper)
 {
     $formMapper->add('category')->add('type', 'choice', array('choices' => Job::getTypes(), 'expanded' => true))->add('company')->add('file', 'file', array('label' => 'Company logo', 'required' => false))->add('url')->add('position')->add('location')->add('description')->add('how_to_apply')->add('is_public')->add('email')->add('is_activated');
 }