Как я понимаю этот код нужно вписать в product.tpl
<div class="discount">
<?php foreach ($discounts as $discount) { ?>
<?php echo sprintf($text_discount, $discount['quantity'], $discount['price']); ?><br />
<?php } ?>
</div>
а так же в product.php
$data['text_discount'] = $this->language->get('text_discount');
и
$discounts = $this->model_catalog_product->getProductDiscounts($this->request->get['product_id']);
$data['discounts'] = array();
foreach ($discounts as $discount) {
$data['discounts'][] = array(
'quantity' => $discount['quantity'],
'price' => $this->currency->format($this->tax->calculate($discount['price'], $product_info['tax_class_id'], $this->config->get('config_tax')), $this->session->data['currency'])
);
}
Вставляю как написал, появляется ошибка PHP Notice: Undefined index: product_id in /catalog/controller/product/category.php on line 221
Подскажите как правильно нужно.