diff --git a/assets/images/welcome/screenshot-awards.png b/assets/images/welcome/screenshot-awards.png deleted file mode 100644 index 855f8696..00000000 Binary files a/assets/images/welcome/screenshot-awards.png and /dev/null differ diff --git a/assets/images/welcome/screenshot-conditional-equations.png b/assets/images/welcome/screenshot-conditional-equations.png new file mode 100644 index 00000000..5a988271 Binary files /dev/null and b/assets/images/welcome/screenshot-conditional-equations.png differ diff --git a/assets/images/welcome/screenshot-event-performance-importer.png b/assets/images/welcome/screenshot-event-performance-importer.png deleted file mode 100644 index c38b3eeb..00000000 Binary files a/assets/images/welcome/screenshot-event-performance-importer.png and /dev/null differ diff --git a/assets/images/welcome/screenshot-event-specs.png b/assets/images/welcome/screenshot-event-specs.png new file mode 100644 index 00000000..c2977c83 Binary files /dev/null and b/assets/images/welcome/screenshot-event-specs.png differ diff --git a/assets/images/welcome/screenshot-group-stages.png b/assets/images/welcome/screenshot-group-stages.png deleted file mode 100644 index 54b1525e..00000000 Binary files a/assets/images/welcome/screenshot-group-stages.png and /dev/null differ diff --git a/assets/images/welcome/screenshot-midseason-transfers.png b/assets/images/welcome/screenshot-midseason-transfers.png new file mode 100644 index 00000000..58409dda Binary files /dev/null and b/assets/images/welcome/screenshot-midseason-transfers.png differ diff --git a/assets/images/welcome/screenshot-next-team.png b/assets/images/welcome/screenshot-next-team.png new file mode 100644 index 00000000..9b3401e8 Binary files /dev/null and b/assets/images/welcome/screenshot-next-team.png differ diff --git a/assets/images/welcome/screenshot-officials.png b/assets/images/welcome/screenshot-officials.png deleted file mode 100644 index 75fa1d54..00000000 Binary files a/assets/images/welcome/screenshot-officials.png and /dev/null differ diff --git a/assets/images/welcome/screenshot-performance-icons.png b/assets/images/welcome/screenshot-performance-icons.png deleted file mode 100644 index d14bc39e..00000000 Binary files a/assets/images/welcome/screenshot-performance-icons.png and /dev/null differ diff --git a/assets/images/welcome/screenshot-results-matrix.png b/assets/images/welcome/screenshot-results-matrix.png new file mode 100644 index 00000000..b32b6a44 Binary files /dev/null and b/assets/images/welcome/screenshot-results-matrix.png differ diff --git a/assets/images/welcome/screenshot-sponsor-levels.png b/assets/images/welcome/screenshot-sponsor-levels.png deleted file mode 100644 index b4377ba7..00000000 Binary files a/assets/images/welcome/screenshot-sponsor-levels.png and /dev/null differ diff --git a/assets/images/welcome/screenshot-vertical-timelines.png b/assets/images/welcome/screenshot-vertical-timelines.png new file mode 100644 index 00000000..b880f236 Binary files /dev/null and b/assets/images/welcome/screenshot-vertical-timelines.png differ diff --git a/changelog.txt b/changelog.txt index 81d2ea6c..db312997 100644 --- a/changelog.txt +++ b/changelog.txt @@ -7,6 +7,7 @@ * Feature - Short name option added to teams. * Feature - Automatic event titles using short name when available. * Feature - Display featured image in countdown widget. +* Tweak - Stronger connections between leagues, seasons, and teams for automatic player lists. * Tweak - Relative date option added to editor shortcodes. * Tweak - Display only current team in player list. * Tweak - Filter players dropdown by current team only. diff --git a/includes/admin/class-sp-admin-assets.php b/includes/admin/class-sp-admin-assets.php index 1c5b4c45..e3dec5bd 100755 --- a/includes/admin/class-sp-admin-assets.php +++ b/includes/admin/class-sp-admin-assets.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/admin/class-sp-admin-sports.php b/includes/admin/class-sp-admin-sports.php index 33576416..6a5974a9 100644 --- a/includes/admin/class-sp-admin-sports.php +++ b/includes/admin/class-sp-admin-sports.php @@ -5,7 +5,7 @@ * The SportsPress admin sports class stores preset sport data. * * @class SP_Admin_Sports - * @version 2.5.2 + * @version 2.6 * @package SportsPress/Admin * @category Class * @author ThemeBoy diff --git a/includes/admin/class-sp-admin-taxonomies.php b/includes/admin/class-sp-admin-taxonomies.php index f0cac911..e11b2d9a 100644 --- a/includes/admin/class-sp-admin-taxonomies.php +++ b/includes/admin/class-sp-admin-taxonomies.php @@ -7,7 +7,7 @@ if ( ! defined( 'ABSPATH' ) ) { * Handles taxonomies in admin * * @class SP_Admin_Taxonomies - * @version 2.5.1 + * @version 2.6 * @package SportsPress/Admin * @category Class * @author ThemeBoy diff --git a/includes/admin/class-sp-admin-welcome.php b/includes/admin/class-sp-admin-welcome.php index 4b117480..cc87f02f 100644 --- a/includes/admin/class-sp-admin-welcome.php +++ b/includes/admin/class-sp-admin-welcome.php @@ -133,8 +133,6 @@ class SP_Admin_Welcome { - - -
+
+ Screenshot

Conditional Equations

-

+

Use the newly introduced conditional operators >, <, , , , and to calculate the relationship between variables, then insert that calculation into more complex equations. Visit the Configure page to edit variables and equations.

+ Screenshot

Event Specs

-

-
-
- -
-
-

Countdown Images

-

+

Measure and display additional details per event using the new Event Specs variables. They are customizable and can be useful for keeping track of information like player of the match, attendance, and venue weather.

+ Screenshot

Next Team Column

-

+

Provide a quick overview of who each team is playing next using the new Next Team preset for league table columns. This will automatically display the next team's name or logo that links to the next match for each team in the table.

@@ -213,14 +207,21 @@ class SP_Admin_Welcome {
-
+
+ Results Matrix

Results Matrix

-

+

Display matches between home and away team in a grid. Create or select an existing calendar and select the Matrix layout to convert the calendar to an interactive results matrix!

+ Midseason Transfers +

Midseason Transfers

+

Keep track of players that switched teams during a season by adding one or more extra rows to their statistics table. Display the team and partial statistics before and after the transfer.

+

+
+ Vertical Timelines

Vertical Timelines

-

+

Display a match commentary style play-by-play timeline within events. Upgrade to SportsPress Pro to get access to Timelines and other pro features.

@@ -233,22 +234,22 @@ class SP_Admin_Welcome {
-

Data Accuracy and Flexibility

+

Player Data Improvements

-

Relative Date in Shortcodes

-

+

Player Assignments

+

Players will now be saved using a new data format that allows them to belong to multiple leagues, seasons, and teams and be accurately selected in player lists.

-

Current Team in Player Lists

-

+

Current Team Column

+

The Team column in player lists will now display only the current team that player belongs to, determined by the Current Team setting of each player.

Squad Number Zero

-

+

It's now possible to import players with the squad number 0 (zero) or any other value that would previously be interpreted as empty.

@@ -261,17 +262,17 @@ class SP_Admin_Welcome {
+
+

Countdown Images

+

A new option has been added to the Countdown widget, allowing you to display a featured image from the next event.

+
+
+

Relative Date in Shortcodes

+

You'll now be able to select a relative date range when inserting calendar-related shortcodes from the visual editor.

+

Short Names

-

-
-
-

Calculating Substitution Time

-

-
-
-

Localization Improvements

-

+

Teams have been given a Short Name setting in addition to the existing Abbreviation for added customizability.

diff --git a/includes/admin/importers/class-sp-player-importer.php b/includes/admin/importers/class-sp-player-importer.php index 3117d985..c513b84f 100644 --- a/includes/admin/importers/class-sp-player-importer.php +++ b/includes/admin/importers/class-sp-player-importer.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin/Importers - * @version 2.5.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/admin/post-types/class-sp-admin-cpt-event.php b/includes/admin/post-types/class-sp-admin-cpt-event.php index bae9b5d8..b97bb229 100644 --- a/includes/admin/post-types/class-sp-admin-cpt-event.php +++ b/includes/admin/post-types/class-sp-admin-cpt-event.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin/Post_Types - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/admin/post-types/class-sp-admin-cpt-player.php b/includes/admin/post-types/class-sp-admin-cpt-player.php index 75cf26e5..39fd8d97 100755 --- a/includes/admin/post-types/class-sp-admin-cpt-player.php +++ b/includes/admin/post-types/class-sp-admin-cpt-player.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin/Post_Types - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/admin/post-types/class-sp-admin-cpt-spec.php b/includes/admin/post-types/class-sp-admin-cpt-spec.php index 8318949d..23125e9a 100644 --- a/includes/admin/post-types/class-sp-admin-cpt-spec.php +++ b/includes/admin/post-types/class-sp-admin-cpt-spec.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin/Post_Types - * @version 0.9 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/admin/post-types/class-sp-admin-cpt-team.php b/includes/admin/post-types/class-sp-admin-cpt-team.php index 3a4f2f3a..16d9b451 100644 --- a/includes/admin/post-types/class-sp-admin-cpt-team.php +++ b/includes/admin/post-types/class-sp-admin-cpt-team.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin/Post_Types - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/admin/post-types/meta-boxes/class-sp-meta-box-event-specs.php b/includes/admin/post-types/meta-boxes/class-sp-meta-box-event-specs.php index 1e4e17c2..6ef6fb4c 100644 --- a/includes/admin/post-types/meta-boxes/class-sp-meta-box-event-specs.php +++ b/includes/admin/post-types/meta-boxes/class-sp-meta-box-event-specs.php @@ -1,11 +1,11 @@ $teams, 'readonly' => $readonly ), $id ); ?>
- +
@@ -166,7 +166,7 @@ class SP_Meta_Box_Player_Statistics { if ( $div_id === 0 ) continue; $div = get_term( $div_id, 'sp_season' ); ?> - + @@ -237,10 +237,10 @@ class SP_Meta_Box_Player_Statistics { echo $timeval ? $timeval : $placeholder; } else { if ( 'time' === sp_array_value( $formats, $column, 'number' ) ) { - echo ''; + echo ''; echo ''; } else { - echo ''; + echo ''; } } ?> diff --git a/includes/admin/post-types/meta-boxes/class-sp-meta-box-spec-details.php b/includes/admin/post-types/meta-boxes/class-sp-meta-box-spec-details.php index cc23115f..9ba10dab 100644 --- a/includes/admin/post-types/meta-boxes/class-sp-meta-box-spec-details.php +++ b/includes/admin/post-types/meta-boxes/class-sp-meta-box-spec-details.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin/Meta_Boxes - * @version 1.0 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/admin/post-types/meta-boxes/class-sp-meta-box-staff-details.php b/includes/admin/post-types/meta-boxes/class-sp-meta-box-staff-details.php index e73d0804..9b08d01e 100644 --- a/includes/admin/post-types/meta-boxes/class-sp-meta-box-staff-details.php +++ b/includes/admin/post-types/meta-boxes/class-sp-meta-box-staff-details.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin/Meta_Boxes - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/admin/post-types/meta-boxes/class-sp-meta-box-team-details.php b/includes/admin/post-types/meta-boxes/class-sp-meta-box-team-details.php index c0fe4e8b..646fb2ae 100644 --- a/includes/admin/post-types/meta-boxes/class-sp-meta-box-team-details.php +++ b/includes/admin/post-types/meta-boxes/class-sp-meta-box-team-details.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin/Meta_Boxes - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/admin/settings/class-sp-settings-events.php b/includes/admin/settings/class-sp-settings-events.php index 5834903b..8a66c597 100644 --- a/includes/admin/settings/class-sp-settings-events.php +++ b/includes/admin/settings/class-sp-settings-events.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin - * @version 2.5.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly @@ -278,7 +278,7 @@ class SP_Settings_Events extends SP_Settings_Page { apply_filters( 'sportspress_eventplayer_options', array( array( - 'title' => __( 'Player Sorting', 'sportspress' ), + 'title' => __( 'Order', 'sportspress' ), 'id' => 'sportspress_event_player_sort', 'default' => 'jersey', 'type' => 'radio', @@ -286,8 +286,7 @@ class SP_Settings_Events extends SP_Settings_Page { 'jersey'=> __( 'Jersey (e.g. "33. John Doe")', 'sportspress' ), 'name' => __( 'Name (e.g. "John Doe (33)")', 'sportspress' ), ), - 'desc_tip' => _x( 'When editing an event, this determines how the checklist of players are sorted in the Teams metabox. This does not affect the Box Score section.', 'event player sort setting description', 'sportspress' ), - + 'desc_tip' => 'When editing an event, this determines how the checklist of players are sorted in the Teams metabox. This does not affect the Box Score section.', ), ) ), diff --git a/includes/admin/settings/class-sp-settings-modules.php b/includes/admin/settings/class-sp-settings-modules.php index 2353410a..462927bd 100644 --- a/includes/admin/settings/class-sp-settings-modules.php +++ b/includes/admin/settings/class-sp-settings-modules.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly @@ -74,25 +74,6 @@ class SP_Settings_Modules extends SP_Settings_Page {
- - - - - - - - -
- <?php _e( 'WordPay', 'sportspress' ); ?> -
-

-

- - -

-
- - diff --git a/includes/admin/settings/class-sp-settings-teams.php b/includes/admin/settings/class-sp-settings-teams.php index 9041c13c..3043de94 100644 --- a/includes/admin/settings/class-sp-settings-teams.php +++ b/includes/admin/settings/class-sp-settings-teams.php @@ -5,7 +5,7 @@ * @author ThemeBoy * @category Admin * @package SportsPress/Admin - * @version 2.5.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/class-sp-ajax.php b/includes/class-sp-ajax.php index 2f4e1cc7..8ee51ed4 100644 --- a/includes/class-sp-ajax.php +++ b/includes/class-sp-ajax.php @@ -8,7 +8,7 @@ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly * AJAX Event Handler * * @class SP_AJAX - * @version 2.5.5 + * @version 2.6 * @package SportsPress/Classes * @category Class * @author ThemeBoy diff --git a/includes/class-sp-event.php b/includes/class-sp-event.php index 58756e1d..1b0ae5c9 100644 --- a/includes/class-sp-event.php +++ b/includes/class-sp-event.php @@ -5,7 +5,7 @@ * The SportsPress event class handles individual event data. * * @class SP_Event - * @version 2.5.2 + * @version 2.6 * @package SportsPress/Classes * @category Class * @author ThemeBoy diff --git a/includes/class-sp-league-table.php b/includes/class-sp-league-table.php index ba695566..e2553030 100644 --- a/includes/class-sp-league-table.php +++ b/includes/class-sp-league-table.php @@ -5,7 +5,7 @@ * The SportsPress league table class handles individual league table data. * * @class SP_League_Table - * @version 2.5 + * @version 2.6 * @package SportsPress/Classes * @category Class * @author ThemeBoy diff --git a/includes/class-sp-modules.php b/includes/class-sp-modules.php index 28999782..227e1eb6 100644 --- a/includes/class-sp-modules.php +++ b/includes/class-sp-modules.php @@ -5,7 +5,7 @@ * The SportsPress modules class stores available modules. * * @class SP_Modules - * @version 2.5 + * @version 2.6 * @package SportsPress/Classes * @category Class * @author ThemeBoy @@ -173,14 +173,6 @@ class SP_Modules { 'link' => 'https://www.themeboy.com/sportspress-extensions/sponsors/', 'desc' => __( 'Attract sponsors by offering them advertising space on your website.', 'sportspress' ), ), - 'wordpay' => array( - 'label' => __( 'WordPay', 'sportspress' ), - 'class' => 'WordPay', - 'icon' => 'sp-icon-wordpay', - 'link' => 'https://wordpay.org/sportspress/', - 'desc' => __( 'Start collecting club membership payments with WordPay.', 'sportspress' ), - 'tip' => __( 'Get WordPay', 'sportspress' ), - ), ), )); diff --git a/includes/class-sp-player-list.php b/includes/class-sp-player-list.php index 2f43c78c..f4c1478b 100644 --- a/includes/class-sp-player-list.php +++ b/includes/class-sp-player-list.php @@ -5,7 +5,7 @@ * The SportsPress player list class handles individual player list data. * * @class SP_Player_List - * @version 2.5.5 + * @version 2.6 * @package SportsPress/Classes * @category Class * @author ThemeBoy diff --git a/includes/class-sp-player.php b/includes/class-sp-player.php index 12d9f735..fc54d9b5 100644 --- a/includes/class-sp-player.php +++ b/includes/class-sp-player.php @@ -5,7 +5,7 @@ * The SportsPress player class handles individual player data. * * @class SP_Player - * @version 2.5 + * @version 2.6 * @package SportsPress/Classes * @category Class * @author ThemeBoy @@ -256,8 +256,11 @@ class SP_Player extends SP_Custom_Post { $data = array(); + $league_stats = sp_array_value( $stats, $league_id, array() ); + $div_ids = apply_filters( 'sportspress_player_data_season_ids', $div_ids, $league_stats ); + // Get all seasons populated with data where available - $data = sp_array_combine( $div_ids, sp_array_value( $stats, $league_id, array() ), true ); + $data = sp_array_combine( $div_ids, $league_stats, true ); // Get equations from statistic variables $equations = sp_get_var_equations( 'sp_statistic' ); @@ -340,7 +343,7 @@ class SP_Player extends SP_Custom_Post { ); endif; - $args = apply_filters( 'sportspress_player_data_event_args', $args ); + $args = apply_filters( 'sportspress_player_data_event_args', $args, $data, $div_id ); $events = get_posts( $args ); @@ -597,7 +600,7 @@ class SP_Player extends SP_Custom_Post { if ( -1 == $team_id ) continue; - $season_name = sp_array_value( $season_names, $season_id, ' ' ); + $season_name = sp_array_value( $season_names, (int) $season_id, ' ' ); if ( $team_id ): $team_name = sp_team_short_name( $team_id ); diff --git a/includes/class-sp-post-types.php b/includes/class-sp-post-types.php index 7a3a78e1..31d4dc2b 100644 --- a/includes/class-sp-post-types.php +++ b/includes/class-sp-post-types.php @@ -9,7 +9,7 @@ if ( ! defined( 'ABSPATH' ) ) { * Registers post types and taxonomies * * @class SP_Post_types - * @version 2.5.5 + * @version 2.6 * @package SportsPress/Classes * @category Class * @author ThemeBoy diff --git a/includes/class-sp-team.php b/includes/class-sp-team.php index e429b111..f2146405 100644 --- a/includes/class-sp-team.php +++ b/includes/class-sp-team.php @@ -5,7 +5,7 @@ * The SportsPress team class handles individual team data. * * @class SP_Team - * @version 2.2.4 + * @version 2.6 * @package SportsPress/Classes * @category Class * @author ThemeBoy diff --git a/includes/sp-api-functions.php b/includes/sp-api-functions.php index 89b4ab62..01f17c7c 100644 --- a/includes/sp-api-functions.php +++ b/includes/sp-api-functions.php @@ -7,7 +7,7 @@ * @author ThemeBoy * @category Core * @package SportsPress/Functions - * @version 2.5.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/sp-core-functions.php b/includes/sp-core-functions.php index e8d9828a..4a9949f6 100644 --- a/includes/sp-core-functions.php +++ b/includes/sp-core-functions.php @@ -7,7 +7,7 @@ * @author ThemeBoy * @category Core * @package SportsPress/Functions - * @version 2.5.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/sp-deprecated-functions.php b/includes/sp-deprecated-functions.php index 9369f5d3..e7977f2f 100644 --- a/includes/sp-deprecated-functions.php +++ b/includes/sp-deprecated-functions.php @@ -7,7 +7,7 @@ * @author ThemeBoy * @category Core * @package ThemeBoy/Functions - * @version 1.6.1 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/includes/sp-template-hooks.php b/includes/sp-template-hooks.php index 0a8aed14..7de98ac1 100644 --- a/includes/sp-template-hooks.php +++ b/includes/sp-template-hooks.php @@ -7,7 +7,7 @@ * @author ThemeBoy * @category Core * @package SportsPress/Functions - * @version 2.5.10 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/modules/sportspress-conditional-equations.php b/modules/sportspress-conditional-equations.php index 15c47c0a..bb9d6eea 100644 --- a/modules/sportspress-conditional-equations.php +++ b/modules/sportspress-conditional-equations.php @@ -5,7 +5,7 @@ Plugin URI: http://themeboy.com/ Description: Add conditional equations to SportsPress. Author: ThemeBoy Author URI: http://themeboy.com/ -Version: 2.5.10 +Version: 2.6 */ // Exit if accessed directly @@ -17,7 +17,7 @@ if ( ! class_exists( 'SportsPress_Conditional_Equations' ) ) : * Main SportsPress Conditional Equations Class * * @class SportsPress_Conditional_Equations - * @version 2.5.10 + * @version 2.6 */ class SportsPress_Conditional_Equations { @@ -42,7 +42,7 @@ if ( ! class_exists( 'SportsPress_Conditional_Equations' ) ) : */ private function define_constants() { if ( !defined( 'SP_CONDITIONAL_EQUATIONS_VERSION' ) ) - define( 'SP_CONDITIONAL_EQUATIONS_VERSION', '2.5.10' ); + define( 'SP_CONDITIONAL_EQUATIONS_VERSION', '2.6' ); if ( !defined( 'SP_CONDITIONAL_EQUATIONS_URL' ) ) define( 'SP_CONDITIONAL_EQUATIONS_URL', plugin_dir_url( __FILE__ ) ); diff --git a/modules/sportspress-countdowns.php b/modules/sportspress-countdowns.php index 51585905..1496ff34 100644 --- a/modules/sportspress-countdowns.php +++ b/modules/sportspress-countdowns.php @@ -5,7 +5,7 @@ Plugin URI: http://themeboy.com/ Description: Add countdown widgets to SportsPress. Author: ThemeBoy Author URI: http://themeboy.com/ -Version: 2.0 +Version: 2.6 */ // Exit if accessed directly @@ -17,7 +17,7 @@ if ( ! class_exists( 'SportsPress_Countdowns' ) ) : * Main SportsPress Countdowns Class * * @class SportsPress_Countdowns - * @version 2.0 + * @version 2.6 */ class SportsPress_Countdowns { @@ -41,7 +41,7 @@ class SportsPress_Countdowns { */ private function define_constants() { if ( !defined( 'SP_COUNTDOWNS_VERSION' ) ) - define( 'SP_COUNTDOWNS_VERSION', '2.0' ); + define( 'SP_COUNTDOWNS_VERSION', '2.6' ); if ( !defined( 'SP_COUNTDOWNS_URL' ) ) define( 'SP_COUNTDOWNS_URL', plugin_dir_url( __FILE__ ) ); diff --git a/modules/sportspress-event-specs.php b/modules/sportspress-event-specs.php index 34eab80e..69277bac 100644 --- a/modules/sportspress-event-specs.php +++ b/modules/sportspress-event-specs.php @@ -5,7 +5,7 @@ Plugin URI: http://themeboy.com/ Description: Add event specs/stats to SportsPress. Author: ThemeBoy Author URI: http://themeboy.com/ -Version: 2.5.10 +Version: 2.6 */ // Exit if accessed directly @@ -17,7 +17,7 @@ if ( ! class_exists( 'SportsPress_Event_Specs' ) ) : * Main SportsPress Event Specs Class * * @class SportsPress_Event_Specs - * @version 2.5.10 + * @version 2.6 */ class SportsPress_Event_Specs { @@ -48,7 +48,7 @@ class SportsPress_Event_Specs { */ private function define_constants() { if ( !defined( 'SP_EVENT_SPECS_VERSION' ) ) - define( 'SP_EVENT_SPECS_VERSION', '2.5.10' ); + define( 'SP_EVENT_SPECS_VERSION', '2.6' ); if ( !defined( 'SP_EVENT_SPECS_URL' ) ) define( 'SP_EVENT_SPECS_URL', plugin_dir_url( __FILE__ ) ); diff --git a/modules/sportspress-officials.php b/modules/sportspress-officials.php index c82efe53..b9542617 100644 --- a/modules/sportspress-officials.php +++ b/modules/sportspress-officials.php @@ -5,7 +5,7 @@ Plugin URI: http://themeboy.com/ Description: Add officials to SportsPress. Author: ThemeBoy Author URI: http://themeboy.com/ -Version: 2.5.1 +Version: 2.6 */ // Exit if accessed directly @@ -17,7 +17,7 @@ if ( ! class_exists( 'SportsPress_Officials' ) ) : * Main SportsPress Officials Class * * @class SportsPress_Officials - * @version 2.5.1 + * @version 2.6 */ class SportsPress_Officials { @@ -66,7 +66,7 @@ class SportsPress_Officials { */ private function define_constants() { if ( !defined( 'SP_OFFICIALS_VERSION' ) ) - define( 'SP_OFFICIALS_VERSION', '2.5.1' ); + define( 'SP_OFFICIALS_VERSION', '2.6' ); if ( !defined( 'SP_OFFICIALS_URL' ) ) define( 'SP_OFFICIALS_URL', plugin_dir_url( __FILE__ ) ); diff --git a/modules/sportspress-player-assignments.php b/modules/sportspress-player-assignments.php index a98ba85f..88b407e5 100644 --- a/modules/sportspress-player-assignments.php +++ b/modules/sportspress-player-assignments.php @@ -5,7 +5,7 @@ Plugin URI: http://themeboy.com/ Description: Add player assignments support to SportsPress. Author: Savvas Author URI: http://themeboy.com/ -Version: 2.6.0 +Version: 2.6 */ // Exit if accessed directly if ( ! defined( 'ABSPATH' ) ) exit; @@ -14,7 +14,7 @@ if ( ! class_exists( 'SportsPress_Player_Assignments' ) ) : * Main SportsPress Player Assignments Class * * @class SportsPress_Player_Assignments - * @version 2.6.0 + * @version 2.6 */ class SportsPress_Player_Assignments { /** @@ -36,7 +36,7 @@ class SportsPress_Player_Assignments { */ private function define_constants() { if ( !defined( 'SP_PLAYER_ASSIGNMENTS_VERSION' ) ) - define( 'SP_PLAYER_ASSIGNMENTS_VERSION', '2.6.0' ); + define( 'SP_PLAYER_ASSIGNMENTS_VERSION', '2.6' ); if ( !defined( 'SP_PLAYER_ASSIGNMENTS_URL' ) ) define( 'SP_PLAYER_ASSIGNMENTS_URL', plugin_dir_url( __FILE__ ) ); if ( !defined( 'SP_PLAYER_ASSIGNMENTS_DIR' ) ) @@ -57,7 +57,7 @@ class SportsPress_Player_Assignments { if ( 0 === $l_id ) continue; foreach ( $season as $s_id => $team_id ) { if ( 0 >= $team_id ) continue; - $serialized = $l_id.'_'.$s_id.'_'.$team_id; + $serialized = intval($l_id).'_'.intval($s_id).'_'.intval($team_id); add_post_meta( $post_id, 'sp_assignments', $serialized, false ); } } diff --git a/modules/sportspress-wordpay.php b/modules/sportspress-wordpay.php index a93411cf..f5dab27e 100644 --- a/modules/sportspress-wordpay.php +++ b/modules/sportspress-wordpay.php @@ -5,7 +5,7 @@ Plugin URI: http://themeboy.com/ Description: Add team and player registration shortcodes to WordPay. Author: ThemeBoy Author URI: http://themeboy.com/ -Version: 2.4.1 +Version: 2.6 */ // Exit if accessed directly @@ -17,7 +17,7 @@ if ( ! class_exists( 'SportsPress_WordPay' ) ) : * Main SportsPress WordPay Class * * @class SportsPress_WordPay - * @version 2.4.1 + * @version 2.6 */ class SportsPress_WordPay { @@ -47,7 +47,7 @@ class SportsPress_WordPay { */ private function define_constants() { if ( !defined( 'SP_WORDPAY_VERSION' ) ) - define( 'SP_WORDPAY_VERSION', '2.4.1' ); + define( 'SP_WORDPAY_VERSION', '2.6' ); if ( !defined( 'SP_WORDPAY_URL' ) ) define( 'SP_WORDPAY_URL', plugin_dir_url( __FILE__ ) ); @@ -232,6 +232,4 @@ class SportsPress_WordPay { endif; -if ( get_option( 'sportspress_load_wordpay_module', 'yes' ) == 'yes' ) { - new SportsPress_WordPay(); -} \ No newline at end of file +new SportsPress_WordPay(); \ No newline at end of file diff --git a/readme.txt b/readme.txt index b7d2c0ec..ae3c0ee5 100644 --- a/readme.txt +++ b/readme.txt @@ -4,7 +4,7 @@ Tags: calendars, club, club management, esports, events, fixtures, leagues, leag Donate link: http://tboy.co/donate Requires at least: 3.8 Tested up to: 4.9 -Stable tag: 2.6-RC1 +Stable tag: 2.6 License: GPLv3 License URI: http://www.gnu.org/licenses/gpl-3.0.html @@ -244,6 +244,7 @@ When you upgrade to one of the SportsPress Pro licenses, you can simply activate * Feature - Short name option added to teams. * Feature - Automatic event titles using short name when available. * Feature - Display featured image in countdown widget. +* Tweak - Stronger connections between leagues, seasons, and teams for automatic player lists. * Tweak - Relative date option added to editor shortcodes. * Tweak - Display only current team in player list. * Tweak - Filter players dropdown by current team only. diff --git a/sportspress.php b/sportspress.php index 2232127d..3307203f 100644 --- a/sportspress.php +++ b/sportspress.php @@ -3,7 +3,7 @@ * Plugin Name: SportsPress * Plugin URI: http://themeboy.com/sportspress/ * Description: Manage your club and its players, staff, events, league tables, and player lists. - * Version: 2.6-RC1 + * Version: 2.6 * Author: ThemeBoy * Author URI: http://themeboy.com * Requires at least: 3.8 @@ -26,14 +26,14 @@ if ( ! class_exists( 'SportsPress' ) ) : * Main SportsPress Class * * @class SportsPress - * @version 2.6-RC1 + * @version 2.6 */ final class SportsPress { /** * @var string */ - public $version = '2.6-RC1'; + public $version = '2.6'; /** * @var SportsPress The single instance of the class diff --git a/templates/countdown.php b/templates/countdown.php index e8a5ccfa..de3d81f3 100644 --- a/templates/countdown.php +++ b/templates/countdown.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.5.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/event-list.php b/templates/event-list.php index 64d10040..454ca0f6 100644 --- a/templates/event-list.php +++ b/templates/event-list.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.5.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/event-logos-block.php b/templates/event-logos-block.php index 6c5f3429..1710f6ba 100644 --- a/templates/event-logos-block.php +++ b/templates/event-logos-block.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.2 + * @version 2.6 */ ?>
diff --git a/templates/event-logos-inline.php b/templates/event-logos-inline.php index b8e287ff..7c7e7c6a 100644 --- a/templates/event-logos-inline.php +++ b/templates/event-logos-inline.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.2 + * @version 2.6 */ $team_logos = array(); diff --git a/templates/event-logos.php b/templates/event-logos.php index a6dcd416..392c4a72 100644 --- a/templates/event-logos.php +++ b/templates/event-logos.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.2 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/event-performance.php b/templates/event-performance.php index cc730fc7..684abb8b 100644 --- a/templates/event-performance.php +++ b/templates/event-performance.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/event-results.php b/templates/event-results.php index 07dc2b7f..bae7545d 100644 --- a/templates/event-results.php +++ b/templates/event-results.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/official-details.php b/templates/official-details.php index aac8654f..48be84c1 100644 --- a/templates/official-details.php +++ b/templates/official-details.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/player-details.php b/templates/player-details.php index 249c1949..81560b95 100644 --- a/templates/player-details.php +++ b/templates/player-details.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/player-list.php b/templates/player-list.php index dadd2fa1..723aa263 100644 --- a/templates/player-list.php +++ b/templates/player-list.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.5.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/player-selector.php b/templates/player-selector.php index 4fe1c0cd..43ed3608 100644 --- a/templates/player-selector.php +++ b/templates/player-selector.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.3 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/player-statistics.php b/templates/player-statistics.php index 4ac175ac..f7ed0463 100644 --- a/templates/player-statistics.php +++ b/templates/player-statistics.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.2.4 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly @@ -74,12 +74,7 @@ if ( is_array( $leagues ) ): if ( ! $show_teams ) { $args['hide_teams'] = true; } - - if ( has_action( 'sportspress_player_statistics_league_template' ) ) { - do_action( 'sportspress_player_statistics_league_template', $args ); - } else { - sp_get_template( 'player-statistics-league.php', $args ); - } + sp_get_template( 'player-statistics-league.php', $args ); endforeach; if ( $show_career_totals ) { diff --git a/templates/staff-details.php b/templates/staff-details.php index 6e400e54..ce04eb61 100644 --- a/templates/staff-details.php +++ b/templates/staff-details.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.0 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly diff --git a/templates/staff-header.php b/templates/staff-header.php index df5b8623..0a53d2b4 100644 --- a/templates/staff-header.php +++ b/templates/staff-header.php @@ -4,7 +4,7 @@ * * @author ThemeBoy * @package SportsPress/Templates - * @version 2.5.5 + * @version 2.6 */ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly