On 4/28/2020 at 7:48 PM, gusman126 said:Este modulo es lo que necesitas, es el que uso con mis clientes
https://www.sunnytoo.com/57773/show-combination-images-textures-free-prestashop-module
Se muestran en las cajas de colores las imagenes que tienes asociadas a las combinaciones.
Solo hay que asignar en cada combinación la imagen asociada, luego como puedes ver hay que hacer algun cambio en la plantilla
Yo tengo un problema con este, y es que al parecer mi plantilla no es como la estandar de prestashop, y no sé cómo modificar el codigo para poder añadirlo.. me podrías ayudar?
Mi codigo es este:
Quote<div class="product-variants js-product-variants">
{block name='product_reference'}
{if isset($product.reference_to_display) && $product.reference_to_display neq ''}
<div class="product-reference">
<label class="label">{l s='Reference' d='Shop.Theme.Catalog'}: </label>
<span itemprop="sku">{$product.reference_to_display}</span>
</div>
{/if}
{/block}{block name='product_quantities'}
{if $product.show_quantities}
<div class="product-quantities">
<label class="label">{l s='Available In Stock: ' d='Shop.Theme.Catalog'}</label>
<span data-stock="{$product.quantity}" data-allow-oosp="{$product.allow_oosp}">{$product.quantity} {$product.quantity_label}</span>
</div>
{/if}
{/block}{foreach from=$groups key=id_attribute_group item=group}
{if !empty($group.attributes)}
<div class="clearfix product-variants-item">
<span class="control-label">{$group.name}{l s=': ' d='Shop.Theme.Catalog'}
{foreach from=$group.attributes key=id_attribute item=group_attribute}
{if $group_attribute.selected}{$group_attribute.name}{/if}
{/foreach}
</span>
{if $group.group_type == 'select'}
<select
class="form-control form-control-select"
id="group_{$id_attribute_group}"
aria-label="{$group.name}"
data-product-attribute="{$id_attribute_group}"
name="group[{$id_attribute_group}]">
{foreach from=$group.attributes key=id_attribute item=group_attribute}
<option value="{$id_attribute}" title="{$group_attribute.name}"{if $group_attribute.selected} selected="selected"{/if}>{$group_attribute.name}</option>
{/foreach}
</select>
{elseif $group.group_type == 'color'}
<ul id="group_{$id_attribute_group}">
{foreach from=$group.attributes key=id_attribute item=group_attribute}
<li class="pull-xs-left input-container">
<input class="input-color" type="radio" data-product-attribute="{$id_attribute_group}" name="group[{$id_attribute_group}]" value="{$id_attribute}" title="{$group_attribute.name}"{if $group_attribute.selected} checked="checked"{/if}>
<span
{if $group_attribute.texture}
class="color texture" style="background-image: url({$group_attribute.texture})"
{elseif $group_attribute.html_color_code}
class="color" style="background-color: {$group_attribute.html_color_code}"
{/if}
><span class="attribute-name sr-only">{$group_attribute.name}</span></span>
</li>
{/foreach}
</ul>
{elseif $group.group_type == 'radio'}
<ul id="group_{$id_attribute_group}">
{foreach from=$group.attributes key=id_attribute item=group_attribute}
<li class="input-container pull-xs-left">
<input class="input-radio" type="radio" data-product-attribute="{$id_attribute_group}" name="group[{$id_attribute_group}]" value="{$id_attribute}"{if $group_attribute.selected} checked="checked"{/if}>
<span class="radio-label">{$group_attribute.name}</span>
</li>
{/foreach}
</ul>
{/if}
</div>
{/if}
{/foreach}
</div>