Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
CollectionUpdater.php
Go to the documentation of this file.
1 <?php
8 
9 class CollectionUpdater implements \Magento\Framework\View\Layout\Argument\UpdaterInterface
10 {
14  protected $registryManager;
15 
19  public function __construct(\Magento\Framework\Registry $registryManager)
20  {
21  $this->registryManager = $registryManager;
22  }
23 
30  public function update($argument)
31  {
32  $order = $this->registryManager->registry('current_order');
33  if ($order) {
34  $argument->setOrderFilter($order->getId());
35  }
36  $argument->addOrderInformation(['increment_id']);
37 
38  return $argument;
39  }
40 }
$order
Definition: order.php:55
__construct(\Magento\Framework\Registry $registryManager)