Domyślnie prestashop działa na tej zasadzie że generuje kombinacje produktu w trybie każdy z każdym.
Jednak jeżeli generujemy kombinacje oddzielnie to nie są one od siebie zależne, więc tutaj pojawia się moje pytanie jak zmodyfikować kod przedstawiony niżej, aby kombinacje wyświetlały się niezależnie od siebie?
<div class="product-variants"> {foreach from=$groups key=id_attribute_group item=group} <div class="clearfix product-variants-item"> {if $group.group_type == 'select'} id="group_{$id_attribute_group}" data-product-attribute="{$id_attribute_group}" name="group[{$id_attribute_group}]"> {foreach from=$group.attributes key=id_attribute item=group_attribute} {/foreach} </select> {elseif $group.group_type == 'color'} <ul id="group_{$id_attribute_group}" class="aaa"> {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}"{if $group_attribute.selected} checked="checked"{/if}> <span {if $group_attribute.html_color_code}class="color" style="background-color: {$group_attribute.html_color_code}" {/if} {if $group_attribute.texture}class="color texture" style="background-image: url({$group_attribute.texture})" {/if} </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 btn-{$id_attribute}"> <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}> </li> {/foreach} </ul> {/if} </div> {/foreach} </div>
Czyli gdy wyświetlam listę "select" i chcę aby nie powiązane opcje "radio" z w opcjach select się wyświetlały, nawet jak wspomniałem nie sa powiązane. Teraz działa to tak, że jak coś nie istnieje w powiązaniu z "select" to nie zostanie wygenerowane np. w opcji "radio"