如何解决免费送货提醒和税收问题

问题描述

我有问题,我需要帮助...我在购物车和结帐时创建了免费送货提醒,说您需要x€才能赢得免费送货,否则您将获得免费送货。我加免运费40.322,这意味着含税为50€。但他只认出40.322,不交税。有人可以帮我吗?我使用Opencart 3和日记主题 我把这个

class ControllerCheckoutCart extends Controller {
public function index() {
$this->load->language('common/cart');
$tax_total = $this->cart->getTaxes();
$tax_value = 0;
foreach($tax_total as $value){
$tax_value = $tax_value + $value;
}
$display_sub_total = round($this->cart->getSubTotal() + $tax_value,2);

if($display_sub_total < $this->config->get('shipping_free_total')){
$this->session->data['shipping_method']['code'] = 'flat.flat';
$this->session->data['shipping_method']['title'] = 'Flat Shipping Rate';
$this->session->data['shipping_method']['value'] = $this->config->get('shipping_flat_cost');
$this->session->data['shipping_method']['cost'] = $this->config->get('shipping_flat_cost');
$this->session->data['shipping_method']['tax_class_id'] = $this->config->get('shipping_flat_tax_class_id');
$this->session->data['shipping_method']['sort_order'] = '3'; */
$difference = $this->config->get('shipping_free_total') - $display_sub_total;
$data['shipping_message_cart'] = sprintf($this->language->get('text_charge_shipping_message'),$this->currency->format($difference,$this->session->data['currency']));
} else {
$this->session->data['shipping_method']['code'] = 'free.free';
$this->session->data['shipping_method']['title'] = 'Free Shipping';
$this->session->data['shipping_method']['value'] = '0';
$this->session->data['shipping_method']['cost'] = '0';
$this->session->data['shipping_method']['sort_order'] = '3'; */
$data['free_shipping_message'] = $this->language->get('text_free_shipping_message');
}

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)