Conditions | 3 |
Paths | 2 |
Total Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
33 | public function buildForm(FormBuilderInterface $builder, array $options) |
||
34 | { |
||
35 | if ('doctrine_phpcr' !== $options['sonata_field_description']->getAdmin()->getManagerType() || !$options['sonata_field_description']->getOption('sortable')) { |
||
36 | return; |
||
37 | } |
||
38 | $listener = new CollectionOrderListener($options['sonata_field_description']->getName()); |
||
39 | $builder->addEventListener(FormEvents::SUBMIT, [$listener, 'onSubmit']); |
||
40 | } |
||
41 | |||
60 |