Rewards - Delay Registration Rule


  • Default avatar
    sandro7    
     9 years ago
    0

    Hi,
    I'm trying to config a rule that gives a coupon 2 days after registration (if customer not ordered), but the component is sending this coupon just after registration, without any delay.
    How can I fix this?

    Thanks for your help!
  • Your avatar
    seyi    
     9 years ago
    0

    Hello,

    In the registration rule, have you set:
    - Delay in Days
    - Do not send Coupon if customer ordered

    Also, do you have more than 1 registration rule? If so disable the others.
  • Default avatar
    sandro7    
     9 years ago
    0

    - Delay in Days - Done
    - Do not send Coupon if customer ordered - Done

    Also, do you have more than 1 registration rule? If so disable the others. - No, just one registration rule.

  • Your avatar
    seyi    
     9 years ago
    0

    Alright, able to reproduce. Here is the fix:

    in www/administrator/components/com_aworewards/helpers/estore/estorerewardshandler.php, around line 324 is this:
    <?php
        
    if(!empty($recipient)) $this->credit($_type,$sponsor,$recipient,$rule,null);
    ?>


    Please change it to this:
    <?php
        
    if(!empty($recipient) && empty($rule->params->reg_delay) ) $this->credit($_type,$sponsor,$recipient,$rule,null);
    ?>


    That should fix the problem
  • Default avatar
    sandro7    
     9 years ago
    0

    Hi Seyi, thanks for your response.

    I followed your instruction. Lets wait the days of delay to see if the system will send the coupon...
    So far, so good...