In your merchant panel navigate to Configuration > Design > Affiliate panel theme > and edit the theme. In the 'Theme editor' find and edit: 'period_stats.stpl' file.
You can use the following variables to add sub-affiliates counts to the affiliate panel home screen:
Number (count) of sub-affiliates on visible tiers for (parent) affiliate:
- {$todaySubaffiliatesCount|number_span} - today sub-affiliates count
- {$thisMonthSubaffiliatesCount|number_span} - this month sub-affiliates count
- {$last30DaysSubaffiliatesCount|number_span} - last 30 days sub-affiliates count
- {$subaffiliatesCount|number_span} - sub-affiliates count
Number (count) of direct sub-affiliates:
- {$todayDirectSubaffiliatesCount|number_span} - today direct sub-affiliates count
- {$thisMonthDirectSubaffiliatesCount|number_span} - this month direct sub-affiliates count
- {$last30DaysDirectSubaffiliatesCount|number_span} - last 30 days direct sub-affiliates count
- {$directSubaffiliatesCount|number_span} - direct sub-affiliates count
For example, you can add the following HTML code at the end of the "period_stats.stpl" file to display sub-affiliates counts:
<table width="600" class="StatsSummaries">
<tr class="gray" >
<td class="white" width="20%"></td>
<td align="center" >##Today##</td>
<td align="center" >##This month##</td>
<td align="center" >##All##</td>
</tr>
<tr class="light" >
<td class="white" width="20%">Subaffiliates</td>
<td align="center" >{$todaySubaffiliatesCount|number_span}</td>
<td align="center" >{$thisMonthSubaffiliatesCount|number_span}</td>
<td align="center" >{$subaffiliatesCount|number_span}</td>
</tr>
</table>
Affiliate panel home screen will look like this:
By default the above variables return the number of ALL sub-affiliates the parent affiliate has under him. It means approved, pending and decline affiliates.
If you would like to display number of APPROVED sub-affiliates only, then you need to set sub-affiliates filter in Configuration > Affiliate Panel > Menu & screens > edit either "Signup Subaffiliates" or "Tree of subaffiliates" > Subaffiliates filter > mark only 'Approved' affiliates and save the configuration.