Flat coupon amount not displaying correctly

  • Posts: 44
  • Thank you received: 0
2 weeks 5 days ago #321301

Hi,

We have set the coupon amount as flat INR 1,000 but after applying it is showing Rs 847. How and why?.

Please find attached wrong coupon amount seen in cart after applying coupon and coupon settings.

Attachments:
Last edit: 2 weeks 5 days ago by Harrier.

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

  • Posts: 70022
  • Thank you received: 10487
  • MODERATOR
2 weeks 5 days ago #321306

Hi,

I suppose that it's because the value you see there i the coupon without the taxes since the amount of the taxes you see on the line below is also affected by the coupon and it seems that you've configured the cart to display the prices without tax.
If we were to display 1000 there, then if you would add the subtotal - your coupon + the taxes, then the value you be different than the total.

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

  • Posts: 44
  • Thank you received: 0
2 weeks 4 days ago #321355

Sorry. But I didn't understand what you said.

Our prices in product page are including taxes. In cart we show it excluding tax in Unit price column. Then we deduct coupon and on the net amount tax is applicable and total will be net amount(after coupon deduction) plus tax on net amount. That's it. And this logic should be displayed everywhere, emails, invoices, orders, vendor page orders, etc.

Please guide as this looks more tricky now.

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

  • Posts: 70022
  • Thank you received: 10487
  • MODERATOR
2 weeks 1 day ago #321447

Hi,

On your screenshot of the checkout, the subtotal is 9,497. That's the sum of the price without taxes of the products in the cart.
Then the coupon is added to it, and then the taxes is taxes for the total amount (subtotal-coupon). and then you have the final total which is: (subtotal - coupon + taxes).
So the coupon value you see there is the coupon value before the taxes are added in.
So 847 is the value removed from the sutotal without taxes so that the value removed from the total with taxes is 1000.
That's why it displays 847 there because otherwise, if the customer sums (subtotal - coupon + taxes) and the coupon value is 1000, the total he would found would be different than what is displayed.
The alternative would be to move the taxes row before the coupon row there and display the taxes without taking into account the coupon so that we could display the total coupon value and the sum of the different elements would still match.

Basically, what I'm saying is that the calculations and the display are correct there.
You can of course change the value displayed for the coupon with a bit of code modification in the view displaying that area. To do that, edit the file show_block_cart.php and change the line:

echo $this->currencyClass->format(@$cart->coupon->discount_value_without_tax * -1, @$cart->coupon->discount_currency_id);
to:
echo $this->currencyClass->format(@$cart->coupon->discount_value * -1, @$cart->coupon->discount_currency_id);

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

  • Posts: 4
  • Thank you received: 0
2 weeks 1 day ago #321454

Hi,

We have added the code suggested by you after that also it is not calculating GST properly.
please find attached screenshot for more clarity.
According to requirement, we have to show rows in below order.
Now the system is calculating like this:

Subtotal ₹9,497
Coupon -₹1,000 (Maybe instead of this amount it is subtracting 847 internally that's why it is showing 1557 GST which is 18% of the calculation )
GST ₹1,557 (Correct value should be 1529 GST)
Total ₹10,207

Please check and let us know the solution on this.

Thanks in advance!

Attachments:

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

  • Posts: 70022
  • Thank you received: 10487
  • MODERATOR
2 weeks 1 day ago #321461

Hi,

I don't know how much is the GST rate you configured. So I can't do calculations on the prices I see there and thus can't say if it's correct, incorrect or if something has to be changed and what.
What rate did you configure for your GST tax rate ?

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

  • Posts: 44
  • Thank you received: 0
2 weeks 1 day ago #321476

Our GST rate is 18% non cumulative. Look forward to hearing from you ASAP.

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

  • Posts: 70022
  • Thank you received: 10487
  • MODERATOR
2 weeks 23 hours ago #321487

Hi,

Thanks. So here is what I found:

taxes on the subtotal 9497 * 18% = 1709
subttoal with taxes 9497 + 1709 = 11206
total with taxes with coupon added : 11206 - 1000 = 10206
taxes to be displayed with coupon added : 10206*18/100 = 1837

As you get 1557 instead, I suppose there is an issue with the application of the coupon value on the taxes.
Please try changing the "Apply coupons" setting in the HikaShop configuration, that should help.

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

Time to create page: 0.077 seconds
Powered by Kunena Forum