Add ability to display positions in event performance tables

This commit is contained in:
Brian Miyaji
2015-03-16 22:36:41 +11:00
parent 820b44cae8
commit 8922ff07e4
3 changed files with 18 additions and 13 deletions

View File

@@ -5,7 +5,7 @@
* @author ThemeBoy
* @category Admin
* @package SportsPress/Admin/Meta_Boxes
* @version 1.7
* @version 1.7.2
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
@@ -85,14 +85,7 @@ class SP_Meta_Box_Event_Performance {
<th>#</th>
<th><?php _e( 'Player', 'sportspress' ); ?></th>
<th class="column-position">
<?php if ( $has_checkboxes ): ?>
<label for="sp_columns_position">
<input type="checkbox" name="sp_columns[]" value="position" id="sp_columns_position" <?php checked( ! is_array( $columns ) || in_array( 'position', $columns ) ); ?>>
<?php _e( 'Position', 'sportspress' ); ?>
</label>
<?php else: ?>
<?php _e( 'Position', 'sportspress' ); ?>
<?php endif; ?>
<?php _e( 'Position', 'sportspress' ); ?>
</th>
<?php foreach ( $labels as $key => $label ): ?>
<th>

View File

@@ -5,7 +5,7 @@
* @author ThemeBoy
* @category Admin
* @package SportsPress/Admin
* @version 1.7
* @version 1.7.2
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
@@ -241,6 +241,14 @@ class SP_Settings_Events extends SP_Settings_Page {
'manual' => __( 'Manual', 'sportspress' ),
),
),
array(
'title' => __( 'Position', 'sportspress' ),
'desc' => __( 'Display position', 'sportspress' ),
'id' => 'sportspress_event_show_position',
'default' => 'yes',
'type' => 'checkbox',
),
array(
'title' => __( 'Mode', 'sportspress' ),