| 1 | <?php |
||
| 9 | class MediaType extends AbstractType |
||
| 10 | { |
||
| 11 | /** |
||
| 12 | * @param FormBuilderInterface $builder |
||
| 13 | * @param array $options |
||
| 14 | */ |
||
| 15 | public function buildForm(FormBuilderInterface $builder, array $options) |
||
| 16 | { |
||
| 17 | $builder |
||
| 18 | ->add('fileData','file') |
||
| 19 | ; |
||
| 20 | } |
||
| 21 | |||
| 22 | /** |
||
| 23 | * @param OptionsResolverInterface $resolver |
||
| 24 | */ |
||
| 25 | public function setDefaultOptions(OptionsResolverInterface $resolver) |
||
| 26 | { |
||
| 27 | $resolver->setDefaults(array( |
||
| 28 | 'data_class' => 'Mykees\MediaBundle\Entity\Media' |
||
| 29 | )); |
||
| 30 | } |
||
| 31 | |||
| 32 | /** |
||
| 33 | * @return string |
||
| 34 | */ |
||
| 35 | public function getName() |
||
| 39 | } |
||
| 40 |