I'm trying to change the functionality of Ship button when you choose an order.
The only thing that I have found so far is this file under /vendor/magento/module-sales/Block/Adminhtml/Order/View.php:
I see this part where the button has an onclick method:
$this->addButton(
'order_ship',
[
'label' => __('Ship'),
'onclick' => 'setLocation(\'' . $this->getShipUrl() . '\')',
'class' => 'ship'
]
);
and then this is the URL
public function getShipUrl()
{
return $this->getUrl('adminhtml/order_shipment/start');
}
I don't know if that url is a controller, I have not found a route with that id nor that exactly path. Or maybe it's an api? This is the url that is shown on backend when I inspect
admin/order_shipment/start/order_id/60/key/ec0160f0fda15ac0271c4a0e1e2115471f7535673cc0e69f5c3af11deaba9ddf/'
Hope someone can give me a hint!
thanks
sales_order_shipment_save_after