Checkout workflow helper
Definition at line 13 of file Checkout.php.
◆ __construct()
- Parameters
-
\Magento\Checkout\Model\Session | $session | |
Definition at line 23 of file Checkout.php.
◆ cancelCurrentOrder()
cancelCurrentOrder |
( |
|
$comment | ) |
|
Cancel last placed order with specified comment message
- Parameters
-
string | $comment | Comment appended to order history |
- Returns
- bool True if order cancelled, false otherwise
Definition at line 35 of file Checkout.php.
37 $order = $this->session->getLastRealOrder();
39 $order->registerCancellation($comment)->save();
◆ restoreQuote()
Restores quote
- Returns
- bool
Definition at line 50 of file Checkout.php.
52 return $this->session->restoreQuote();
◆ $session
The documentation for this class was generated from the following file: