Example #1
0
 public function __construct(Context $context, StoreManagerInterface $storeManager, CustomerFactory $customerFactory, AddressFactory $addressFactory, Session $customerSession, ProductRepositoryInterface $productRepository, Cart $cart, Collection $merchantCollection, Application $application)
 {
     parent::__construct($context);
     $this->customerFactory = $customerFactory;
     $this->addressFactory = $addressFactory;
     $this->customerSession = $customerSession;
     $this->productRepository = $productRepository;
     $this->cart = $cart;
     $this->merchant = $merchantCollection->getItemById($storeManager->getWebsite()->getId())->getMerchant();
     $this->application = $application->getApp();
     $this->countryProvider = $this->application['country_code.provider'];
 }
Example #2
0
 public function __construct(ActionFactory $actionFactory, ResponseInterface $response, Application $application)
 {
     $this->actionFactory = $actionFactory;
     $this->response = $response;
     $this->application = $application->getApp();
 }