Skip to content

Commit

Permalink
Add empty questionnaire response items for repeat groups without answers
Browse files Browse the repository at this point in the history
  • Loading branch information
Rkareko committed Oct 10, 2024
1 parent 45b96ff commit c6715e6
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -941,13 +941,10 @@ internal fun QuestionnaireItemComponent.createQuestionnaireResponseItem():
) {
this.copyNestedItemsToChildlessAnswers(this@createQuestionnaireResponseItem)
} else if (
this@createQuestionnaireResponseItem.type == Questionnaire.QuestionnaireItemType.GROUP &&
!repeats
this@createQuestionnaireResponseItem.type == Questionnaire.QuestionnaireItemType.GROUP
) {
this@createQuestionnaireResponseItem.item.forEach {
if (!it.isRepeatedGroup) {
this.addItem(it.createQuestionnaireResponseItem())
}
}
}
}
Expand Down

0 comments on commit c6715e6

Please sign in to comment.