From f7e83434e312ca6cf598c6d815fe32dc200e3056 Mon Sep 17 00:00:00 2001 From: GitLab Bot Date: Thu, 18 Nov 2021 09:10:16 +0000 Subject: [PATCH] Add latest changes from gitlab-org/gitlab@master --- .../components/board_filtered_search.vue | 22 ++++++++++- .../issue_board_filtered_search.vue | 20 ++-------- .../javascripts/boards/stores/actions.js | 1 - .../tokens/iteration_token.vue | 8 +--- .../labels_select_vue/labels_select_root.vue | 2 + app/controllers/concerns/notes_actions.rb | 2 + .../admin/propagate_service_template.rb | 11 ------ .../concerns/admin/propagate_service.rb | 37 ------------------- .../propagate_service.rb} | 30 +++++++++++++-- .../propagate_template_service.rb | 10 +++++ .../shared/issuable/form/_title.html.haml | 2 +- app/workers/propagate_integration_worker.rb | 2 +- .../propagate_service_template_worker.rb | 2 +- doc/administration/audit_events.md | 2 +- doc/administration/auth/ldap/index.md | 3 +- .../database/loose_foreign_keys.md | 8 ++++ .../database/multiple_databases.md | 28 ++++++++++++++ doc/user/tasks.md | 9 +++-- locale/gitlab.pot | 2 +- .../user_sees_wip_help_message_spec.rb | 4 +- .../components/board_filtered_search_spec.js | 3 +- .../propagate_service_spec.rb} | 2 +- .../propagate_integration_worker_spec.rb | 2 +- 23 files changed, 123 insertions(+), 89 deletions(-) delete mode 100644 app/services/admin/propagate_service_template.rb delete mode 100644 app/services/concerns/admin/propagate_service.rb rename app/services/{admin/propagate_integration_service.rb => integrations/propagate_service.rb} (68%) create mode 100644 app/services/integrations/propagate_template_service.rb rename spec/services/{admin/propagate_integration_service_spec.rb => integrations/propagate_service_spec.rb} (98%) diff --git a/app/assets/javascripts/boards/components/board_filtered_search.vue b/app/assets/javascripts/boards/components/board_filtered_search.vue index 6e6ada2d109..6fa5f018875 100644 --- a/app/assets/javascripts/boards/components/board_filtered_search.vue +++ b/app/assets/javascripts/boards/components/board_filtered_search.vue @@ -39,6 +39,7 @@ export default { assigneeUsername, search, milestoneTitle, + iterationId, types, weight, epicId, @@ -83,6 +84,13 @@ export default { }); } + if (iterationId) { + filteredSearchValue.push({ + type: 'iteration', + value: { data: iterationId, operator: '=' }, + }); + } + if (weight) { filteredSearchValue.push({ type: 'weight', @@ -118,6 +126,13 @@ export default { }); } + if (this.filterParams['not[iteration_id]']) { + filteredSearchValue.push({ + type: 'iteration_id', + value: { data: this.filterParams['not[iteration_id]'], operator: '!=' }, + }); + } + if (this.filterParams['not[weight]']) { filteredSearchValue.push({ type: 'weight', @@ -179,8 +194,8 @@ export default { weight, epicId, myReactionEmoji, + iterationId, } = this.filterParams; - let notParams = {}; if (Object.prototype.hasOwnProperty.call(this.filterParams, 'not')) { @@ -194,6 +209,7 @@ export default { 'not[weight]': this.filterParams.not.weight, 'not[epic_id]': this.filterParams.not.epicId, 'not[my_reaction_emoji]': this.filterParams.not.myReactionEmoji, + 'not[iteration_id]': this.filterParams.not.iterationId, }, undefined, ); @@ -205,6 +221,7 @@ export default { 'label_name[]': labelName, assignee_username: assigneeUsername, milestone_title: milestoneTitle, + iteration_id: iterationId, search, types, weight, @@ -261,6 +278,9 @@ export default { case 'milestone_title': filterParams.milestoneTitle = filter.value.data; break; + case 'iteration': + filterParams.iterationId = filter.value.data; + break; case 'weight': filterParams.weight = filter.value.data; break; diff --git a/app/assets/javascripts/boards/components/issue_board_filtered_search.vue b/app/assets/javascripts/boards/components/issue_board_filtered_search.vue index bdb9c2be836..c20b5e3f377 100644 --- a/app/assets/javascripts/boards/components/issue_board_filtered_search.vue +++ b/app/assets/javascripts/boards/components/issue_board_filtered_search.vue @@ -12,6 +12,7 @@ import { __ } from '~/locale'; import { DEFAULT_MILESTONES_GRAPHQL, TOKEN_TITLE_MY_REACTION, + OPERATOR_IS_AND_IS_NOT, } from '~/vue_shared/components/filtered_search_bar/constants'; import AuthorToken from '~/vue_shared/components/filtered_search_bar/tokens/author_token.vue'; import EmojiToken from '~/vue_shared/components/filtered_search_bar/tokens/emoji_token.vue'; @@ -35,8 +36,6 @@ export default { issue: __('Issue'), milestone: __('Milestone'), weight: __('Weight'), - is: __('is'), - isNot: __('is not'), }, components: { BoardFilteredSearch }, inject: ['isSignedIn'], @@ -62,8 +61,6 @@ export default { tokensCE() { const { label, - is, - isNot, author, assignee, issue, @@ -84,10 +81,7 @@ export default { icon: 'user', title: assignee, type: 'assignee_username', - operators: [ - { value: '=', description: is }, - { value: '!=', description: isNot }, - ], + operators: OPERATOR_IS_AND_IS_NOT, token: AuthorToken, unique: true, fetchAuthors, @@ -97,10 +91,7 @@ export default { icon: 'pencil', title: author, type: 'author_username', - operators: [ - { value: '=', description: is }, - { value: '!=', description: isNot }, - ], + operators: OPERATOR_IS_AND_IS_NOT, symbol: '@', token: AuthorToken, unique: true, @@ -111,10 +102,7 @@ export default { icon: 'labels', title: label, type: 'label_name', - operators: [ - { value: '=', description: is }, - { value: '!=', description: isNot }, - ], + operators: OPERATOR_IS_AND_IS_NOT, token: LabelToken, unique: false, symbol: '~', diff --git a/app/assets/javascripts/boards/stores/actions.js b/app/assets/javascripts/boards/stores/actions.js index 3a96e535cf7..5a111cdf81b 100644 --- a/app/assets/javascripts/boards/stores/actions.js +++ b/app/assets/javascripts/boards/stores/actions.js @@ -373,7 +373,6 @@ export default { commit(types.REQUEST_ITEMS_FOR_LIST, { listId, fetchNext }); const { fullPath, fullBoardId, boardType, filterParams } = state; - const variables = { fullPath, boardId: fullBoardId, diff --git a/app/assets/javascripts/vue_shared/components/filtered_search_bar/tokens/iteration_token.vue b/app/assets/javascripts/vue_shared/components/filtered_search_bar/tokens/iteration_token.vue index aff93ebc9c0..4a1dbf9d3fe 100644 --- a/app/assets/javascripts/vue_shared/components/filtered_search_bar/tokens/iteration_token.vue +++ b/app/assets/javascripts/vue_shared/components/filtered_search_bar/tokens/iteration_token.vue @@ -1,7 +1,6 @@