Catalog.php 969 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. /**
  7. * Catalog price rules
  8. *
  9. * @author Magento Core Team <core@magentocommerce.com>
  10. */
  11. namespace Magento\CatalogRule\Block\Adminhtml\Promo;
  12. /**
  13. * @api
  14. * @since 100.0.2
  15. */
  16. class Catalog extends \Magento\Backend\Block\Widget\Grid\Container
  17. {
  18. /**
  19. * @return void
  20. */
  21. protected function _construct()
  22. {
  23. $this->_blockGroup = 'Magento_CatalogRule';
  24. $this->_controller = 'adminhtml_promo_catalog';
  25. $this->_headerText = __('Catalog Price Rule');
  26. $this->_addButtonLabel = __('Add New Rule');
  27. parent::_construct();
  28. $this->buttonList->add(
  29. 'apply_rules',
  30. [
  31. 'label' => __('Apply Rules'),
  32. 'onclick' => "location.href='" . $this->getUrl('catalog_rule/*/applyRules') . "'",
  33. 'class' => 'apply'
  34. ]
  35. );
  36. }
  37. }