Skip to content

Commit

Permalink
Merge branch '9.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
petmongrels committed Jun 19, 2024
2 parents 7547738 + 2043abd commit 1821bb0
Show file tree
Hide file tree
Showing 2 changed files with 2,652 additions and 86 deletions.
9 changes: 8 additions & 1 deletion src/dataEntryApp/sagas/enrolmentSaga.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,12 @@ function* setupNewEnrolmentWorker({ subjectTypeName, programName, formType, prog
identifierAssignmentService.addIdentifiersToObservations(enrolForm, programEnrolment.observations, identifierAssignments);
}

const { formElementGroup, filteredFormElements, onSummaryPage, wizard, isFormEmpty } = commonFormUtil.onLoad(enrolForm, programEnrolment);
const { formElementGroup, filteredFormElements, onSummaryPage, wizard, isFormEmpty } = commonFormUtil.onLoad(
enrolForm,
programEnrolment,
false,
!isNewEnrolment
);
yield put.resolve(
onLoadSuccess(
programEnrolment,
Expand Down Expand Up @@ -195,6 +200,7 @@ export function* updateEnrolmentObsWorker({ formElement, value, childFormElement
function* addNewQuestionGroupWatcher() {
yield takeEvery(enrolmentTypes.ADD_NEW_QG, addNewQuestionGroupWorker);
}

export function* addNewQuestionGroupWorker({ formElement }) {
const state = yield select(selectProgramEnrolmentState);
const programEnrolment = state.programEnrolment.cloneForEdit();
Expand All @@ -211,6 +217,7 @@ export function* addNewQuestionGroupWorker({ formElement }) {
function* removeQuestionGroupWatcher() {
yield takeEvery(enrolmentTypes.REMOVE_QG, removeQuestionGroupWorker);
}

export function* removeQuestionGroupWorker({ formElement, questionGroupIndex }) {
const state = yield select(selectProgramEnrolmentState);
const programEnrolment = state.programEnrolment.cloneForEdit();
Expand Down
Loading

0 comments on commit 1821bb0

Please sign in to comment.