Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- namespace UVBestellungPlugin;
- class Buttons
- {
- public function beforePushButtons(
- MagentoBackendBlockWidgetButtonToolbarInterceptor $subject,
- MagentoFrameworkViewElementAbstractBlock $context,
- MagentoBackendBlockWidgetButtonButtonList $buttonList
- ) {
- $this->_request = $context->getRequest();
- if($this->_request->getFullActionName() == 'sales_order_view'){
- $buttonList->add(
- 'Bestellschein',
- ['label' => __('Bestellschein'), 'onclick' => 'alert("test");', 'class' => 'reset'],
- -1
- );
- }
- }
- }
- ?>
- <?php
- namespace UVBestellungControllerAdminhtmlOrder;
- class Custom extends MagentoSalesControllerAdminhtmlOrder
- {
- public function execute()
- {
- // my logic here
- }
- }
- ?>
Add Comment
Please, Sign In to add comment