Re: Buy one get one free, tax calculation problem
On the surface that appears to address what is seen, but when charged, is the correct amount "taken"? I'm also not familiar with the plugin, but the above code change appears to only address one output characteristic and wouldn't want you to be surprised to be charged more than displayed.
Re: Buy one get one free, tax calculation problem
Tax is usually done by using zen_add_tax() and passing the relevant tax rates, and then passing that result to the currency->format().
Looks like this particular BOGO module wasn't written with tax in mind?
Re: Buy one get one free, tax calculation problem
Dear DrByte,
It's seem that this module isn't write with tax in mind indeed. But for now it works fine the way I have changed the program code.
It looks like this:
function process() {
global $order, $currencies;
$order->info['total'] = $order->info['total'] - $_SESSION['cost_minimize_agg']-($_SESSION['cost_minimize_agg']*0.06);
if($_SESSION['cost_minimize_agg'] > 0){
$this->output[] = array('title' => $this->title . ':',
'text' => '-' . $currencies->format($_SESSION['cost_minimize_agg']+($_SESSION['cost_minimize_agg']*0.06), true, $order->info['currency'], $order->info['currency_value']),
'value' => $_SESSION['cost_minimize_agg']);