Atout ads Posted December 9, 2021 Share Posted December 9, 2021 Bonjour, J'aimerai ajouter le numéro de suivi colis directement dans l'historique de commande via une nouvelle colonne sur le site d'un client. J'ai réussi à créer la colonne mais je ne parviens pas a faire remonter le numéro de suivi dans le bloc. Il doit manquer un truc dans les div ? Petite question au passage, mon bloc historique ne prend pas toute la largeur sur PC, savez-vous pourquoi ? Le est www.shopcoiffure.eu Version de presta 1.7.5 Voici mon fichier history.tpl, j'ai mis en gras les nouveaux champs. {block name='page_title'} {l s='Order history' d='Shop.Theme.Customeraccount'} {/block} {block name='page_content'} <p>{l s='Here are the orders you\'ve placed since your account was created.' d='Shop.Theme.Customeraccount'}</p> {if $orders} <table class="table table-bordered table-labeled hidden-sm-down"> <thead> <tr> <th>{l s='Order reference' d='Shop.Theme.Checkout'}</th> <th>{l s='Date' d='Shop.Theme.Checkout'}</th> <th>{l s='Total price' d='Shop.Theme.Checkout'}</th> <th class="hidden-md-down">{l s='Payment' d='Shop.Theme.Checkout'}</th> <th class="hidden-md-down">{l s='Status' d='Shop.Theme.Checkout'}</th> <th>{l s='Invoice' d='Shop.Theme.Checkout'}</th> <th>{l s='Tracking number' d='Shop.Theme.Checkout'}</th> <th> </th> </tr> </thead> <tbody> {foreach from=$orders item=order} <tr> <th scope="row">{$order.details.reference}</th> <td>{$order.details.order_date}</td> <td class="text-right">{$order.totals.total.value}</td> <td class="hidden-md-down">{$order.details.payment}</td> <td> <span class="badge badge-default {$order.history.current.contrast}" style="background-color:{$order.history.current.color}" > {$order.history.current.ostate_name} </span> </td> <td class="text-center hidden-md-down"> {if $order.details.invoice_url} <a href="{$order.details.invoice_url}"><i class="fto-file-pdf fs_lg"></i></a> {else} - {/if} </td> <td>{$line.tracking nofilter}</td> <td class="text-center order-actions"> <a href="{$order.details.details_url}" data-link-action="view-order-details" title="{l s='Details' d='Shop.Theme.Customeraccount'}" class="mar_r4"> {l s='Details' d='Shop.Theme.Customeraccount'} </a> {if $order.details.reorder_url} <a href="{$order.details.reorder_url}" title="{l s='Reorder' d='Shop.Theme.Actions'}">{l s='Reorder' d='Shop.Theme.Actions'}</a> {/if} </td> </tr> {/foreach} </tbody> </table> <div class="orders hidden-md-up base_list_line medium_list"> {foreach from=$orders item=order} <div class="order line_item flex_box"> <div class="flex_child"> <a href="{$order.details.details_url}" title="{$order.details.reference}" class="font-weight-bold">{$order.details.reference}</a> <div class="date">{$order.details.order_date}</div> <div class="total">{$order.totals.total.value}</div> <div>{$order.details.payment}</div> </div> <div class="text-right"> <div class="status"> <span class="badge badge-default {$order.history.current.contrast}" style="background-color:{$order.history.current.color}" > {$order.history.current.ostate_name} </span> </div> <a href="{$order.details.details_url}" data-link-action="view-order-details" title="{l s='Details' d='Shop.Theme.Customeraccount'}"> {l s='Details' d='Shop.Theme.Customeraccount'} </a> {if $order.details.reorder_url} <a href="{$order.details.reorder_url}" title="{l s='Reorder' d='Shop.Theme.Actions'}" class="mar_l6"> {l s='Reorder' d='Shop.Theme.Actions'} </a> {/if} </div> </div> {/foreach} </div> {/if} {/block} Merci par avance Anthony Link to comment Share on other sites More sharing options...
Atout ads Posted December 15, 2021 Author Share Posted December 15, 2021 Bonjour, Personne pour m'aider ? Link to comment Share on other sites More sharing options...
Mediacom87 Posted December 15, 2021 Share Posted December 15, 2021 Il faudrait déjà savoir si cette page reçoit cette données pour pouvoir l'afficher. Link to comment Share on other sites More sharing options...
Atout ads Posted December 16, 2021 Author Share Posted December 16, 2021 Bonjour, une astuce pour vous donner l'info ? Ce qui est sûr c'est que la page "Details de la commande" remonte cette info, l'idée étant que le client y accède plus simplement. Merci Link to comment Share on other sites More sharing options...
Natc77 Posted December 16, 2021 Share Posted December 16, 2021 Vous êtes sûr du nom $line.tracking ? Moi je suis en 1.7.6.1 et le numéro est dans deux tables, c'est soit shipping_number dans ps_orders, soit tracking_number dans ps_order_carrier 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