diff --git a/core/Entity/Site/Page/ChoiceBlock.php b/core/Entity/Site/Page/ChoiceBlock.php new file mode 100644 index 0000000..69f5b38 --- /dev/null +++ b/core/Entity/Site/Page/ChoiceBlock.php @@ -0,0 +1,21 @@ +add( + 'value', + ChoiceType::class, + array_merge([ + 'required' => false, + 'label' => false, + ], $options['options']), + ); + } + + public function configureOptions(OptionsResolver $resolver) + { + $resolver->setDefaults([ + 'data_class' => ChoiceBlock::class, + 'options' => [], + ]); + } +}