// Merging multishipping branche on 1.5
This commit is contained in:
@@ -48,7 +48,7 @@
|
||||
|
||||
"customizedDatas":[
|
||||
{if isset($blockcart_customizedDatas.$productId.$productAttributeId)}
|
||||
{foreach from=$blockcart_customizedDatas.$productId.$productAttributeId key='id_customization' item='customization' name='customizedDatas'}{ldelim}
|
||||
{foreach from=$blockcart_customizedDatas.$productId.$productAttributeId[$product.id_address_delivery] key='id_customization' item='customization' name='customizedDatas'}{ldelim}
|
||||
{* This empty line was made in purpose (product addition debug), please leave it here *}
|
||||
|
||||
"customizationId": {$id_customization},
|
||||
|
||||
@@ -76,7 +76,7 @@ var removingLinkText = '{l s='remove this product from my cart' mod='blockcart'
|
||||
{if isset($blockcart_customizedDatas.$productId.$productAttributeId)}
|
||||
{if !isset($product.attributes_small)}<dd id="cart_block_combination_of_{$product.id_product}{if $product.id_product_attribute}_{$product.id_product_attribute}{/if}" class="{if $smarty.foreach.myLoop.first}first_item{elseif $smarty.foreach.myLoop.last}last_item{else}item{/if}">{/if}
|
||||
<ul class="cart_block_customizations" id="customization_{$productId}_{$productAttributeId}">
|
||||
{foreach from=$blockcart_customizedDatas.$productId.$productAttributeId key='id_customization' item='customization' name='customizations'}
|
||||
{foreach from=$blockcart_customizedDatas.$productId.$productAttributeId[$product.id_address_delivery] key='id_customization' item='customization' name='customizations'}
|
||||
<li name="customization">
|
||||
<div class="deleteCustomizableProduct" id="deleteCustomizableProduct_{$id_customization|intval}_{$product.id_product|intval}_{$product.id_product_attribute|intval}"><a class="ajax_cart_block_remove_link" href="{$link->getPageLink('cart', true, NULL, "delete&id_product={$product.id_product|intval}&ipa={$product.id_product_attribute|intval}&id_customization={$id_customization}&token={$static_token}")}"> </a></div>
|
||||
<span class="quantity-formated"><span class="quantity">{$customization.quantity}</span>x</span>{if isset($customization.datas.$blockcart_CUSTOMIZE_TEXTFIELD.0)}
|
||||
@@ -142,7 +142,7 @@ var removingLinkText = '{l s='remove this product from my cart' mod='blockcart'
|
||||
{/if}
|
||||
<p id="cart-buttons">
|
||||
{capture name=step_order_process}
|
||||
{if $blockcart_order_process == 'order'}step=1{/if}
|
||||
{if $blockcart_order_process == 'order'}step=1{/if}
|
||||
{/capture}
|
||||
{if $blockcart_order_process == 'order'}<a href="{$link->getPageLink("$blockcart_order_process", true)}" class="button_small" title="{l s='Cart' mod='blockcart'}">{l s='Cart' mod='blockcart'}</a>{/if}
|
||||
<a href="{$link->getPageLink("$blockcart_order_process", true, NULL, "{$smarty.capture.step_order_process}")}" id="button_order_cart" class="exclusive{if $blockcart_order_process == 'order-opc'}_large{/if}" title="{l s='Check out' mod='blockcart'}">{l s='Check out' mod='blockcart'}</a>
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
*
|
||||
* @author PrestaShop SA <contact@prestashop.com>
|
||||
* @copyright 2007-2011 PrestaShop SA
|
||||
* @version Release: $Revision: 7096 $
|
||||
* @version Release: $Revision: 9532 $
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registred Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
@@ -52,16 +52,16 @@ $(document).ready(function()
|
||||
|
||||
// Click on label
|
||||
$('label a').live({
|
||||
click: function() {
|
||||
if($(this).parent().parent().find('input').attr('disabled') == '')
|
||||
click: function() {
|
||||
if ($(this).parent().parent().find('input').attr('disabled') == '')
|
||||
{
|
||||
$(this).parent().parent().find('input').click();
|
||||
reloadContent();
|
||||
$(this).parent().parent().find('input').click();
|
||||
reloadContent();
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
});
|
||||
return false;
|
||||
}
|
||||
});
|
||||
paginationButton();
|
||||
initLayered();
|
||||
});
|
||||
@@ -94,14 +94,6 @@ function initLayered()
|
||||
var params = window.location.href.split('#')[1];
|
||||
reloadContent('&selected_filters='+params);
|
||||
}
|
||||
}
|
||||
|
||||
function updatelink(link)
|
||||
{
|
||||
baseUrl = link.split('#');
|
||||
linkFilterUpdate = baseUrl[0]+getValueSelected();
|
||||
linkFilterUpdate = friendlyUrl(linkFilterUpdate, 'short');
|
||||
return linkFilterUpdate;
|
||||
}
|
||||
|
||||
function getValueSelected(){
|
||||
@@ -125,37 +117,6 @@ function getValueSelected(){
|
||||
return checkboxChecked;
|
||||
}
|
||||
|
||||
function friendlyUrl(link, encode)
|
||||
{
|
||||
var friendlyTab =
|
||||
{
|
||||
'layered_condition_' : 'cond_',
|
||||
'layered_id_attribute_group_' : 'g_',
|
||||
'id_category_layered=' : 'c=',
|
||||
'layered_manufacturer_' : 'm_',
|
||||
'layered_id_feature_' : 'f_',
|
||||
'layered_category_' : 'cat_',
|
||||
};
|
||||
|
||||
if(encode == 'short')
|
||||
{
|
||||
$.each(friendlyTab, function(key, value)
|
||||
{
|
||||
Expression = new RegExp(key,'g');
|
||||
link = link.replace(Expression, value);
|
||||
});
|
||||
}else
|
||||
{
|
||||
$.each(friendlyTab, function(key, value)
|
||||
{
|
||||
Expression = new RegExp(value,'g');
|
||||
link = link.replace(Expression, key);
|
||||
});
|
||||
}
|
||||
|
||||
return link;
|
||||
}
|
||||
|
||||
function paginationButton() {
|
||||
$('#pagination li').not('.current, .disabled').each( function () {
|
||||
var nbPage = 0;
|
||||
@@ -181,7 +142,7 @@ function cancelFilter()
|
||||
{
|
||||
$('#enabled_filters a').live('click', function(e)
|
||||
{
|
||||
if($(this).attr('rel').search(/_slider$/) > 0)
|
||||
if ($(this).attr('rel').search(/_slider$/) > 0)
|
||||
{
|
||||
$('#'+$(this).attr('rel')).slider('values' , 0, $('#'+$(this).attr('rel')).slider('option' , 'min' ));
|
||||
$('#'+$(this).attr('rel')).slider('values' , 1, $('#'+$(this).attr('rel')).slider('option' , 'max' ));
|
||||
@@ -189,8 +150,8 @@ function cancelFilter()
|
||||
}
|
||||
else
|
||||
{
|
||||
$('#'+$(this).attr('rel')).attr('checked', false);
|
||||
$('#layered_form input[name='+$(this).attr('rel')+']:hidden').remove();
|
||||
$('#'+$(this).attr('rel')).attr('checked', false);
|
||||
$('#layered_form input[name='+$(this).attr('rel')+']:hidden').remove();
|
||||
}
|
||||
reloadContent();
|
||||
e.preventDefault();
|
||||
@@ -224,7 +185,7 @@ function reloadContent(params_plus)
|
||||
|
||||
if (!ajaxLoaderOn)
|
||||
{
|
||||
$('#product_list').prepend($('#layered_ajax_loader').html());
|
||||
$('#product_list').prepend($('#layered_ajax_loader').html());
|
||||
$('#product_list').css('opacity', '0.7');
|
||||
ajaxLoaderOn = 1;
|
||||
}
|
||||
@@ -233,7 +194,7 @@ function reloadContent(params_plus)
|
||||
$('.layered_slider').each( function () {
|
||||
var sliderStart = $(this).slider('values', 0);
|
||||
var sliderStop = $(this).slider('values', 1);
|
||||
if(typeof(sliderStart) == 'number' && typeof(sliderStop) == 'number')
|
||||
if (typeof(sliderStart) == 'number' && typeof(sliderStop) == 'number')
|
||||
data += '&'+$(this).attr('id')+'='+sliderStart+'_'+sliderStop;
|
||||
});
|
||||
|
||||
@@ -244,7 +205,7 @@ function reloadContent(params_plus)
|
||||
}
|
||||
|
||||
var slideUp = true;
|
||||
if(params_plus == undefined)
|
||||
if (params_plus == undefined)
|
||||
{
|
||||
params_plus = '';
|
||||
slideUp = false;
|
||||
@@ -267,7 +228,7 @@ function reloadContent(params_plus)
|
||||
{
|
||||
$('#layered_block_left').after('<div id="tmp_layered_block_left"></div>').remove();
|
||||
$('#tmp_layered_block_left').html(result.filtersBlock).attr('id', 'layered_block_left');
|
||||
|
||||
|
||||
$('.category-product-count').html(result.categoryCount);
|
||||
|
||||
$('#product_list').replaceWith(result.productList);
|
||||
@@ -290,7 +251,7 @@ function reloadContent(params_plus)
|
||||
return false;
|
||||
});
|
||||
if (typeof(ajaxCart) != "undefined")
|
||||
ajaxCart.overrideButtonsInThePage();
|
||||
ajaxCart.overrideButtonsInThePage();
|
||||
|
||||
if (typeof(reloadProductComparison) == 'function')
|
||||
reloadProductComparison();
|
||||
@@ -314,7 +275,7 @@ function reloadContent(params_plus)
|
||||
});
|
||||
if (current_friendly_url == '#')
|
||||
current_friendly_url = '#/';
|
||||
window.location = current_friendly_url;
|
||||
window.location = current_friendly_url;
|
||||
lockLocationChecking = true;
|
||||
|
||||
if(slideUp)
|
||||
@@ -339,7 +300,7 @@ function initLocationChange(func, time)
|
||||
|
||||
lockLocationChecking = true;
|
||||
reloadContent('&selected_filters='+getUrlParams().replace(/^#/, ''));
|
||||
}
|
||||
}
|
||||
else {
|
||||
lockLocationChecking = false;
|
||||
current_friendly_url = getUrlParams();
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
*
|
||||
* @author PrestaShop SA <contact@prestashop.com>
|
||||
* @copyright 2007-2011 PrestaShop SA
|
||||
* @version Release: $Revision: 7310 $
|
||||
* @version Release: $Revision: 9528 $
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registred Trademark & Property of PrestaShop SA
|
||||
*}
|
||||
@@ -72,7 +72,7 @@ param_product_url = '#{$param_product_url}';
|
||||
{if isset($filter.slider)}
|
||||
<div class="layered_{$filter.type}" style="display: none;">
|
||||
{else}
|
||||
<div>
|
||||
<div>
|
||||
{/if}
|
||||
<span class="layered_subtitle">{$filter.name|escape:html:'UTF-8'}</span>
|
||||
<span class="layered_close"><a href="#" rel="ul_layered_{$filter.type}_{$filter.id_key}">v</a></span>
|
||||
@@ -85,39 +85,40 @@ param_product_url = '#{$param_product_url}';
|
||||
<input type="button" name="layered_{$filter.type_lite}_{$id_value}" rel="{$id_value}_{$filter.id_key}" id="layered_id_attribute_group_{$id_value}" {if !$value.nbr} value="X" disabled="disabled"{/if} style="background: {if isset($value.color)}{$value.color}{else}#CCC{/if}; margin-left: 0; width: 16px; height: 16px; padding:0; border: 1px solid {if isset($value.checked) && $value.checked}red{else}#666{/if};" />
|
||||
{if isset($value.checked) && $value.checked}<input type="hidden" name="layered_{$filter.type_lite}_{$id_value}" value="{$id_value}" />{/if}
|
||||
{else}
|
||||
<input type="checkbox" class="checkbox" name="layered_{$filter.type_lite}_{$id_value}" id="layered_{$filter.type_lite}{if $id_value || $filter.type == 'quantity'}_{$id_value}{/if}" value="{$id_value}{if $filter.id_key}_{$filter.id_key}{/if}"{if isset($value.checked)} checked="checked"{/if}{if !$value.nbr} disabled="disabled"{/if} />
|
||||
{/if}
|
||||
<label for="layered_{$filter.type_lite}_{$id_value}"{if !$value.nbr} class="disabled"{else}{if isset($filter.is_color_group) && $filter.is_color_group} name="layered_{$filter.type_lite}_{$id_value}" class="layered_color" rel="{$id_value}_{$filter.id_key}"{/if}{/if}>
|
||||
{if !$value.nbr}
|
||||
{$value.name|escape:html:'UTF-8'}{if $layered_show_qties}<span> (0)</span>{/if}</a>
|
||||
{else}
|
||||
<a href="{$value.link}" rel="{$value.rel}">{$value.name|escape:html:'UTF-8'}{if $layered_show_qties}<span> ({$value.nbr})</span>{/if}</a></label>
|
||||
{/if}
|
||||
<input type="checkbox" class="checkbox" name="layered_{$filter.type_lite}_{$id_value}" id="layered_{$filter.type_lite}{if $id_value || $filter.type == 'quantity'}_{$id_value}{/if}" value="{$id_value}{if $filter.id_key}_{$filter.id_key}{/if}"{if isset($value.checked)} checked="checked"{/if}{if !$value.nbr} disabled="disabled"{/if} />
|
||||
{/if}
|
||||
<label for="layered_{$filter.type_lite}_{$id_value}"{if !$value.nbr} class="disabled"{else}{if isset($filter.is_color_group) && $filter.is_color_group} name="layered_{$filter.type_lite}_{$id_value}" class="layered_color" rel="{$id_value}_{$filter.id_key}"{/if}{/if}>
|
||||
{if !$value.nbr}
|
||||
{$value.name|escape:html:'UTF-8'}{if $layered_show_qties}<span> (0)</span>{/if}</a>
|
||||
{else}
|
||||
<a href="{$value.link}" rel="{$value.rel}">{$value.name|escape:html:'UTF-8'}{if $layered_show_qties}<span> ({$value.nbr})</span>{/if}</a>
|
||||
{/if}
|
||||
</label>
|
||||
</li>
|
||||
{/foreach}
|
||||
{else}
|
||||
<label for="{$filter.type}">{l s='Range:'}</label> <span id="layered_{$filter.type}_range"></span>
|
||||
<div style="margin: 6px 0 6px 6px; width: 93%;">
|
||||
<div style="margin-top:5px;" class="layered_slider" id="layered_{$filter.type}_slider"></div>
|
||||
<div style="margin-top:5px;" class="layered_slider" id="layered_{$filter.type}_slider"></div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
{literal}
|
||||
addSlider('{/literal}{$filter.type}{literal}',{
|
||||
range: true,
|
||||
min: {/literal}{$filter.min}{literal},
|
||||
max: {/literal}{$filter.max}{literal},
|
||||
values: [ {/literal}{$filter.values[0]}{literal}, {/literal}{$filter.values[1]}{literal}],
|
||||
slide: function( event, ui ) {
|
||||
$('#layered_{/literal}{$filter.type}{literal}_range').html(ui.values[ 0 ] + '{/literal}{$filter.unit}{literal}' + ' - ' + ui.values[ 1 ] + '{/literal}{$filter.unit}{literal}');
|
||||
},
|
||||
stop: function () {
|
||||
reloadContent();
|
||||
}
|
||||
range: true,
|
||||
min: {/literal}{$filter.min}{literal},
|
||||
max: {/literal}{$filter.max}{literal},
|
||||
values: [ {/literal}{$filter.values[0]}{literal}, {/literal}{$filter.values[1]}{literal}],
|
||||
slide: function( event, ui ) {
|
||||
$('#layered_{/literal}{$filter.type}{literal}_range').html(ui.values[ 0 ] + '{/literal}{$filter.unit}{literal}' + ' - ' + ui.values[ 1 ] + '{/literal}{$filter.unit}{literal}');
|
||||
},
|
||||
stop: function () {
|
||||
reloadContent();
|
||||
}
|
||||
}, '{/literal}{$filter.unit}{literal}');
|
||||
$(document).ready(function()
|
||||
{
|
||||
$('.layered_{/literal}{$filter.type}{literal}').show();
|
||||
});
|
||||
});
|
||||
{/literal}
|
||||
</script>
|
||||
{/if}
|
||||
|
||||
@@ -48,8 +48,8 @@
|
||||
- {l s='The total amount of your order is' mod='cheque'}
|
||||
<span id="amount" class="price">{displayPrice price=$total}</span>
|
||||
{if $use_taxes == 1}
|
||||
{l s='(tax incl.)' mod='cheque'}
|
||||
{/if}
|
||||
{l s='(tax incl.)' mod='cheque'}
|
||||
{/if}
|
||||
</p>
|
||||
<p>
|
||||
-
|
||||
|
||||
Reference in New Issue
Block a user