Skip to content

Commit

Permalink
Add missing Tag-related thresholds in manage page
Browse files Browse the repository at this point in the history
Fixes #26119
  • Loading branch information
dregad committed Dec 2, 2019
1 parent 28891e4 commit 2dfb827
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lang/strings_english.txt
Expand Up @@ -1483,6 +1483,13 @@ $s_email_on_sponsorship_changed = 'E-mail on Sponsorship changed';
$s_email_on_relationship_changed = 'E-mail on Relationship changed';
$s_email_on_updated = 'E-mail on Updated';
$s_email_on_monitor = 'E-mail when user starts monitoring';
$s_view_tags = 'View tags attached to a bug';
$s_attach_tags = 'Attach tags to a bug';
$s_detach_tags = 'Detach tags from a bug';
$s_detach_own_tags = 'Detach tags attached by the same user';
$s_create_new_tags = 'Create new tags';
$s_edit_tags = 'Edit tag names and descriptions';
$s_edit_own_tags = 'Edit tags created by the same user';

# Dynamic filters (load filter controls via AJAX upon request)
$s_loading = 'Loading...';
Expand Down
11 changes: 11 additions & 0 deletions manage_config_work_threshold_page.php
Expand Up @@ -408,6 +408,17 @@ function get_section_end() {
get_capability_row( lang_get( 'change_view_state_own_bugnotes' ), 'bugnote_user_change_view_state_threshold' );
get_section_end();

# Tags
get_section_begin_mcwt( lang_get( 'tags' ) );
get_capability_row( lang_get( 'view_tags' ), 'tag_view_threshold' );
get_capability_row( lang_get( 'attach_tags' ), 'tag_attach_threshold' );
get_capability_row( lang_get( 'detach_tags' ), 'tag_detach_threshold' );
get_capability_row( lang_get( 'detach_own_tags' ), 'tag_detach_own_threshold' );
get_capability_row( lang_get( 'create_new_tags' ), 'tag_create_threshold' );
get_capability_row( lang_get( 'edit_tags' ), 'tag_edit_threshold' );
get_capability_row( lang_get( 'edit_own_tags' ), 'tag_edit_own_threshold' );
get_section_end();

# Others
get_section_begin_mcwt( lang_get( 'others' ) );
get_capability_row( lang_get( 'view' ) . ' ' . lang_get( 'changelog_link' ), 'view_changelog_threshold' );
Expand Down
10 changes: 10 additions & 0 deletions manage_config_work_threshold_set.php
Expand Up @@ -189,6 +189,16 @@ function set_capability_enum( $p_threshold, $p_all_projects_only = false ) {
set_capability_row( 'private_bugnote_threshold' );
set_capability_row( 'bugnote_user_change_view_state_threshold' );

# Tags

set_capability_row( 'tag_view_threshold' );
set_capability_row( 'tag_attach_threshold' );
set_capability_row( 'tag_detach_threshold' );
set_capability_row( 'tag_detach_own_threshold' );
set_capability_row( 'tag_create_threshold' );
set_capability_row( 'tag_edit_threshold' );
set_capability_row( 'tag_edit_own_threshold' );

# Others
set_capability_row( 'view_changelog_threshold' );
set_capability_row( 'roadmap_view_threshold' );
Expand Down

0 comments on commit 2dfb827

Please sign in to comment.