Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
Resume.php
Go to the documentation of this file.
1 <?php
8 
10 {
16  public function execute()
17  {
18  $queue = $this->_objectManager->get(
19  \Magento\Newsletter\Model\Queue::class
20  )->load(
21  $this->getRequest()->getParam('id')
22  );
23 
24  if (!in_array($queue->getQueueStatus(), [\Magento\Newsletter\Model\Queue::STATUS_PAUSE])) {
25  $this->_redirect('*/*');
26  return;
27  }
28 
29  $queue->setQueueStatus(\Magento\Newsletter\Model\Queue::STATUS_SENDING);
30  $queue->save();
31 
32  $this->_redirect('*/*');
33  }
34 }
$queue
Definition: queue.php:21