Skip to content

Commit

Permalink
RecentInteraction: comment old store properties
Browse files Browse the repository at this point in the history
  • Loading branch information
anantmittal committed Jul 18, 2024
1 parent ff48e54 commit 7875874
Showing 1 changed file with 17 additions and 30 deletions.
47 changes: 17 additions & 30 deletions web_registry/src/components/PatientDetail/RecentInteraction.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ export const RecentInteraction: FunctionComponent = observer(() => {
currentPatient?.loadSessionsState.error ||
currentPatient?.loadAssessmentLogsState.error;

console.log(currentPatient.activityLogsSortedByDateAndTimeDescending);
console.log(currentPatient.recentActivityLogsSortedByDateAndTimeDescending);

return (
<ActionPanel
id="recent-interaction"
Expand All @@ -36,23 +39,23 @@ export const RecentInteraction: FunctionComponent = observer(() => {
label="Patient Interaction Date"
value={currentPatient.recentInteractionCutoffDateTime}
/>
<GridTextField
{/* <GridTextField
sm={3}
label="Activities Count"
value={
currentPatient.recentActivities
? currentPatient.recentActivities.length
: "No Recent Activities"
}
/>
<GridTextField
/> */}
{/* <GridTextField
sm={3}
label="Activities"
value={currentPatient.recentActivities
?.map((activity) => activity.name)
.join(", ")}
multiline={true}
/>
/> */}
<GridTextField
sm={3}
label="Values Count"
Expand All @@ -70,44 +73,28 @@ export const RecentInteraction: FunctionComponent = observer(() => {
.join(", ")}
multiline={true}
/>
{/* <GridTextField
sm={9}
label="Activity Logs"
value={currentPatient.recentActivityLogs
?.map(
(activityLog) =>
activityLog.dataSnapshot.scheduledActivity.dataSnapshot.activity
.name,
)
.join(", ")}
multiline={true}
/> */}
<GridTextField
sm={3}
label="Activity Schedules Count"
label="Activity Logs Counts"
value={
currentPatient.recentActivitySchedules
? currentPatient.recentActivitySchedules.length
: "No Recent Activity Schedules"
currentPatient.recentActivityLogsSortedByDateAndTimeDescending
?.length
}
/>
{/* <GridTextField
sm={3}
label="Activity Schedules Count"
value={currentPatient.recentActivitySchedules?.length}
/> */}
<GridTextField
sm={3}
label="Assessment Logs Count"
value={
currentPatient.recentAssessmentLogs
? currentPatient.recentAssessmentLogs.length
: "No Recent Assessment Logs"
}
value={currentPatient.recentAssessmentLogs?.length}
/>
<GridTextField
sm={3}
label="Mood Logs Count"
value={
currentPatient.recentMoodLogs
? currentPatient.recentMoodLogs.length
: "No Recent Mood Logs"
}
value={currentPatient.recentMoodLogs?.length}
/>
<GridTextField
sm={3}
Expand Down

0 comments on commit 7875874

Please sign in to comment.