protected function modalBegin()
    {
        $config = ArrayHelper::merge([
            'class' => ModalButton::class,
            'model' => $this->model,
            'scenario' => $this->scenario,
            'button' => $this->button,
            'form' => [
                'enableAjaxValidation' => true,
                'validationUrl' => $this->validationUrl,
            ],
            'modal' => [
                'header' => Html::tag(ArrayHelper::remove($this->header, 'tag', 'h4'),
                    ArrayHelper::remove($this->header, 'label')),
                'headerOptions' => $this->header,
                'footer' => $this->footer,
            ],
        ], $this->modal);

        $this->modal = call_user_func([ArrayHelper::remove($config, 'class'), 'begin'], $config);
    }