Marmulet
Members-
Posts
19 -
Joined
-
Last visited
Profile Information
-
Location
France
-
First Name
Guillaume
-
Last Name
ZIEGLER
Recent Profile Visitors
Marmulet's Achievements
-
Il faut que tu ajoutes la variable dans la classe Cart.php. Tu fais un override de la classe Cart.php. http://doc.prestashop.com/display/PS16/Overriding+default+behaviors Tu cherches : "pl.`available_later`," et tu ajoutes après : "IF(`pa`.id_product_attribute is null,p.`available_date`,pa.`available_date`) as available_date," La variable devient disponible et tu peux donc l'utiliser dans le thème.
-
Déclinaisons - Google Shopping - Structured Data
Marmulet replied to Marmulet's topic in PrestaShop pour les développeurs
J'avoue je suis en train de faire encore des modifications. J'ai du mal à satisfaire Google complètement. Il me reste encore des problèmes sur certains prix aussi donc il s'agit toujours d'un version Beta {if !isset($groups)} {if !$product->is_virtual && $product->condition} {if $product->condition == 'new'} <link itemprop="itemCondition" href="https://schema.org/NewCondition"/> {elseif $product->condition == 'used'} <link itemprop="itemCondition" href="https://schema.org/UsedCondition"/> {elseif $product->condition == 'refurbished'} <link itemprop="itemCondition" href="https://schema.org/RefurbishedCondition"/> {/if} {/if} {/if} <!--EAN13--> {if $product->ean13} <p id="product_ean13"> <label>{l s='EAN'} </label> <span class="editable" {if !isset($groups)}itemprop="gtin13"{/if} content="{$product->ean13}">{if !isset($groups)}{$product->ean13|escape:'html':'UTF-8'}{/if}</span> </p> {/if} <p class="our_price_display" {if !isset($groups)}itemprop="offers" itemscope itemtype="https://schema.org/Offer"{/if}>{strip} {if !isset($groups)}{if $product->quantity > 0}<link itemprop="availability" href="https://schema.org/InStock"/>{/if}{/if} {if $priceDisplay >= 0 && $priceDisplay <= 2} <span id="our_price_display" class="price" {if !isset($groups)}itemprop="price"{/if} content="{$productPrice}">{convertPrice price=$productPrice|floatval}</span> {if $tax_enabled && ((isset($display_tax_label) && $display_tax_label == 1) || !isset($display_tax_label))} {if $priceDisplay == 1} {l s='tax excl.'}{else} {l s='tax incl.'}{/if} {/if} {if !isset($groups)}<meta itemprop="priceCurrency" content="{$currency->iso_code}" />{/if} {hook h="displayProductPriceBlock" product=$product type="price"} {/if} {/strip} </p> <!-- Block Variations --> {if isset($groups)} <section id="variations" class="page-product-box"> <h2 class="page-product-heading">{l s='Déclinaisons'} {$product->name|escape:'html':'UTF-8'}{if !(stripos(strtoupper($product->name),strtoupper($product->manufacturer_name)) !== FALSE)} {$product->manufacturer_name|escape:'html':'UTF-8'}{/if}</h2> <div class="table-responsive"> <table border="1" class="table"> <thead> <!-- En-tête du tableau --> <tr> <th>{l s='Réference'}</th> {foreach from=$groups item='attributearray' key='groupindex'} <th>{$attributearray.name}</th> {/foreach} <th>{l s='Nom'}</th> <th>{l s='Prix'}</th> {if !empty($product->ean13)}<th>{l s='EAN'}</th>{/if} </tr> <tbody> <!-- Corps du tableau --> {foreach from=$combinations item='combination' key='combinationId'} <tr itemscope itemtype="https://schema.org/Product"> <td itemprop="model">{$combination.reference}</td> {foreach from=$combination.attributes_values item='a' key='groupindex'} <td>{$a}</td> {/foreach} <td itemprop="name">[spam-filter]$product->name|escape:'html':'UTF-8'[spam-filter]{foreach from=$combination.attributes_values item='a' key='groupindex'} {$a}{/foreach}</td> {if $priceDisplay >= 0 && $priceDisplay <= 2} <td itemprop="offers" itemscope itemtype="https://schema.org/Offer"> {if $combination.price != 0} {if isset($combination.specific_price.reduction_type)} {if $combination.specific_price.reduction_type==amount} <span itemprop="price" content="{($combination.price * ($tax_rate/100 + 1)) + $productPrice - $combination.specific_price.reduction}"">{convertPrice price=($combination.price * ($tax_rate/100 + 1)) + $productPrice - $combination.specific_price.reduction}</span> {elseif $combination.specific_price.reduction_type==percentage} <span itemprop="price" content="{(($combination.price * ($tax_rate/100 + 1)) + $productPrice)* (1-$combination.specific_price.reduction)}"">{convertPrice price=(($combination.price * ($tax_rate/100 + 1)) + $productPrice) * (1-$combination.specific_price.reduction)}</span> {/if} {else} <span itemprop="price" content="{($combination.price * ($tax_rate/100 + 1)) + $productPrice}"">{convertPrice price=($combination.price * ($tax_rate/100 + 1)) + $productPrice}</span> {/if} {else} {if isset($combination.specific_price.reduction_type)} {if $combination.specific_price.reduction_type==amount} <span itemprop="price" content="{$productPrice - $combination.specific_price.reduction}">{convertPrice price=($productPrice - $combination.specific_price.reduction)}</span> {elseif $combination.specific_price.reduction_type==percentage} <span itemprop="price" content="{$productPrice*(1-$combination.specific_price.reduction)}">{convertPrice price=($productPrice* (1-$combination.specific_price.reduction))}</span> {/if} {else} <span itemprop="price" content="{$productPrice}">{convertPrice price=$productPrice}</span> {/if} {/if} {if $combination.quantity > 0}<link itemprop="availability" href="https://schema.org/InStock"/>{/if} <link itemprop="itemCondition" href="https://schema.org/NewCondition"/> </td> {/if} {if !empty($product->ean13)}<td itemprop="gtin13">{if !empty($combination.ean13)}{$combination.ean13}{/if}</td>{/if} </tr> {/foreach} </tbody> </thead> </table> </div> </section> {/if} <!-- /Block Variations --> -
Déclinaisons - Google Shopping - Structured Data
Marmulet replied to Marmulet's topic in PrestaShop pour les développeurs
Je confirme Google est passé et ça se confirme. Cela fonctionne parfaitement ;-) -
Déclinaisons - Google Shopping - Structured Data
Marmulet replied to Marmulet's topic in PrestaShop pour les développeurs
Dernière version avec les Structured Data en plus. Je n'ai pas d'erreurs quand j'utilise l'outils de test. J'attends le retour du bot de Google Shopping dans quelques jours. <!-- Block Variations --> {if isset($groups)} <section id="variations" class="page-product-box"> <h2 class="page-product-heading">{l s='Déclinaisons'} {$product->name|escape:'html':'UTF-8'}{if !(stripos(strtoupper($product->name),strtoupper($product->manufacturer_name)) !== FALSE)} {$product->manufacturer_name|escape:'html':'UTF-8'}{/if}</h2> <div class="table-responsive"> <table border="1" class="table"> <thead> <!-- En-tête du tableau --> <tr> <th>{l s='Réference'}</th> {foreach from=$groups item='attributearray' key='groupindex'} <th>{$attributearray.name}</th> {/foreach} <th>{l s='Nom'}</th> <th>{l s='Prix'}</th> {if !empty($product->ean13)}<th>{l s='EAN'}</th>{/if} </tr> <tbody> <!-- Corps du tableau --> {foreach from=$combinations item='combination' key='combinationId'} <tr itemscope itemtype="https://schema.org/Product"> <td itemprop="sku">{$combination.reference}</td> {foreach from=$combination.attributes_values item='a' key='groupindex'} <td>{$a}</td> {/foreach} <td itemprop="name">{$product->name|escape:'html':'UTF-8'}{foreach from=$combination.attributes_values item='a' key='groupindex'} {$a}{/foreach}</td> {if $priceDisplay >= 0 && $priceDisplay <= 2} {if $combination.price != 0} <td itemprop="offers" itemscope itemtype="https://schema.org/Offer"> <span itemprop="price" content="{($combination.price * ($tax_rate/100 + 1)) + $productPrice}"">{convertPrice price=($combination.price * ($tax_rate/100 + 1)) + $productPrice}</span></td> {else} <td itemprop="offers" itemscope itemtype="https://schema.org/Offer"> <span itemprop="price" content="{$productPrice}">{convertPrice price=$productPrice}</span></td> {/if} {/if} {if !empty($product->ean13)}<td itemprop="gtin13">{if !empty($combination.ean13)}{$combination.ean13}{/if}</td>{/if} </tr> {/foreach} </tbody> </thead> </table> </div> </section> {/if} <!-- /Block Variations --> -
Déclinaisons - Google Shopping - Structured Data
Marmulet replied to Marmulet's topic in PrestaShop pour les développeurs
Il faut remplir l'EAN du produit ou enlever la condition (2 fois) : {if !empty($product->ean13)} -
Déclinaisons - Google Shopping - Structured Data
Marmulet replied to Marmulet's topic in PrestaShop pour les développeurs
Comme je disais, j'ai ajouté un tableau avec les déclinaisons : référence, prix , valeurs des variations, EAN. Il suffit de modifier le product.tpl <!-- Block Variations --> {if isset($groups)} <section id="variations" class="page-product-box"> <h2 class="page-product-heading">{l s='Déclinaisons'} {$product->name|escape:'html':'UTF-8'}{if !(stripos(strtoupper($product->name),strtoupper($product->manufacturer_name)) !== FALSE)} {$product->manufacturer_name|escape:'html':'UTF-8'}{/if}</h2> <div class="table-responsive"> <table border="1" class="table"> <thead> <!-- En-tête du tableau --> <tr> <th>Réference</th> {foreach from=$groups item='attributearray' key='groupindex'} <th>{$attributearray.name}</th> {/foreach} <th>Prix</th> {if !empty($product->ean13)}<th>EAN</th>{/if} </tr> <tbody> <!-- Corps du tableau --> {foreach from=$combinations item='combination' key='combinationId'} <tr> <td>{$combination.reference}</td> {foreach from=$combination.attributes_values item='a' key='groupindex'} <td>{$a}</td> {/foreach} {if $priceDisplay >= 0 && $priceDisplay <= 2} {if $combination.price != 0} <td>{convertPrice price=($combination.price * ($tax_rate/100 + 1)) + $productPrice}</td> {else} <td>{convertPrice price=$productPrice}</td> {/if} {/if} {if !empty($product->ean13)}<td>{if !empty($combination.ean13)}{$combination.ean13}{/if}</td>{/if} </tr> {/foreach} </tbody> </thead> </table> </div> </section> {/if} <!-- /Block Variations --> L'idéal serait d'ajouter les structured data aux déclinaisons. En effet, cela évite que mes produits soient refusés mais les prix ne sont pas mis à jour automatiquement. -
Déclinaisons - Google Shopping - Structured Data
Marmulet replied to Marmulet's topic in PrestaShop pour les développeurs
J'ai ajouté un tableau des déclinaisons sur les pages produits concernées. On va voir si cela fonctionne. Allez Google, soit sympa ;-) -
Bonjour à tous, J'ai décidé d'utiliser les déclinaisons dans Google Shopping (Merchant Center) mais je rencontre un problème lié au structured data. Je prends un exemple avec l'url suivante : http://equi-clic.com/fr/articulations/2729-ekyflex-arthro-3515650660667.html#/107-conditionnement-14_kg Le problème c'est que je communique à Google un tarif de 1168€ TTC mais quand il vient chercher la page il trouve le tarif de base et non le tarif de de la déclinaison ce qui ne lui convient pas du tout. Il exclut donc toutes mes déclinaisons. Si j'utilise l'outils de test des Structured Data de Google, je n'ai pas le bon prix : https://developers.google.com/structured-data/testing-tool?url=http%253A%252F%252Fequi-clic.com%252Ffr%252Farticulations%252F2729-ekyflex-arthro-3515650660667.html%2523%252F107-conditionnement-14_kg Google trouve les données du produit de base et non de la déclinaison :-( J'imagine que tout le monde doit être concerné par ce problème. Avez-vous une idée ? Merci d'avance.
-
afficher ean13 (code barre) sur fiche produit
Marmulet replied to mistertendance's topic in PrestaShop pour les développeurs
Tout bêtement, je n'avais pas vidé le cache ! Cela pourra servir pour ceux qui voudront le mettre en place sur prestashop 1.6. -
afficher ean13 (code barre) sur fiche produit
Marmulet replied to mistertendance's topic in PrestaShop pour les développeurs
Je remercie tout le monde pour votre aide précieuse. Malheureusement il y a eu quelques changements sur Prestashop 1.6 et je n'arrive pas à mettre à jour l'EAN selon les déclinaisons. J'ai réalisé les modification suivantes : - dans Product.php, à la fonction getAttributesGroups j'ai remplacé pa.`reference`, par pa.`reference`,pa.`ean13`, - dans product.tpl, j'ai ajouté {if $product->ean13} <p id="product_ean13"> <label>{l s='EAN'} </label> <span class="editable" itemprop="gtin13" content="{$product->ean13}">{if !isset($groups)}{$product->ean13|escape:'html':'UTF-8'}{/if}</span> </p> {/if} et {addJsDef productEan13=$product->ean13|escape:'html':'UTF-8'} - dans ProductController.php, j'ai modifié la fonction assignAttributesGroups() en ajoutant : $combinations[$row['id_product_attribute']]['ean13'] = $row['ean13']; - dans product.js, j'ai ajouté : combinationsJS[k]['ean13'] = combinations[i]['ean13']; dans la fonction addCombination, j'ai remplacé reference, par reference, ean13, et ajouter combination['ean13'] = ean13; dans la fonction findCombination, j'ai ajouté : selectedCombination['ean13'] = combination['ean13']; dans la fonction updateDisplay, j'ai ajouté : if (selectedCombination['ean13'] || productEan13) { if (selectedCombination['ean13']) $('#product_ean13 span').text(selectedCombination['ean13']); else if (productEan13) $('#product_ean13 span').text(productEan13); $('#product_ean13:hidden').show('slow'); } else $('#product_ean13:visible').hide('slow'); Je ne pense pas être tout seul dans cette situation. Je croise les doigts en espérant que quelqu'un a la solution ;-) -
Pour information, la version avec itemprop="brand" fonctionne très bien pour le texte enrichie. Les 2 méthodes fonctionnent. La première nécessite moins de code html. Cette modification n'est donc pas nécessaire. https://developers.google.com/structured-data/testing-tool?url=http%253A%252F%252Fequi-clic.com%252Ffr%252Fsulky%252F2590-sulky-rc6000-acier.html
-
PHP Warning when manually adding orders from BO
Marmulet replied to zanpo's topic in Ecommerce x PrestaShop [ARCHIVE BOARD]
I have the same problem and I have Nginx too. -
module a facette
Marmulet replied to valetco's topic in Utilisation de PrestaShop : configuration et difficultés
Tu peux résoudre le bug en appliquant ce patch : https://github.com/PrestaShop/blocklayered/pull/88 -
Bonjour, J'ai l'impression que tu as résolu ton problème et j'ai exactement le même. Pourrais-tu partager la solution ? En te remerciant d'avance. FINALEMENT J'ai trouvé d'où vient le problème. Le problème vient du module Block Layered. Il y a une solution : https://github.com/PrestaShop/blocklayered/pull/88