diff --git a/client/src/elm/Pages/Prenatal/Activity/Utils.elm b/client/src/elm/Pages/Prenatal/Activity/Utils.elm index 17a8f88680..39f30f2a17 100644 --- a/client/src/elm/Pages/Prenatal/Activity/Utils.elm +++ b/client/src/elm/Pages/Prenatal/Activity/Utils.elm @@ -1929,8 +1929,7 @@ matchLabResultsAndExaminationPrenatalDiagnosis egaInWeeks dangerSigns assembled (\egaWeeks -> (egaWeeks >= 20) && (egaWeeks < 37) - && moderatePreeclampsiaByMeasurementsInitialPhase - measurements + && moderatePreeclampsiaByMeasurementsInitialPhase measurements ) DiagnosisModeratePreeclampsiaRecurrentPhase -> @@ -1942,7 +1941,7 @@ matchLabResultsAndExaminationPrenatalDiagnosis egaInWeeks dangerSigns assembled (not <| diagnosedModeratePreeclampsiaPrevoiusly assembled) && -- If diagnosed Moderate Preeclampsia at initial stage, we do not -- need to diagnose again. - (not <| diagnosed DiagnosisModeratePreeclampsiaInitialPhase assembled) + (not <| diagnosedAtInitalPhase DiagnosisModeratePreeclampsiaInitialPhase) && resolveEGAWeeksAndThen (\egaWeeks -> (egaWeeks >= 20) @@ -1960,7 +1959,7 @@ matchLabResultsAndExaminationPrenatalDiagnosis egaInWeeks dangerSigns assembled DiagnosisSeverePreeclampsiaRecurrentPhase -> (-- If diagnosed Severe Preeclampsia at initial stage, we do not -- need to diagnose again. - not <| diagnosed DiagnosisSeverePreeclampsiaInitialPhase assembled + not <| diagnosedAtInitalPhase DiagnosisSeverePreeclampsiaInitialPhase ) && resolveEGAWeeksAndThen (\egaWeeks -> @@ -2081,7 +2080,7 @@ matchLabResultsAndExaminationPrenatalDiagnosis egaInWeeks dangerSigns assembled ) Backend.PrenatalEncounter.Types.DiagnosisDiabetesRecurrentPhase -> - (not <| diagnosed Backend.PrenatalEncounter.Types.DiagnosisDiabetesInitialPhase assembled) + (not <| diagnosedAtInitalPhase Backend.PrenatalEncounter.Types.DiagnosisDiabetesInitialPhase) && (not <| diagnosedPreviouslyAnyOf diabetesDiagnoses assembled) && resolveEGAWeeksAndThen (\egaWeeks -> @@ -2096,7 +2095,7 @@ matchLabResultsAndExaminationPrenatalDiagnosis egaInWeeks dangerSigns assembled ) Backend.PrenatalEncounter.Types.DiagnosisGestationalDiabetesRecurrentPhase -> - (not <| diagnosed Backend.PrenatalEncounter.Types.DiagnosisGestationalDiabetesInitialPhase assembled) + (not <| diagnosedAtInitalPhase Backend.PrenatalEncounter.Types.DiagnosisGestationalDiabetesInitialPhase) && (not <| diagnosedPreviouslyAnyOf diabetesDiagnoses assembled) && resolveEGAWeeksAndThen (\egaWeeks -> diff --git a/client/src/elm/Pages/Prenatal/ProgressReport/Update.elm b/client/src/elm/Pages/Prenatal/ProgressReport/Update.elm index 9d32c074e5..061345cd87 100644 --- a/client/src/elm/Pages/Prenatal/ProgressReport/Update.elm +++ b/client/src/elm/Pages/Prenatal/ProgressReport/Update.elm @@ -76,7 +76,7 @@ update msg model = ( updatedModel, Cmd.none, [] ) ReviewAndAcceptLabsResults personId encounterId labsResultsId value -> - ( model + ( { model | labResultsMode = Nothing, labResultsHistoryOrigin = Nothing } , Cmd.none , [ Backend.PrenatalEncounter.Model.SaveLabsResults personId (Just labsResultsId) { value | reviewState = Just LabsResultsReviewCompleted } |> Backend.Model.MsgPrenatalEncounter encounterId diff --git a/client/src/elm/Pages/Prenatal/Utils.elm b/client/src/elm/Pages/Prenatal/Utils.elm index 4874de07e3..4a61532acf 100644 --- a/client/src/elm/Pages/Prenatal/Utils.elm +++ b/client/src/elm/Pages/Prenatal/Utils.elm @@ -3913,11 +3913,17 @@ healthEducationFormInputsAndTasksForNurse language phase setBoolInputMsg assembl if diagnosedAnyOf triggeringDiagnoses assembled then let header = - if diagnosed Backend.PrenatalEncounter.Types.DiagnosisDiabetesRecurrentPhase assembled then - Translate.PrenatalDiagnosis Backend.PrenatalEncounter.Types.DiagnosisDiabetesRecurrentPhase + if + diagnosedAnyOf + [ Backend.PrenatalEncounter.Types.DiagnosisDiabetesInitialPhase + , Backend.PrenatalEncounter.Types.DiagnosisDiabetesRecurrentPhase + ] + assembled + then + Translate.Diabetes else - Translate.PrenatalDiagnosis Backend.PrenatalEncounter.Types.DiagnosisGestationalDiabetesRecurrentPhase + Translate.GestationalDiabetes in ( [ viewCustomLabel language header "" "label header" , viewCustomLabel language Translate.PrenatalHealthEducationDiabetesInform "." "label paragraph" diff --git a/client/src/elm/Pages/Report/Utils.elm b/client/src/elm/Pages/Report/Utils.elm index 7d0e70b607..fd6888f8cf 100644 --- a/client/src/elm/Pages/Report/Utils.elm +++ b/client/src/elm/Pages/Report/Utils.elm @@ -101,7 +101,7 @@ randomBloodSugarResultNormal result = value >= 74 && value <= 126 TestRunAfterMeal value -> - value >= 74 && value <= 200 + value >= 74 && value < 200 hemoglobinResultNormal : Float -> Bool