Add capabilities to taxonomies

This commit is contained in:
Brian Miyaji
2016-08-20 16:43:32 +10:00
parent 0d55037ffa
commit 64d8a64e1f

View File

@@ -55,6 +55,7 @@ class SP_Post_types {
'show_tagcloud' => false,
'hierarchical' => true,
'rewrite' => array( 'slug' => get_option( 'sportspress_league_slug', 'league' ) ),
'capabilities' => array( 'edit_sp_event' ),
'show_in_rest' => true,
'rest_controller_class' => 'SP_REST_Posts_Controller',
'rest_base' => 'leagues',
@@ -89,6 +90,7 @@ class SP_Post_types {
'show_tagcloud' => false,
'hierarchical' => true,
'rewrite' => array( 'slug' => get_option( 'sportspress_season_slug', 'season' ) ),
'capabilities' => array( 'edit_sp_event' ),
'show_in_rest' => true,
'rest_controller_class' => 'SP_REST_Posts_Controller',
'rest_base' => 'seasons',
@@ -123,6 +125,7 @@ class SP_Post_types {
'show_tagcloud' => false,
'hierarchical' => true,
'rewrite' => array( 'slug' => get_option( 'sportspress_venue_slug', 'venue' ) ),
'capabilities' => array( 'edit_sp_event' ),
'show_in_rest' => true,
'rest_controller_class' => 'SP_REST_Posts_Controller',
'rest_base' => 'venues',
@@ -157,6 +160,7 @@ class SP_Post_types {
'show_tagcloud' => false,
'hierarchical' => true,
'rewrite' => array( 'slug' => get_option( 'sportspress_position_slug', 'position' ) ),
'capabilities' => array( 'edit_sp_player' ),
'show_in_rest' => true,
'rest_controller_class' => 'SP_REST_Posts_Controller',
'rest_base' => 'positions',
@@ -191,6 +195,7 @@ class SP_Post_types {
'show_tagcloud' => false,
'hierarchical' => true,
'rewrite' => array( 'slug' => get_option( 'sportspress_role_slug', 'role' ) ),
'capabilities' => array( 'edit_sp_event' ),
'show_in_rest' => true,
'rest_controller_class' => 'SP_REST_Posts_Controller',
'rest_base' => 'roles',