Skip to content

Commit

Permalink
Merge pull request #28 from EyeSeeTea/fix/show-orgunit-name-edit-bug
Browse files Browse the repository at this point in the history
Fix OrgUnit name not showing up & fix edit bug
  • Loading branch information
MiquelAdell authored Apr 3, 2024
2 parents 9151cdc + b063212 commit e038db7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/data/utils/surveyListMappers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export const mapTrackedEntityToSurvey = (
status: "ACTIVE",
assignedOrgUnit: {
id: trackedEntity.orgUnit ?? "",
name: "",
name: trackedEntity.enrollments?.[0]?.orgUnitName ?? "",
},
surveyType: "",
parentWardRegisterId: undefined,
Expand Down
2 changes: 1 addition & 1 deletion src/domain/usecases/ApplyInitialRulesToSurveyUseCase.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export class ApplyInitialRulesToSurveyUseCase {
const currentParentId =
module?.name === "PPS" ? currentPPSSurveyForm : currentPrevalenceSurveyForm;

const currentSurveyRules = module?.rulesBySurvey.find(
const currentSurveyRules = module?.rulesBySurvey?.find(
rule => rule.surveyId === currentParentId
)?.surveyRules;

Expand Down

0 comments on commit e038db7

Please sign in to comment.