src/Integration/Subcolumns.php
public function hookLoadFormField($widget)
    {
        if ($widget->type === 'formcolstart') {
            $type   = $widget->fsc_type;
            $gridId = $widget->bootstrap_grid;
            $grid   = Factory::createById($gridId);

            $GLOBALS['TL_SUBCL'][static::$name]['sets'][$type] = $this->prepareContainer($grid);

        } elseif ($widget->type === 'formcolpart' || $widget->type === 'formcolend') {
            $parent = \FormFieldModel::findByPk($widget->fsc_parent);

            $this->updateSubcolumnsDefinition($parent->bootstrap_grid, $parent->fsc_type);
        }

        return $widget;
    }
public function hookLoadFormField($widget)
    {
        if ($widget->type === 'formcolstart') {
            $type   = $widget->fsc_type;
            $gridId = $widget->bootstrap_grid;
            $grid   = Factory::createById($gridId);

            $GLOBALS['TL_SUBCL'][static::$name]['sets'][$type] = $this->prepareContainer($grid);

        } elseif ($widget->type === 'formcolpart' || $widget->type === 'formcolend') {
            $parent = \FormFieldModel::findByPk($widget->fsc_parent);

            $this->updateSubcolumnsDefinition($parent->bootstrap_grid, $parent->fsc_type);
        }

        return $widget;
    }
Load columnset definition for the form field.

@param \Widget $widget The form widget.

@return \Widget

@SuppressWarnings(PHPMD.Superglobals)