CENIN Posted September 17, 2012 Share Posted September 17, 2012 Bonjour a tous, Je cherche desesperement a remplacer les menus deroulants qui gere les attributs de mes declinaisons dans ma fiche produit par des palettes couleurs comme celle que propose PrestaShop mais que pour un seul attribut alors que moi j en ai 3 Pour info : PrestaShop genere un doublon car la palette est generee egalement en menu deroulant Link to comment Share on other sites More sharing options...
CENIN Posted September 24, 2012 Author Share Posted September 24, 2012 (edited) Bonjour, j ai un peu avancé mais pas progressé :rolleyes: :rolleyes: pour mon probleme j essaye de fusionner, mixer cette boucle <div id="color_picker"> <p>{l s='Pick a color:' js=1}</p> <div class="clear"></div> <ul id="color_to_pick_list"> {foreach from=$colors key='id_attribute' item='color'} <li><a id="color_{$id_attribute|intval}" class="color_pick" style="background: {$color.value};" onclick="updateColorSelect({$id_attribute|intval});$('#wrapResetImages').show('slow');" title="{$color.name}">{if file_exists($col_img_dir|cat:$id_attribute|cat:'.jpg')}<img src="{$img_col_dir}{$id_attribute}.jpg" alt="{$color.name}" width="20" height="20" />{/if}</a></li> {/foreach} </ul> <div class="clear"></div> </div> avec cette boucle <!-- attributes --> <div id="attributes"> {foreach from=$groups key=id_attribute_group item=group} {if $group.attributes|@count} <p> <label for="group_{$id_attribute_group|intval}">{$group.name|escape:'htmlall':'UTF-8'} :</label> {assign var="groupName" value="group_$id_attribute_group"} <select name="{$groupName}" id="group_{$id_attribute_group|intval}" onchange="javascript:findCombination();{if $colors|@count > 0}$('#wrapResetImages').show('slow');{/if};"> {foreach from=$group.attributes key=id_attribute item=group_attribute} <option value="{$id_attribute|intval}"{if (isset($smarty.get.$groupName) && $smarty.get.$groupName|intval == $id_attribute) || $group.default == $id_attribute} selected="selected"{/if} title="{$group_attribute|escape:'htmlall':'UTF-8'}">{$group_attribute|escape:'htmlall':'UTF-8'}</option> {/foreach} mais sans aucun succes pour l instant ... Merci d avance de votre aide Edited September 24, 2012 by CENIN (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now