public static function getRequiredModules() { return array('Locale', 'Settings', 'Users', 'Groups', 'Extensions', 'Pages', 'Search', 'ContentBlocks', 'Tags'); }
/** * Make sure the required modules are checked and can't be desalbed * * @param FormView $view The FormView generated by Symfony * @param FormInterface $form The form itself * @param array $options The array options */ public function finishView(FormView $view, FormInterface $form, array $options) { foreach ($view->children['modules']->children as $module) { if (in_array($module->vars['value'], ForkInstaller::getRequiredModules())) { $module->vars['attr']['disabled'] = 'disabled'; $module->vars['checked'] = true; } } }