【发布时间】:2017-12-15 22:03:30
【问题描述】:
我想在 Prestashop 中将产品功能添加到发送给客户的订单确认中。
在这种情况下,我们有 1.6.1.4 类/PaymentModule.php 文件,它向我们显示 产品名称 - 属性:属性值,例如 Nice Nike 鞋 - 尺寸:42强>.
我想扩展它以显示:
漂亮的耐克鞋 - 尺码:42
系列:Hyperdunk(作为特征系列和特征值Hyperdunk)
'name' => $product['name'].(isset($product['attributes']) ? ' - '.$product['attributes'] : ''),
所以我想添加新的模板变量,比如
'features' => $product['features'].(isset($product['features']) ? ' - '.$product['features'] : ''),
我也在 order_conf_product_list.tpl 中添加了
<td style="border:1px solid #D6D4D4;">
<table class="table">
<tr>
<td width="10"> </td>
<td>
<font size="2" face="Open-sans, sans-serif" color="#555454">
<strong>{$product['name']}</strong><br />{$product['features']}
</font>
</td>
<td width="10"> </td>
</tr>
</table>
</td>
但它不起作用......有什么想法吗?
编辑:启用调试模式后,我有 Array - Array 代替 {$product['features']} 变量
【问题讨论】:
标签: php prestashop prestashop-1.6