You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
959 B
42 lines
959 B
![]()
8 years ago
|
<?php
|
||
|
/* For licensing terms, see /license.txt */
|
||
|
|
||
|
namespace Chamilo\CourseBundle\Settings;
|
||
|
|
||
|
use Chamilo\CoreBundle\Settings\AbstractSettingsSchema;
|
||
|
use Sylius\Bundle\SettingsBundle\Schema\SettingsBuilderInterface;
|
||
|
use Symfony\Component\Form\FormBuilderInterface;
|
||
|
|
||
|
/**
|
||
|
* Class GroupCourseSettingsSchema
|
||
|
* @package Chamilo\CourseBundle\Settings
|
||
|
*/
|
||
|
class GroupCourseSettingsSchema extends AbstractSettingsSchema
|
||
|
{
|
||
|
/**
|
||
|
* {@inheritdoc}
|
||
|
*/
|
||
|
public function buildSettings(SettingsBuilderInterface $builder)
|
||
|
{
|
||
|
$builder
|
||
|
->setDefaults(array(
|
||
|
'enabled' => '',
|
||
|
))
|
||
|
;
|
||
|
$allowedTypes = [
|
||
|
'enabled' => ['string'],
|
||
|
];
|
||
|
$this->setMultipleAllowedTypes($allowedTypes, $builder);
|
||
|
}
|
||
|
|
||
|
/**
|
||
|
* {@inheritdoc}
|
||
|
*/
|
||
|
public function buildForm(FormBuilderInterface $builder)
|
||
|
{
|
||
|
$builder
|
||
|
->add('enabled', 'yes_no')
|
||
|
;
|
||
|
}
|
||
|
}
|