SaveAndContinueButton.php 873 B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. /**
  3. * Copyright © 2016 Ihor Vansach (ihor@magefan.com). All rights reserved.
  4. * See LICENSE.txt for license details (http://opensource.org/licenses/osl-3.0.php).
  5. *
  6. * Glory to Ukraine! Glory to the heroes!
  7. */
  8. namespace Magefan\Blog\Block\Adminhtml\Edit;
  9. use Magento\Framework\View\Element\UiComponent\Control\ButtonProviderInterface;
  10. /**
  11. * Class SaveAndContinueButton
  12. */
  13. class SaveAndContinueButton extends GenericButton implements ButtonProviderInterface
  14. {
  15. /**
  16. * @return array
  17. */
  18. public function getButtonData()
  19. {
  20. return [
  21. 'label' => __('Save and Continue Edit'),
  22. 'class' => 'save',
  23. 'data_attribute' => [
  24. 'mage-init' => [
  25. 'button' => ['event' => 'saveAndContinueEdit'],
  26. ],
  27. ],
  28. 'sort_order' => 80,
  29. ];
  30. }
  31. }