Display same position for teams tied in table
This commit is contained in:
@@ -113,7 +113,7 @@ foreach ( $data as $team_id => $row ):
|
||||
$output .= '<tr class="' . ( $i % 2 == 0 ? 'odd' : 'even' ) . $class . '">';
|
||||
|
||||
// Rank
|
||||
$output .= '<td class="data-rank">' . $before . ( $start + 1 ) . $after . '</td>';
|
||||
$output .= '<td class="data-rank">' . $before . sp_array_value( $row, 'pos' ) . $after . '</td>';
|
||||
|
||||
$name_class = '';
|
||||
|
||||
@@ -135,7 +135,7 @@ foreach ( $data as $team_id => $row ):
|
||||
$output .= '<td class="data-name' . $name_class . '">' . $name . '</td>';
|
||||
|
||||
foreach( $labels as $key => $value ):
|
||||
if ( $key == 'name' )
|
||||
if ( in_array( $key, array( 'pos', 'name' ) ) )
|
||||
continue;
|
||||
if ( ! is_array( $columns ) || in_array( $key, $columns ) )
|
||||
$output .= '<td class="data-' . $key . '">' . $before . sp_array_value( $row, $key, '—' ) . $after . '</td>';
|
||||
|
||||
Reference in New Issue
Block a user