我希望找到的是从具有组合产品显示基价一个智者变量。这些组合可以或者可以不影响基本价格。我能找到包含组合的数组,它包含价格的“价格影响”的中$combinations
变量,但由于某种原因在调试窗口,我找不到以前的组合对价格的影响基本/根的价格。
任何人都知道,如果这个变量是由默认的服务,如果没有,我怎么会能增加吗?
非常感谢。
试着用:
$prod = new Product($id_product);
echo $prod->price;
问候
也许这将帮助:使用getPriceStatic方法。所以,在/controllers/ProductController.php下围绕线231和234
$productPrice = $this->product->getPrice(true, null, 6);
$productPricet = $this->product->getPriceStatic($this->product->id, false, null, 2, null, false, false, 1, false, null, null, null, $this->specificPrice);
和在管线365〜把它分配给阵列
$this->context->smarty->assign(array(
'priceDisplay' => $priceDisplay,
'productPriceWithoutReduction' => $productPriceWithoutReduction,
'customizationFields' => $customization_fields,
'id_customization' => empty($customization_datas) ? null : $customization_datas[0]['id_customization'],
'accessories' => $accessories,
'product' => $product_for_template,
'displayUnitPrice' => (!empty($this->product->unity) && $this->product->unit_price_ratio > 0.000000) ? true : false,
'product_manufacturer' => $productManufacturer,
'manufacturer_image_url' => $manufacturerImageUrl,
'product_brand_url' => $productBrandUrl,
'productPricet' => $productPricet,
));
然后在你的主题.tpl文件
{$productPricet}
编辑:测试过它,不工作WERY好 - 你会得到完全一样的解决方法如下... - 对不起。简单的解决方法是使用格式{$ productPriceWithoutReduction}在TPL文件 - >将显示基本属性的价格,属性变化过程中不会改变。