diff options
author | Robert Schilling <rschilling@student.tugraz.at> | 2019-02-06 15:31:56 +0300 |
---|---|---|
committer | Robert Schilling <rschilling@student.tugraz.at> | 2019-02-21 16:02:38 +0300 |
commit | bd9ae901ec0bc0f9d1060e9128ecd5f8d8127671 (patch) | |
tree | 2b0db5ffbc5c37d8e78ff30387c1b48394a687fd /app/assets/javascripts/filtered_search | |
parent | 3de4c8d0462aba1e254a255c438c80092109edf7 (diff) |
Ability to filter confidential issues
Add a new search bar filter for confidential issues. Add filtering
support to the IssuesFinder.
Diffstat (limited to 'app/assets/javascripts/filtered_search')
-rw-r--r-- | app/assets/javascripts/filtered_search/filtered_search_dropdown_manager.js | 5 | ||||
-rw-r--r-- | app/assets/javascripts/filtered_search/filtered_search_token_keys.js | 17 |
2 files changed, 22 insertions, 0 deletions
diff --git a/app/assets/javascripts/filtered_search/filtered_search_dropdown_manager.js b/app/assets/javascripts/filtered_search/filtered_search_dropdown_manager.js index 57ec6603d80..4d05f46ed17 100644 --- a/app/assets/javascripts/filtered_search/filtered_search_dropdown_manager.js +++ b/app/assets/javascripts/filtered_search/filtered_search_dropdown_manager.js @@ -96,6 +96,11 @@ export default class FilteredSearchDropdownManager { gl: DropdownNonUser, element: this.container.querySelector('#js-dropdown-wip'), }, + confidential: { + reference: null, + gl: DropdownNonUser, + element: this.container.querySelector('#js-dropdown-confidential'), + }, status: { reference: null, gl: NullDropdown, diff --git a/app/assets/javascripts/filtered_search/filtered_search_token_keys.js b/app/assets/javascripts/filtered_search/filtered_search_token_keys.js index b70da240833..48534bdf815 100644 --- a/app/assets/javascripts/filtered_search/filtered_search_token_keys.js +++ b/app/assets/javascripts/filtered_search/filtered_search_token_keys.js @@ -72,6 +72,23 @@ export default class FilteredSearchTokenKeys { ); } + addExtraTokensForIssues() { + const confidentialToken = { + key: 'confidential', + type: 'string', + param: '', + symbol: '', + icon: 'eye-slash', + tag: 'Yes or No', + lowercaseValueOnSubmit: true, + uppercaseTokenName: false, + capitalizeTokenValue: true, + }; + + this.tokenKeys.push(confidentialToken); + this.tokenKeysWithAlternative.push(confidentialToken); + } + addExtraTokensForMergeRequests() { const wipToken = { key: 'wip', |