Get separate set of posts for each league
This commit is contained in:
5
team.php
5
team.php
@@ -57,8 +57,13 @@ function sp_team_stats_meta( $post ) {
|
|||||||
'post_type' => 'sp_event',
|
'post_type' => 'sp_event',
|
||||||
'meta_key' => 'sp_team',
|
'meta_key' => 'sp_team',
|
||||||
'meta_value' => $post->ID,
|
'meta_value' => $post->ID,
|
||||||
|
'tax_query' => array(
|
||||||
|
array(
|
||||||
'taxonomy' => 'sp_league',
|
'taxonomy' => 'sp_league',
|
||||||
|
'field' => 'id',
|
||||||
'terms' => $league_id
|
'terms' => $league_id
|
||||||
|
)
|
||||||
|
)
|
||||||
);
|
);
|
||||||
$placeholders[ $league_id ] = sp_get_stats_row( $args );
|
$placeholders[ $league_id ] = sp_get_stats_row( $args );
|
||||||
endforeach;
|
endforeach;
|
||||||
|
|||||||
Reference in New Issue
Block a user