- Posts: 63
- Thank you received: 1
Shows Cost with shipping even though shipping is hidden
8 years 2 months ago #296728
by mikekiy
Shows Cost with shipping even though shipping is hidden was created by mikekiy
-- Joomla version -- : 3.8.11
-- PHP version -- : 7.0
Hello,
In the Hikashop Cart Module, we have it configured as:
www.dropbox.com/s/dsmic758u2da8da/Screen...%2015.43.51.png?dl=0
As you can see coupon = yes, but shipping = no, price is calculated with shipping always event though shipping isn't shown and it looks like:
www.dropbox.com/s/yleidua0lnwb1ys/Screen...%2015.46.06.png?dl=0 , if I disable coupon the calculation is correct.
-- PHP version -- : 7.0
Hello,
In the Hikashop Cart Module, we have it configured as:
www.dropbox.com/s/dsmic758u2da8da/Screen...%2015.43.51.png?dl=0
As you can see coupon = yes, but shipping = no, price is calculated with shipping always event though shipping isn't shown and it looks like:
www.dropbox.com/s/yleidua0lnwb1ys/Screen...%2015.46.06.png?dl=0 , if I disable coupon the calculation is correct.
Please Log in or Create an account to join the conversation.
Less
More
- Posts: 12953
- Thank you received: 1778
8 years 2 months ago - 8 years 2 months ago #296733
by Mohamed Thelji
Replied by Mohamed Thelji on topic Shows Cost with shipping even though shipping is hidden
Hello,
A solution can eventually be to directly edit the code of the "Cart" file of the "Product" view of your front-end template via "Hikashop->Display->Views" and change these lines :
by :
A solution can eventually be to directly edit the code of the "Cart" file of the "Product" view of your front-end template via "Hikashop->Display->Views" and change these lines :
Code:
<td class="hikashop_cart_module_product_total_value"><?php
$this->row = $this->total;
echo $this->loadTemplate();
?></td>
Code:
<td class="hikashop_cart_module_product_total_value"><?php
//
//
$price_name = '';
if(!$this->params->get('show_shipping', 0) && isset($this->total->prices[0]->price_value_without_shipping)){
$price_name = '_without_shipping';
}
if(!$this->params->get('show_coupon', 0) && isset($this->total->prices[0]->price_value_without_discount)){
$price_name = '_without_discount';
}
$price = '';
if($this->params->get('price_with_tax')){
$var_name = 'price_value'.$price_name.'_with_tax';
$price .= $this->currencyClass->format(@$this->total->prices[0]->$var_name, $this->total->prices[0]->price_currency_id);
}
if($this->params->get('price_with_tax')==2){
$price .= JText::_('PRICE_BEFORE_TAX');
}
if($this->params->get('price_with_tax')==2||!$this->params->get('price_with_tax')){
$var_name = 'price_value'.$price_name;
$price .= $this->currencyClass->format(@$this->total->prices[0]->price_value, $this->total->prices[0]->price_currency_id);
}
if($this->params->get('price_with_tax')==2){
$price .= JText::_('PRICE_AFTER_TAX');
}
echo $price;
?></td>
Last edit: 8 years 2 months ago by Mohamed Thelji.
Please Log in or Create an account to join the conversation.
8 years 2 months ago #296805
by mikekiy
Replied by mikekiy on topic Shows Cost with shipping even though shipping is hidden
Thank you, I take it this will be in the next release?
Please Log in or Create an account to join the conversation.
8 years 2 months ago #296809
by Jerome
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Replied by Jerome on topic Shows Cost with shipping even though shipping is hidden
Hello,
The patch that Mohamed gave you is adapted to your configuration.
For the moment we don't think that we will integrate it in the next release because it won't suit for all users.
We need to find for other solutions and see if there is one which can be useful for everybody.
But if you apply the modification via a view override, you will be sure to not loose it with updates.
Regards,
The patch that Mohamed gave you is adapted to your configuration.
For the moment we don't think that we will integrate it in the next release because it won't suit for all users.
We need to find for other solutions and see if there is one which can be useful for everybody.
But if you apply the modification via a view override, you will be sure to not loose it with updates.
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Please Log in or Create an account to join the conversation.
8 years 2 months ago #296906
by mikekiy
Replied by mikekiy on topic Shows Cost with shipping even though shipping is hidden
Hello,
But it is a bug is it not? You tell it not to show shipping within the cart yet it still calculates the price of shipping....
But it is a bug is it not? You tell it not to show shipping within the cart yet it still calculates the price of shipping....
Please Log in or Create an account to join the conversation.
8 years 2 months ago #296916
by mikekiy
Replied by mikekiy on topic Shows Cost with shipping even though shipping is hidden
Hello,
It is rather a nightmare. Now we have the coupon not being added to the total configuration.
Many thanks
Tony
It is rather a nightmare. Now we have the coupon not being added to the total configuration.
Many thanks
Tony
Please Log in or Create an account to join the conversation.
Less
More
- Posts: 12953
- Thank you received: 1778
8 years 2 months ago #296920
by Mohamed Thelji
Replied by Mohamed Thelji on topic Shows Cost with shipping even though shipping is hidden
Hello,
Thank you for your feedback we just added it on our TODO list for futur HikaShop versions, we'll keep you updated about it.
Depending on your configuration some adaptation should be applied through the code we gave you.
Best regards,
Mohamed Thelji.
But it is a bug is it not? You tell it not to show shipping within the cart yet it still calculates the price of shipping....
Thank you for your feedback we just added it on our TODO list for futur HikaShop versions, we'll keep you updated about it.
It is rather a nightmare. Now we have the coupon not being added to the total configuration.
Depending on your configuration some adaptation should be applied through the code we gave you.
Best regards,
Mohamed Thelji.
Please Log in or Create an account to join the conversation.
Time to create page: 0.084 seconds