echo affiliate_wp()->referrals->count(array('affiliate_id' => $affiliate_id, 'status' => 'unpaid')); ?> </td> <td><?php echo affiliate_wp()->referrals->count(array('affiliate_id' => $affiliate_id, 'status' => 'pending')); ?> </td> <td><?php echo affiliate_wp()->referrals->count(array('affiliate_id' => $affiliate_id, 'status' => 'rejected')); ?> </td> <td><?php echo affwp_get_affiliate_visit_count($affiliate_id); ?> </td> <?php do_action('affwp_view_affiliate_report_table_row', $affiliate_id); ?> </tr> </tbody> </table> <?php $graph = new Affiliate_WP_Referrals_Graph(); $graph->set('x_mode', 'time'); $graph->set('affiliate_id', $affiliate_id); $graph->display(); do_action('affwp_view_affiliate_report_bottom'); ?> </div>
echo get_aff_coupon_code(); ?> </span></td> </tr> </tbody> </table> </div> <br> <div id="affwp-affiliate-dashboard-graphs" class="affwp-tab-content"> <h4>Referrals Graph</h4> <?php $graph = new Affiliate_WP_Referrals_Graph(); $graph->set('x_mode', 'time'); $graph->set('affiliate_id', affwp_get_affiliate_id()); $graph->display(); ?> <?php do_action('affwp_affiliate_dashboard_after_graphs', affwp_get_affiliate_id()); ?> </div> <script> jQuery(document).ready(function($) { /*tool tip*/ $('[data-toggle="tooltip"]').tooltip();
/** * Display the referrals reports tab * * @since 1.1 * @return void */ function affwp_reports_tab_referrals() { ?> <table id="affwp_total_earnings" class="affwp_table"> <thead> <tr> <th><?php _e('Paid Earnings', 'affiliate-wp'); ?> </th> <th><?php _e('Paid Earnings This Month', 'affiliate-wp'); ?> </th> <th><?php _e('Paid Earnings Today', 'affiliate-wp'); ?> </th> </tr> </thead> <tbody> <tr> <td><?php echo affiliate_wp()->referrals->paid_earnings(); ?> </td> <td><?php echo affiliate_wp()->referrals->paid_earnings('month'); ?> </td> <td><?php echo affiliate_wp()->referrals->paid_earnings('today'); ?> </td> </tr> </tbody> </table> <table id="affwp_unpaid_earnings" class="affwp_table"> <thead> <tr> <th><?php _e('Unpaid Earnings', 'affiliate-wp'); ?> </th> <th><?php _e('Unpaid Earnings This Month', 'affiliate-wp'); ?> </th> <th><?php _e('Unpaid Earnings Today', 'affiliate-wp'); ?> </th> </tr> </thead> <tbody> <tr> <td><?php echo affiliate_wp()->referrals->unpaid_earnings(); ?> </td> <td><?php echo affiliate_wp()->referrals->unpaid_earnings('month'); ?> </td> <td><?php echo affiliate_wp()->referrals->unpaid_earnings('today'); ?> </td> </tr> </tbody> </table> <table id="affwp_unpaid_counts" class="affwp_table"> <thead> <tr> <th><?php _e('Unpaid Referrals', 'affiliate-wp'); ?> </th> <th><?php _e('Unpaid Referrals This Month', 'affiliate-wp'); ?> </th> <th><?php _e('Unpaid Referrals Today', 'affiliate-wp'); ?> </th> </tr> </thead> <tbody> <tr> <td><?php echo affiliate_wp()->referrals->unpaid_count(); ?> </td> <td><?php echo affiliate_wp()->referrals->unpaid_count('month'); ?> </td> <td><?php echo affiliate_wp()->referrals->unpaid_count('today'); ?> </td> </tr> </tbody> </table> <?php $graph = new Affiliate_WP_Referrals_Graph(); $graph->set('x_mode', 'time'); $graph->display(); }