Magento2 add custom buttonevent in admin edit form

by Pallavi   Last Updated April 16, 2018 12:09 PM

can anyone help me with suggestions as to how we can add our own custom button with new custom event(saveandaddnew) like saveandcontinue in admin edit form?

$this->buttonList->add(
                'saveandcontinue',
                [
                    'label' => __('Save and Continue Edit'),
                    'class' => 'save',
                    'data_attribute' => [
                        'mage-init' => [
                            'button' => ['event' => 'saveAndContinueEdit', 'target' => '#edit_form'],
                        ],
                    ]
                ],
Tags : magento2


Related Questions



Magento 2.2 Not Loading theme and blocks

Updated January 11, 2018 02:09 AM