Thanks.
yeah,i set up the specific price with amount or percentage discount,but i find max_price of all products with specific price are wrong,while with no specific price are right. so,i delete the code below,it gets the right results. Anyhow , thanks! in fact,max_price of specific should approximately equal with the min_price. aha .
/*
foreach ($product_min_prices as $specific_price)
foreach ($currency_list as $currency)
{
if ($specific_price['id_currency'] && $specific_price['id_currency'] != $currency['id_currency'])
continue;
$price_before_reduction = Product::priceCalculation((($specific_price['id_shop'] == 0) ? null : (int)$specific_price['id_shop']), (int)$id_product,
null, (($specific_price['id_country'] == 0) ? null : $specific_price['id_country']), null, null,
$currency['id_currency'], (($specific_price['id_group'] == 0) ? null : $specific_price['id_group']),
$specific_price['from_quantity'], false, 6, false, false, true, $specific_price_output, true, null, null, null, 1);
$only_reduction = Product::priceCalculation((($specific_price['id_shop'] == 0) ? null : (int)$specific_price['id_shop']), (int)$id_product,
null, (($specific_price['id_country'] == 0) ? null : $specific_price['id_country']), null, true,
$currency['id_currency'], (($specific_price['id_group'] == 0) ? null : $specific_price['id_group']),
$specific_price['from_quantity'], false, 6, true, true, true, $specific_price_output, true, null, null, null, 1);
if (isset($price_before_reduction, $only_reduction))
$price = (float) $price_before_reduction - (float) $only_reduction * 100/(100 + $max_tax_rate_for_reduction);
unset($price_before_reduction, $only_reduction);
if (!isset($max_price[$currency['id_currency']]))
$max_price[$currency['id_currency']] = 0;
if (!isset($min_price[$currency['id_currency']]))
$min_price[$currency['id_currency']] = null;
if ($price > $max_price[$currency['id_currency']])
$max_price[$currency['id_currency']] = $price;
if ($price == 0)
continue;
if (is_null($min_price[$currency['id_currency']]) || $price < $min_price[$currency['id_currency']])
$min_price[$currency['id_currency']] = $price;
}
*/