Coupon Discount after Tax


  • Default avatar
    paul50    
     14 years ago
    0

    Hi, if an answer to this is already in the forum I apologise. For me a search did not find it.

    I can't seem to make the coupon discount happen after tax has been added.

    I have 2000 odd coupons imported in the following format.

    2606,12123,Published,Coupon,Product,Percent,Overall,80,,Total,1,,,,,Include,98

    The product is $25.00 including 15% tax ($20.00 pre tax)
    So 25 x 80% = 20 Total to pay should be $5.00

    The discount is being taken off the pre tax price.

    Subtract payment discount before tax/shipping? Is NOT checked in Virtuemart
    Enable Coupon Usage is set to yes in Virtuemart

    Enable Virtuemart Coupons is set to no in AwoCoupon Pro

    AwoCoupon Pro Version: 1.2.1 pro
    VirtueMart 1.1.5
    Joomla Version 1.5.20

    Thanks in advance.

  • Your avatar
    seyi    
     14 years ago
    0

    Ok, from my calculation, the product price should be 21.74 pre tax, probably does not matter, just making sure we have all the right numbers.

    So after entering the discount coupon, what is the order total?

    Are you clicking all the way through to the confirm screen to see if the total changes?

    Also i think you all these coupons are for 1 product correct? If so, you should set the discount type to specific, otherwise it would discount the whole cart, as long as that one product is in it.
  • Default avatar
    paul50    
     14 years ago
    0

    There are several different scenarios. The site is using zone shipping - Tax for local shoppers, none for others. Shipping is free on this particular product. This is achieved by using Free Shipping Extension from joomlacache.

    1: Local customer is already logged in and enters coupon code on first screen after adding product to cart. This works correctly since the shop displays the price incl tax ($25.00) and the coupon discounts 80% ($20.00). Total to pay $5.00 But the tax total still shows as $3.26 Which of course is the tax on the original $25.00 - This confuses the customer but they are only charged the correct $5.00 price.
    2: Local customer is not logged in and enters coupon code on first screen after adding product to cart. This works incorrectly since the shop displays the price excl tax ($21.74) and the coupon discounts 80% ($17.39). Then the shopper logs in, the product price is shown incl tax $25.00 less discount $17.39 Total to pay $7.61 But the tax total still shows as $3.26

    The coupons are unique codes for specific customers. This is why I have used Number of Uses = Total (1) rather than per customer.
    Using per customer stops the problem of being able to enter the coupon code before being logged in the coupon errors, but these codes could be passed on to other people to use. Not ideal.

    Summary.
    I'd like to fix the confusing incorrect tax total.
    I'd like to stop customers being able to enter code before tax is added.

    Thanks for point out the overall specific thing. That would have been costly. I've removed all coupons in the short term.
  • Your avatar
    seyi    
     14 years ago
    0

    I'd like to fix the confusing incorrect tax total.
    wrote a blog on this, since this issue keeps coming up:
    https://awodev.com/blog/virtuemart-coupon-tax-error-initial-basket

    I'd like to stop customers being able to enter code before tax is added.
    one possible solution is to hide the coupon field until the customer logs in:
    https://awodev.com/forum/awocoupon/help-section/it-possible-have-code-used-set-number-times-without-users-lo#comment-46
  • Default avatar
    paul50    
     14 years ago
    0

    I've tried the fix in your blog but the tax total is still incorrect. It shows as the original tax on the full price. The total being charged is still correct though. Extract from my basket.php file below. Please note that the incorrect tax is not only on the the initial basket, it is incorrect on the final confirm payment pages and order emails. This is before and after the "fix"

    * http://virtuemart.net
    */
    mm_showMyFileName( __FILE__ );
    global $vars;

    require_once(CLASSPATH. 'ps_product.php' );
  • Your avatar
    seyi    
     14 years ago
    0

    I see. On a default installation this would work. the problem is i cannot see your store, how you have it configured, with taxes, shopper groups, products, etc. there are just so many elements and something in your configuration is causing this. Or there is just a bug in virtuemart code (which is not unheard of). if you have manually updated any virtuemart files, that could be part of the problem.

    the main files that affect the pricing in your cart that you can look at are
    www/administrator/components/com_virtuemart/classes/ps_checkout.php
    www/administrator/components/com_virtuemart/html/basket.php
    www/administrator/components/com_virtuemart/html/ro_basket.php

    You will probably have to try and trace through those files to find out where the error is occurring.