Discount Code is not Valid


  • Default avatar
    peaces    
     12 years ago
    0

    I am probably not doing something correctly but I have created:

    Coupon
    Product
    (Code Number)
    Published
    Amount
    Discount: Overall
    Value: 25.00

    Number of Uses: per Customer 1
    Minimum Value: 150.00
    No Dates

    I have tries this coupon without a minimum value and it will process. When I add any amount to the Minimum value, the check out page tells me "The Discount Code is not Valid".

    Suggestions?

    Thanks in advance.

    Pro Version 2.1.1
  • Your avatar
    seyi    
     12 years ago
    0

    Hello,

    Strange problem. What eshop are you using, would like to test it locally.
  • Default avatar
    peaces    
     12 years ago
    0

    RedShop (latest ver)
  • Your avatar
    seyi    
     12 years ago
    0

    Thanks, found the problem. This will be updated in the next update. In the meantime, here is the fix required to get it to work correctly:

    in www/administrator/components/com_awocoupon/helpers/estore/redshop/couponhandler.php, around line 23 is this:
    <?php
            $this
    ->estore 'redshop';
    ?>


    right after that add this
    <?php
            $this
    ->rscart $this->session->get('cart');
            
    $this->product_total = @$this->rscart['total'];
    ?>


    That should fix the problem.
  • Default avatar
    peaces    
     12 years ago
    0

    Thanks, I'll give it a try.

    Warren
  • Default avatar
    peaces    
     12 years ago
    0

    Actually my file does not have the (
    <?php
     
    and 
    ?>
    ) and looks like this:
    function AwoCouponRedshopCouponHandler () {

    parent::__construct();



    $this->estore = 'redshop';
    }



    static function process_coupon_code( $c_data ) {

    //exit('processing');


    If I place the two lines after the 'redshop' line the Cart page works,...
    $this->estore = 'redshop';
    $this->rscart = $this->session->get('cart');
    $this->product_total = @$this->rscart['total'];

    ..........but on the following Check Out Page page I get this across the top.


    Warning: Division by zero in /home/content/62/8459762/html/administrator/components/com_awocoupon/helpers/estore/redshop/couponhandler.php on line 333

    Warning: Division by zero in /home/content/62/8459762/html/administrator/components/com_awocoupon/helpers/estore/redshop/couponhandler.php on line 333

    Warning: Division by zero in /home/content/62/8459762/html/administrator/components/com_awocoupon/helpers/estore/redshop/couponhandler.php on line 333
  • Your avatar
    seyi    
     12 years ago
    0

    Yes, sorry, you would not see the <\?php and ?>. Those are just there to make the code look pretty.

    So again, find this code
            $this->estore = 'redshop';


    And add this to it
            $this->rscart = $this->session->get('cart');
            $this->product_total = @$this->rscart['total'];


    You are in the right place. Add that and lets see how that works.