Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/graphql/mutations/jira_import/start.rb')
-rw-r--r--app/graphql/mutations/jira_import/start.rb9
1 files changed, 7 insertions, 2 deletions
diff --git a/app/graphql/mutations/jira_import/start.rb b/app/graphql/mutations/jira_import/start.rb
index 3df26d33711..eda28059272 100644
--- a/app/graphql/mutations/jira_import/start.rb
+++ b/app/graphql/mutations/jira_import/start.rb
@@ -21,12 +21,17 @@ module Mutations
argument :jira_project_name, GraphQL::STRING_TYPE,
required: false,
description: 'Project name of the importer Jira project'
+ argument :users_mapping,
+ [Types::JiraUsersMappingInputType],
+ required: false,
+ description: 'The mapping of Jira to GitLab users'
- def resolve(project_path:, jira_project_key:)
+ def resolve(project_path:, jira_project_key:, users_mapping:)
project = authorized_find!(full_path: project_path)
+ mapping = users_mapping.to_ary.map { |map| map.to_hash }
service_response = ::JiraImport::StartImportService
- .new(context[:current_user], project, jira_project_key)
+ .new(context[:current_user], project, jira_project_key, mapping)
.execute
jira_import = service_response.success? ? service_response.payload[:import_data] : nil