Skip to content

Commit

Permalink
POC-511: added VL reminder check
Browse files Browse the repository at this point in the history
  • Loading branch information
hiqedme committed Sep 4, 2023
1 parent eb89b31 commit e481812
Showing 1 changed file with 18 additions and 13 deletions.
31 changes: 18 additions & 13 deletions service/patient-reminder.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,19 +84,24 @@ function viralLoadReminders(data) {
});
} // adults
else if (isAdult && data.needs_vl_coded === 3) {
reminders.push({
message:
requires +
'.Patients older than 25 years and newly on ART require ' +
'a viral load test after 12 months. ' +
labMessage,
title: 'Viral Load Reminder',
type: 'danger',
display: {
banner: true,
toast: true
}
});
if (
(data.viral_load > 200 && data.months_since_last_vl_date > 3) ||
(data.viral_load < 200 && data.months_since_last_vl_date > 6)
) {
reminders.push({
message:
requires +
'.Patients older than 25 years and newly on ART require ' +
'a viral load test after 12 months. ' +
labMessage,
title: 'Viral Load Reminder',
type: 'danger',
display: {
banner: true,
toast: true
}
});
}
} else if (
isAdult &&
(data.needs_vl_coded === 8) & (data.months_since_last_vl_date >= 12)
Expand Down

0 comments on commit e481812

Please sign in to comment.