subtotal on email notifications without tax

  • Posts: 22
  • Thank you received: 0
2 years 6 months ago #341828

-- HikaShop version -- : 4.5.1
-- Joomla version -- : 4.1.3.
-- PHP version -- : 8.0
-- Browser(s) name and version -- : Google Chrome

I'd like to see the subtotal price on the confirmation emails without vat.
I have been searching in the templates of the emails system>emails and found in the order notification for example these lines:
'CLASS' => 'subtotal',
'NAME' => JText::_('SUBTOTAL'),
'VALUE' => $currencyHelper->format($subtotal,$data->cart->order_currency_id)
);
}
if(bccomp($data->cart->order_discount_price,0,5) != 0) {
if($config->get('price_with_tax')) {
$t = $currencyHelper->format($data->cart->order_discount_price * -1, $data->cart->order_currency_id);
}else{
$t = $currencyHelper->format(($data->cart->order_discount_price - @$data->cart->order_discount_tax) * -1, $data->cart->order_currency_id);
}

But no matter what I try, the subtotal remains with vat. Can you please help me?

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
2 years 6 months ago #341834

Hi,

It's not that code you want to change.
You want to change the line:
$subtotal += $item->order_product_total_price;
to:
$subtotal += $item->order_product_total_price_no_vat;

The following user(s) said Thank You: CindyDP

Please Log in or Create an account to join the conversation.

Time to create page: 0.047 seconds
Powered by Kunena Forum