function paragraphs_ee_form_paragraphs_type_form_builder in Paragraphs Editor Enhancements 8
Entity builder for the menu configuration entity.
1 string reference to 'paragraphs_ee_form_paragraphs_type_form_builder'
File
- ./
paragraphs_ee.module, line 265 - Main functions for "Paragraphs Editor Enhancements" module.
Code
function paragraphs_ee_form_paragraphs_type_form_builder($entity_type, ParagraphsTypeInterface $paragraph, &$form, FormStateInterface $form_state) {
if ($form_state
->getValue('paragraphs_categories')) {
$paragraph
->setThirdPartySetting('paragraphs_ee', 'paragraphs_categories', array_filter($form_state
->getValue('paragraphs_categories')));
return;
}
// Remove setting.
$paragraph
->unsetThirdPartySetting('paragraphs_ee', 'paragraphs_categories');
}