ViewCart.php 679 B

123456789101112131415161718192021222324
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Customer\Controller\Adminhtml\Index;
  7. class ViewCart extends \Magento\Customer\Controller\Adminhtml\Index
  8. {
  9. /**
  10. * Get shopping cart to view only
  11. *
  12. * @return \Magento\Framework\View\Result\Layout
  13. */
  14. public function execute()
  15. {
  16. $this->initCurrentCustomer();
  17. $resultLayout = $this->resultLayoutFactory->create();
  18. $resultLayout->getLayout()->getBlock('admin.customer.view.cart')->setWebsiteId(
  19. (int)$this->getRequest()->getParam('website_id')
  20. );
  21. return $resultLayout;
  22. }
  23. }