1 | <?php |
||
27 | abstract class AbstractGridBatchSubscriber implements EventSubscriberInterface |
||
28 | { |
||
29 | /** |
||
30 | * @var RegistryInterface |
||
31 | */ |
||
32 | private $repositoryRegistry; |
||
33 | |||
34 | /** |
||
35 | * @var ParameterResolverInterface |
||
36 | */ |
||
37 | private $parameterResolver; |
||
38 | |||
39 | /** |
||
40 | * @param RegistryInterface $repositoryRegistry |
||
41 | * @param ParameterResolverInterface $parameterResolver |
||
42 | */ |
||
43 | public function __construct( |
||
50 | |||
51 | /** |
||
52 | * @param FormEvent $event |
||
53 | */ |
||
54 | public function onPreSetData(FormEvent $event) |
||
64 | |||
65 | /** |
||
66 | * @param FormEvent $event |
||
67 | */ |
||
68 | public function onPreSubmit(FormEvent $event) |
||
80 | |||
81 | /** |
||
82 | * {@inheritdoc} |
||
83 | */ |
||
84 | public static function getSubscribedEvents() |
||
91 | |||
92 | /** |
||
93 | * @param GridInterface $grid |
||
94 | * @param RepositoryInterface $repository |
||
95 | * @param mixed[] $choices |
||
96 | * |
||
97 | * @return object[] |
||
98 | */ |
||
99 | abstract protected function findChoices(GridInterface $grid, RepositoryInterface $repository, array $choices); |
||
100 | |||
101 | /** |
||
102 | * @param FormInterface $form |
||
103 | * @param object[] $choices |
||
104 | */ |
||
105 | private function buildForm(FormInterface $form, array $choices) |
||
114 | |||
115 | /** |
||
116 | * @param FormInterface $form |
||
117 | * |
||
118 | * @return mixed[] |
||
119 | */ |
||
120 | private function handleAll(FormInterface $form) |
||
132 | |||
133 | /** |
||
134 | * @param FormInterface $form |
||
135 | * @param mixed[] $data |
||
136 | */ |
||
137 | private function handleValue(FormInterface $form, $data) |
||
161 | } |
||
162 |