diff --git a/controllers/front/AddressController.php b/controllers/front/AddressController.php index 490e361c6..432669a1a 100644 --- a/controllers/front/AddressController.php +++ b/controllers/front/AddressController.php @@ -237,7 +237,7 @@ class AddressControllerCore extends FrontController else // Update cart address $this->context->cart->autosetProductAddress(); - if (Tools::getValue('type') == 'invoice' && Configuration::get('PS_ORDER_PROCESS_TYPE')) + if ((bool)(Tools::getValue('select_address', false)) == true OR Tools::getValue('type') == 'invoice' && Configuration::get('PS_ORDER_PROCESS_TYPE')) { $this->context->cart->id_address_invoice = (int)$address->id; $this->context->cart->update(); diff --git a/themes/default/address.tpl b/themes/default/address.tpl index 1457760c1..7c33539ef 100644 --- a/themes/default/address.tpl +++ b/themes/default/address.tpl @@ -218,7 +218,7 @@ $(function(){ldelim}

- +

diff --git a/themes/default/shopping-cart.tpl b/themes/default/shopping-cart.tpl index e8ab9d46c..16fc04b4d 100644 --- a/themes/default/shopping-cart.tpl +++ b/themes/default/shopping-cart.tpl @@ -365,32 +365,32 @@ {if ((!empty($delivery_option) AND !isset($virtualCart)) OR $delivery->id OR $invoice->id) AND !$opc}

{if !isset($formattedAddresses) || (count($formattedAddresses.invoice) == 0 && count($formattedAddresses.delivery) == 0) || (count($formattedAddresses.invoice.formated) == 0 && count($formattedAddresses.delivery.formated) == 0)} - {if $delivery->id} - - {/if} - {if $invoice->id} - - {/if} + {if $delivery->id} + + {/if} + {if $invoice->id} + + {/if} {else} {foreach from=$formattedAddresses key=k item=address} {/foreach} -

+
{/if}

{/if}