Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Therapy notes aren't tied to a session — add sessionId

Open
#293 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
55/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Domain
database, frontend

Research direction

Start with prisma/schema.prisma:222-263 and trace the existing note flow from pages/patient/patientProfile/[id].vue through components/patient/TherapySection.vue, components/therapy/ReportModal.vue, and composables/therapy/useTherapyNoteForm.ts. Check the session entry points named in the issue, then verify that session-created notes retain their session, history identifies it, and profile-created notes remain optional.

Written by the indexing model from the issue text.

Description

area: patient enhancement P1: high

Part of #285 (Group C — notes correctness).

Problem

The user story says "therapists take notes for those sessions," but a TherapyNote is tied only to a patientId — there is no link to a Session/appointment. Notes are a flat per-patient log distinguished only by createdAt and manually-entered per-field dates.

Evidence

  • prisma/schema.prisma:222-263 — TherapyNote has patientId + relation to Patient; no Session/SessionPatient relation.
  • composables/therapy/useTherapyNoteForm.ts — the POST payload has patientId and free-text date fields but no session identifier; grep for sessionId in the therapy components/composables/notes API finds nothing.
  • Entry point is the patient profile page, not a session: pages/patient/patientProfile/[id].vue → components/patient/TherapySection.vue → components/therapy/ReportModal.vue (the note editor).

Impact

P1. Per-session semantics aren't modeled; two sessions the same day are indistinguishable except by hand-typed dates. Attribution of a note to the encounter it documents is lost.

Proposed approach

  • Add a nullable sessionId FK to TherapyNote referencing Session (migration).
  • Add a note entry point from a session (e.g. from SessionDetailModal / the therapist's calendar) that pre-binds sessionId and patient.
  • Keep the profile-page history but group/label notes by session where present.

Acceptance criteria

  • A note can be created in the context of a specific session and stores its sessionId.
  • The notes history shows which session a note belongs to.
  • Existing patient-level note creation still works (session optional).
Dominant language
Vue
Stars
0
Forks
1
Avg merge
8d 17h
Merged PRs (30d)
1

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from UTDallasEPICS/connected-care

All issues in UTDallasEPICS/connected-care

Similar issues

More Databases issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.