adding empty data on CFChoice

And fixing a bug occuring because type of empty data are wrong.

fix #23
This commit is contained in:
2016-08-11 23:26:32 +02:00
parent 2e59c0666b
commit affeae238c
2 changed files with 15 additions and 11 deletions

View File

@@ -123,26 +123,26 @@ class CustomFieldChoice extends AbstractCustomField
'expanded' => true,
'multiple' => false,
'choices' => array(
1 => 'Multiple',
0 => 'Unique'),
'empty_data' => 0,
'1' => 'Multiple',
'0' => 'Unique'),
'empty_data' => '0',
'label' => 'Multiplicity'
))
->add(self::EXPANDED, 'choice', array(
'expanded' => true,
'multiple' => false,
'choices' => array(
1 => 'Expanded',
0 => 'Non expanded'),
'empty_data' => 0,
'1' => 'Expanded',
'0' => 'Non expanded'),
'empty_data' => '0',
'label' => 'Choice display'
))
->add(self::ALLOW_OTHER, 'choice', array(
'label' => 'Allow other',
'choices' => array(
0 => 'No',
1 => 'Yes'),
'empty_data' => 0,
'0' => 'No',
'1' => 'Yes'),
'empty_data' => '0',
'expanded' => true,
'multiple' => false
))