Skip to main content

Email Order Summary items - Change position / remove

More
8 years 7 months ago #287998 by BounceHouseOwner
-- HikaShop version -- : 3.2.2 Business
-- Joomla version -- : 3.8.5
-- PHP version -- : 7.x
-- Browser(s) name and version -- : chrome / firefox
-- Error-message(debug-mod must be tuned on) -- : N/A

How do you switch positions or remove these items?
I tried using the language file, but it still leaves the line value.

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

More
8 years 7 months ago #287999 by BounceHouseOwner
Looking to have that section be:

Subtotal: (total of items)
Tax: (tax on those items)
Delivery: (Delivery charge)
Total: (Total of everything)

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

More
8 years 7 months ago #288013 by nicolas
Hi,

You need to modify this code in the preload section of the email:
Code:
if(bccomp($data->cart->order_discount_price,0,5) != 0 || bccomp($data->cart->order_shipping_price,0,5) != 0 || bccomp($data->cart->order_payment_price,0,5) != 0 || ($data->cart->full_total->prices[0]->price_value!=$data->cart->full_total->prices[0]->price_value_with_tax) || !empty($data->cart->additional)){ $cartFooters[] = array( '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); } $cartFooters[] = array( 'NAME' => JText::_('HIKASHOP_COUPON'), 'VALUE' => $t ); } if(bccomp($data->cart->order_shipping_price,0,5) != 0){ if($config->get('price_with_tax')) { $t = $currencyHelper->format($data->cart->order_shipping_price,$data->cart->order_currency_id); }else{ $t = $currencyHelper->format($data->cart->order_shipping_price-@$data->cart->order_shipping_tax,$data->cart->order_currency_id); } $cartFooters[] = array( 'NAME' => JText::_('HIKASHOP_SHIPPING'), 'VALUE' => $t ); } if(bccomp($data->cart->order_payment_price,0,5) != 0){ if($config->get('price_with_tax')) { $t = $currencyHelper->format($data->cart->order_payment_price, $data->cart->order_currency_id); } else { $t = $currencyHelper->format($data->cart->order_payment_price - @$data->cart->order_payment_tax, $data->cart->order_currency_id); } $cartFooters[] = array( 'NAME' => JText::_('HIKASHOP_PAYMENT'), 'VALUE' => $t ); } if(!empty($data->cart->additional)) { $exclude_additionnal = explode(',', $config->get('order_additional_hide', '')); foreach($data->cart->additional as $additional) { if(in_array($additional->order_product_name, $exclude_additionnal)) continue; if(!empty($additional->order_product_price)) $additional->order_product_price = (float)hikashop_toFloat($additional->order_product_price); if(!empty($additional->order_product_price) || empty($additional->order_product_options)) { if($config->get('price_with_tax')){ $t = $currencyHelper->format($additional->order_product_price + @$additional->order_product_tax, $data->cart->order_currency_id); }else{ $t = $currencyHelper->format($additional->order_product_price, $data->cart->order_currency_id); } } else { $t = $additional->order_product_options; } $cartFooters[] = array( 'NAME' => JText::_($additional->order_product_name), 'VALUE' => $t ); } } if($data->cart->full_total->prices[0]->price_value!=$data->cart->full_total->prices[0]->price_value_with_tax) { if($config->get('detailed_tax_display') && !empty($data->cart->order_tax_info)) { foreach($data->cart->order_tax_info as $tax) { $cartFooters[] = array( 'NAME' => $tax->tax_namekey, 'VALUE' => $currencyHelper->format($tax->tax_amount,$data->cart->order_currency_id) ); } } else { $cartFooters[] = array( 'NAME' => JText::_('ORDER_TOTAL_WITHOUT_VAT'), 'VALUE' => $currencyHelper->format($data->cart->full_total->prices[0]->price_value,$data->cart->order_currency_id) ); } $cartFooters[] = array( 'NAME' => JText::_('ORDER_TOTAL_WITH_VAT'), 'VALUE' => $currencyHelper->format($data->cart->full_total->prices[0]->price_value_with_tax,$data->cart->order_currency_id) ); } else { $cartFooters[] = array( 'NAME' => JText::_('HIKASHOP_TOTAL'), 'VALUE' => $currencyHelper->format($data->cart->full_total->prices[0]->price_value_with_tax,$data->cart->order_currency_id) ); }

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

Time to create page: 0.166 seconds
Powered by Kunena Forum