Magento Native supports multiple Sessions type for frontend and backend (adminhtml) system.
You can get admin Html(backend) quote session using Magento 2 by Magento\Backend\Model\Session\Quote class.
Quote Class is responsible for getting Back end quote in Magento 2 admin panel order processes.
<?php namespace Jesadiya\BackendQuoteSession\Model; use Magento\Quote\Model\Quote; use Magento\Backend\Model\Session\Quote as AdminCheckoutSession; class BackendQuoteSession { /** * @var AdminCheckoutSession */ private $adminCheckoutSession; public function __construct( AdminCheckoutSession $adminCheckoutSession ) { $this->adminCheckoutSession = $adminCheckoutSession; } /** * Returns the Quote object made in adminpanel area * * @return Quote */ public function getCurrentAdminQuote(): Quote { $quote = $this->adminCheckoutSession->getQuote(); return $quote; } }
You can get Backend quote using the above function and fetch quote related data.
You can fetch current quote items, quote id, extension attributes related data.