mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-25 09:03:48 +00:00
add a required field to custom fields type
ref Chill-project/Chill-CustomFields#17
This commit is contained in:
@@ -66,6 +66,11 @@ class CustomFieldType extends AbstractType
|
||||
|
||||
$builder
|
||||
->add('ordering', 'number')
|
||||
->add('required', 'checkbox', array(
|
||||
'required' => false,
|
||||
//'expanded' => TRUE,
|
||||
'label' => 'Required field'
|
||||
))
|
||||
->add('type', 'hidden', array('data' => $options['type']))
|
||||
->addEventListener(FormEvents::PRE_SET_DATA, function (FormEvent $event)
|
||||
{
|
||||
|
Reference in New Issue
Block a user