diff --git a/includes/admin/post-types/meta-boxes/class-sp-meta-box-player-statistics.php b/includes/admin/post-types/meta-boxes/class-sp-meta-box-player-statistics.php index 74ba81e5..c276c718 100644 --- a/includes/admin/post-types/meta-boxes/class-sp-meta-box-player-statistics.php +++ b/includes/admin/post-types/meta-boxes/class-sp-meta-box-player-statistics.php @@ -36,6 +36,11 @@ class SP_Meta_Box_Player_Statistics { self::table( $post->ID, $league->term_id, $columns, $data, $placeholders, $merged, $seasons_teams, $has_checkboxes && $i == 0, true ); $i ++; endforeach; + ?> +
+ data( 0, true ); + self::table( $post->ID, 0, $columns, $data, $placeholders, $merged, $seasons_teams ); } else { // Determine order of sections if ( 1 == $sections ) { @@ -56,6 +61,11 @@ class SP_Meta_Box_Player_Statistics { self::table( $post->ID, $league->term_id, $columns, $data, $placeholders, $merged, $seasons_teams, $has_checkboxes && $i == 0 && $s == 0, $s == 0 ); $i ++; endforeach; + ?> +
—
+ data( 0, true, $section_id ); + self::table( $post->ID, 0, $columns, $data, $placeholders, $merged, $seasons_teams, $has_checkboxes && $i == 0 && $s == 0, $s == 0 ); $s ++; } } diff --git a/templates/player-statistics-league.php b/templates/player-statistics-league.php index 95c843da..f17ac9f2 100644 --- a/templates/player-statistics-league.php +++ b/templates/player-statistics-league.php @@ -14,6 +14,8 @@ $output = '| ' . $label . ' | '; endforeach; @@ -26,6 +28,8 @@ foreach( $data as $season_id => $row ): $output .= '
|---|
| ' . sp_array_value( $row, $key, '' ) . ' | '; endforeach; diff --git a/templates/player-statistics.php b/templates/player-statistics.php index bb630e0f..ddb6cc5f 100644 --- a/templates/player-statistics.php +++ b/templates/player-statistics.php @@ -55,10 +55,16 @@ if ( is_array( $leagues ) ): sp_get_template( 'player-statistics-league.php', array( 'data' => $player->data( $league->term_id, false, $section_id ), - 'league' => $league, 'caption' => $caption, 'scrollable' => $scrollable, ) ); endforeach; + + sp_get_template( 'player-statistics-league.php', array( + 'data' => $player->data( 0, false, $section_id ), + 'caption' => __( 'Career Total', 'sportspress' ), + 'scrollable' => $scrollable, + 'hide_teams' => true, + ) ); } endif; \ No newline at end of file