Skip to content

Commit

Permalink
Merge branch 'master' into EAR-2291-Update-content-for-calculated-sum…
Browse files Browse the repository at this point in the history
…mary-questions
  • Loading branch information
Farhanam76 authored Feb 19, 2024
2 parents 294f654 + e2fab2f commit bb7e328
Show file tree
Hide file tree
Showing 2 changed files with 60 additions and 1 deletion.
9 changes: 8 additions & 1 deletion eq-author-api/schema/resolvers/importing.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,12 +131,18 @@ module.exports = {
section.displayConditions = null;
section.questionnaireId = ctx.questionnaire.id;
section.folders.forEach((folder) => {
if (folder.listId) {
folder.listId = "";
}
folder.skipConditions = null;
folder.pages.forEach((page) => {
page.routing = null;
page.skipConditions = null;

if (page.pageType !== "ListCollectorPage") {
if (
page.pageType !== "ListCollectorPage" &&
page.answers !== undefined
) {
page.answers.forEach((answer) => {
return stripQCodes(answer);
});
Expand All @@ -152,6 +158,7 @@ module.exports = {
}
});
});

// Fix for missing validation error after importing repeating section
if (section.repeatingSectionListId) {
section.repeatingSectionListId = "";
Expand Down
52 changes: 52 additions & 0 deletions eq-author/src/graphql/importSections.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,58 @@ mutation ImportSections($input: ImportSectionsInput!) {
...Comment
}
}
... on ListCollectorQualifierPage {
id
answers {
id
... on MultipleChoiceAnswer {
...Answer
options {
...Option
}
mutuallyExclusiveOption {
id
}
}
}
comments {
...Comment
}
}
... on ListCollectorAddItemPage {
id
description
descriptionEnabled
guidance
guidanceEnabled
definitionLabel
definitionContent
definitionEnabled
additionalInfoLabel
additionalInfoContent
additionalInfoEnabled
comments {
...Comment
}
}
... on ListCollectorConfirmationPage {
id
answers {
id
... on MultipleChoiceAnswer {
...Answer
options {
...Option
}
mutuallyExclusiveOption {
id
}
}
}
comments {
...Comment
}
}
}
}
}
Expand Down

0 comments on commit bb7e328

Please sign in to comment.