Totals and Referrals Not showing

My Affiliate sales are not showing up when I run the totals report and Referrals search. When I can see the in my WooCommerence Sales (Coupons) Area that there have been 13 orders for a particular Affiliate. The coupons seem to working and allowing the discount, just not seeing sales in those areas and on the page with the short codes.

Coupon code: rspLewis
Username: Lewis.emily016
Name: Emily Lewis

This is just one example, I have a few more this is affecting too.

I have these short codes on one of pages and it is not showing any data.

Monthly Commissions

[affiliates_earnings]
[/affiliates_is_affiliate]

Order History

[affiliates_woocommerce_orders]

5 Responses to Totals and Referrals Not showing

  1. George March 10, 2017 at 8:09 am #

    Just use that snippet and you will be ok. You don’t have to tweak the DB.

    Cheers,
    George

  2. Victor March 9, 2017 at 2:55 am #

    Thank You for this. Could we run a query on the database to update the codes directly there as well? Use that in conjunction with the php code?

  3. George March 8, 2017 at 6:33 pm #

    Hi Victor,

    I had a look on your dashboard using Antonio’s credentials from a previous ticket of yours and i worked out where is your issue.
    WooCommerce converts all codes to lowercase, so if you add a new coupon called rspLewis, it will be stored as rsplewis ( all characters are lowercase ).
    On the other hand affiliates coupons are case sensitive to keep compatibility with other e-commerce plugins, so rspLewis is a different coupon code than rsplewis. That is the reason why you see the sales using the coupon, but the affiliates is not granted with a referral.

    If you have assigned more than one coupons in mixcase for your affiliates and in order to avoid editing each one individually, you should put the following snippet in your functions.php file of your child theme that checks the coupon in lowercase.


    add_filter( 'affiliates_coupons_equality_test', 'gt_affiliates_coupons_equality_test', 10, 3 );
    function gt_affiliates_coupons_equality_test( $test, $coupon1, $coupon2 ) {
    if ( strtolower( $coupon1 ) === strtolower( $coupon2 ) ) {
    $equal = true;
    } else {
    $equal = false;
    }

    return $equal;
    }

    Cheers,
    George

  4. Victor March 8, 2017 at 2:37 pm #

    I opened the ticket because I am not able to go into Affiliates -> Totals and Affiliates -> Referrals and view information. I have included one Affiliate that has know accepted sales and things is showing in the reports for her on her page or when I search within the Admin section on the back end.

    If I go into my WooCommerce -> Coupons Page, and do a search for her coupon there are 14 transactions for her coupon, she is listed as an Affiliate within her User Profile, I can find her in the manage Affiliates Section, but I am not getting any reports of sales for her.

    I have all the included shortcodes already on my Affiliates page, I just included those as a reference to give you as much info as I can to get help, but the reports not showing is what I am after. Once that happens they will appear on the page.

  5. George March 8, 2017 at 7:20 am #

    Hi Victor,

    Please note that the [affiliates_earnings] shortcode shows accepted or closed referrals, pending referrals are not included.
    Also, in case you didn’t mistype it in your topic, the proper block for your affiliates page would be:
    [affiliates_is_affiliate]
    Monthly Commissions

    [affiliates_earnings]
    [/affiliates_is_affiliate]

    Kind regards,
    George

We use cookies to optimize your experience on our site and assume you're OK with that if you stay.
OK, hide this message.

Affiliates · Contact · Jobs · Terms & Conditions · Privacy Policy · Documentation · Downloads · Useful Plugins · My Account

Share