Commit d5f071c1 authored by Nicolò Maria Mezzopera's avatar Nicolò Maria Mezzopera

Merge branch '295617-foss-master-broken-spec-features-boards-multiple_boards_spec-rb' into 'master'

[RUN-AS-IF-FOSS] Change createBoard input

See merge request gitlab-org/gitlab!50564
parents 4ed3010b bf01c551
...@@ -162,21 +162,27 @@ export default { ...@@ -162,21 +162,27 @@ export default {
mutationVariables() { mutationVariables() {
const { board } = this; const { board } = this;
/* eslint-disable @gitlab/require-i18n-strings */ /* eslint-disable @gitlab/require-i18n-strings */
const baseMutationVariables = { let baseMutationVariables = {
name: board.name, name: board.name,
weight: board.weight,
assigneeId: board.assignee?.id ? convertToGraphQLId('User', board.assignee.id) : null,
milestoneId:
board.milestone?.id || board.milestone?.id === 0
? convertToGraphQLId('Milestone', board.milestone.id)
: null,
labelIds: board.labels.map(fullLabelId),
hideBacklogList: board.hide_backlog_list, hideBacklogList: board.hide_backlog_list,
hideClosedList: board.hide_closed_list, hideClosedList: board.hide_closed_list,
iterationId: board.iteration_id
? convertToGraphQLId('Iteration', board.iteration_id)
: null,
}; };
if (this.scopedIssueBoardFeatureEnabled) {
baseMutationVariables = {
...baseMutationVariables,
weight: board.weight,
assigneeId: board.assignee?.id ? convertToGraphQLId('User', board.assignee.id) : null,
milestoneId:
board.milestone?.id || board.milestone?.id === 0
? convertToGraphQLId('Milestone', board.milestone.id)
: null,
labelIds: board.labels.map(fullLabelId),
iterationId: board.iteration_id
? convertToGraphQLId('Iteration', board.iteration_id)
: null,
};
}
/* eslint-enable @gitlab/require-i18n-strings */ /* eslint-enable @gitlab/require-i18n-strings */
return board.id return board.id
? { ? {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment