I am trying to make a (very simplified) page builder for just the homepage in Magento 2.3.
I figured out how to build a repeating field from a serialized array, like this :
<field id="footer_links_2" translate="label comment tooltip" sortOrder="4" showInDefault="1" showInWebsite="1" showInStore="0">
<label>Footer links (Midden)</label>
<frontend_model>Brancom\FooterContext\Block\Adminhtml\System\Config\Form\Field\Footerlinks</frontend_model>
<backend_model>Magento\Config\Model\Config\Backend\Serialized\ArraySerialized</backend_model>
</field>
This is the model
class Footerlinks extends AbstractFieldArray
{
/**
* @var Factory
*/
protected $_elementFactory;
/**
* @param Context $context
* @param Factory $elementFactory
* @param array $data
*/
public function __construct(
Context $context,
Factory $elementFactory,
array $data = []
) {
$this->_elementFactory = $elementFactory;
parent::__construct($context, $data);
}
protected function _construct()
{
$this->addColumn('name', ['label' => __('Tekst')]);
$this->addColumn('link', ['label' => __('Link')]);
$this->_addAfter = false;
$this->_addButtonLabel = __('Voeg Toe');
parent::_construct();
}
}
But I can't seem to find a way to add a column with a WYSIWYG field. Is this even possible?