95 $this->_isScopePrivate =
true;
98 $this->checkoutSession = $resourceSession;
101 parent::__construct($context,
$data);
113 [
'label' =>
__(
'Billing Information'),
'is_show' =>
true]
117 $this->
getCheckout()->setStepData(
'billing',
'allow',
true);
119 parent::_construct();
140 return $this->countryCollectionFactory->create()->loadByStore();
150 return $this->
getQuote()->getCheckoutMethod();
182 return !$this->
getQuote()->isVirtual();
199 if (!$this->taxvat) {
200 $this->taxvat = $this->
getLayout()->createBlock(\
Magento\Customer\Block\Widget\Taxvat::class);
222 ->setTaxvat($this->
getQuote()->getCustomerTaxvat())
223 ->setFieldIdFormat(
'billing:%s')
224 ->setFieldNameFormat(
'billing[%s]')
235 if ($this->address ===
null) {
237 $this->address = $this->
getQuote()->getBillingAddress();
238 if (!$this->address->getFirstname()) {
241 if (!$this->address->getLastname()) {
245 $this->address = $this->addressFactory->create();
260 return $this->_scopeConfig->getValue(
$path, \
Magento\
Store\Model\ScopeInterface::SCOPE_STORE);
270 if (empty($this->customer)) {
271 $this->customer = $this->customerRepository->getById($this->customerSession->getCustomerId());
293 if (empty($this->quote)) {
304 return $this->httpContext->getValue(\
Magento\Customer\Model\Context::CONTEXT_AUTH);
__construct(\Magento\Framework\View\Element\Template\Context $context, \Magento\Customer\Model\Session $customerSession, \Magento\Checkout\Model\Session $resourceSession, \Magento\Directory\Model\ResourceModel\Country\CollectionFactory $countryCollectionFactory, CustomerRepositoryInterface $customerRepository, \Magento\Framework\App\Http\Context $httpContext, \Magento\Quote\Model\Quote\AddressFactory $addressFactory, array $data=[])
$countryCollectionFactory
isUseBillingAddressForShipping()