Remove address as required in booking/order flow

This commit is contained in:
Shreesh Arora
2023-11-20 16:01:54 +05:30
parent ce93a9826f
commit 7b938aa023
8 changed files with 52 additions and 86 deletions

View File

@@ -416,11 +416,12 @@ class FrontControllerCore extends Controller
$display_tax_label = $this->context->country->display_tax_label;
if (isset($cart->{Configuration::get('PS_TAX_ADDRESS_TYPE')}) && $cart->{Configuration::get('PS_TAX_ADDRESS_TYPE')}) {
$infos = Address::getCountryAndState((int)$cart->{Configuration::get('PS_TAX_ADDRESS_TYPE')});
$country = new Country((int)$infos['id_country']);
$this->context->country = $country;
if (Validate::isLoadedObject($country)) {
$display_tax_label = $country->display_tax_label;
if ($infos = Address::getCountryAndState((int)$cart->{Configuration::get('PS_TAX_ADDRESS_TYPE')})) {
$country = new Country((int)$infos['id_country']);
$this->context->country = $country;
if (Validate::isLoadedObject($country)) {
$display_tax_label = $country->display_tax_label;
}
}
}