[-] BO : #PSFV-491 - Fixed problem with multishipping and summary cart
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@12458 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -53,7 +53,9 @@ function updateAddressesDisplay(first_view)
|
||||
|
||||
if ($('input[type=checkbox]#addressesAreEquals:checked').length == 1)
|
||||
{
|
||||
$('#address_invoice_form:visible').hide('fast');
|
||||
if ($('#multishipping_mode_checkbox:checked').length == 0) {
|
||||
$('#address_invoice_form:visible').hide('fast');
|
||||
}
|
||||
$('ul#address_invoice').html($('ul#address_delivery').html());
|
||||
$('ul#address_invoice li.address_title').html(txtInvoiceTitle);
|
||||
}
|
||||
|
||||
@@ -670,9 +670,11 @@ function multishippingMode(it)
|
||||
{
|
||||
if ($(it).attr('checked'))
|
||||
{
|
||||
$('#address_delivery').hide();
|
||||
$('#address_delivery, .address_delivery').hide();
|
||||
$('#address_invoice').removeClass('alternate_item').addClass('item');
|
||||
$('#multishipping_mode_box').addClass('on');
|
||||
$('.addressesAreEquals').hide();
|
||||
$('#address_invoice_form').show();
|
||||
|
||||
$('#link_multishipping_form').click(function() {return false;});
|
||||
|
||||
@@ -728,9 +730,15 @@ function multishippingMode(it)
|
||||
}
|
||||
else
|
||||
{
|
||||
$('#address_delivery').show();
|
||||
$('#address_delivery, .address_delivery').show();
|
||||
$('#address_invoice').removeClass('item').addClass('alternate_item');
|
||||
$('#multishipping_mode_box').removeClass('on');
|
||||
$('.addressesAreEquals').show();
|
||||
if ($('.addressesAreEquals').find('input:checked')) {
|
||||
$('#address_invoice_form').hide();
|
||||
} else {
|
||||
$('#address_invoice_form').show();
|
||||
}
|
||||
|
||||
// Disable multi address shipping
|
||||
$.ajax({
|
||||
@@ -758,6 +766,9 @@ $(document).ready(function() {
|
||||
// If the multishipping mode is off assure us the checkbox "I want to specify a delivery address for each products I order." is unchecked.
|
||||
$('#multishipping_mode_checkbox').attr('checked', false);
|
||||
// If the multishipping mode is on, check the box "I want to specify a delivery address for each products I order.".
|
||||
if (typeof(multishipping_mode) != 'undefined' && multishipping_mode)
|
||||
$('#multishipping_mode_checkbox').click()
|
||||
if (typeof(multishipping_mode) != 'undefined' && multishipping_mode) {
|
||||
$('#multishipping_mode_checkbox').click();
|
||||
$('.addressesAreEquals').hide();
|
||||
$('.addressesAreEquals').find('input').attr('checked', false);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -212,7 +212,7 @@
|
||||
|
||||
</select>
|
||||
</p>
|
||||
<p class="checkbox" {if $cart->isVirtualCart()}style="display:none;"{/if}>
|
||||
<p class="checkbox addressesAreEquals" {if $cart->isVirtualCart()}style="display:none;"{/if}>
|
||||
<input type="checkbox" name="same" id="addressesAreEquals" value="1" onclick="updateAddressesDisplay();{if $opc}updateAddressSelection();{/if}" {if $cart->id_address_invoice == $cart->id_address_delivery || $addresses|@count == 1}checked="checked"{/if} />
|
||||
<label for="addressesAreEquals">{l s='Use the same address for billing.'}</label>
|
||||
</p>
|
||||
|
||||
Reference in New Issue
Block a user