ResetButton.php 692 B

1234567891011121314151617181920212223242526272829
  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 ResetButton
  12. */
  13. class ResetButton implements ButtonProviderInterface
  14. {
  15. /**
  16. * @return array
  17. */
  18. public function getButtonData()
  19. {
  20. return [
  21. 'label' => __('Reset'),
  22. 'class' => 'reset',
  23. 'on_click' => 'location.reload();',
  24. 'sort_order' => 30
  25. ];
  26. }
  27. }