Skip to main content

Prescription Domain

Domain Summary

The Prescription domain manages medical prescriptions for healthcare services provided to clients. It handles the creation, validation, approval, and tracking of prescriptions that authorize specific treatments and services based on medical diagnoses.

This domain enables healthcare providers to document medical prescriptions, track prescribed treatments, validate prescription details against medical and regulatory requirements, and manage the approval process. It serves as a critical component for ensuring that care services are medically justified and properly authorized within the healthcare platform.

Architectural Overview

The Prescription domain follows the standard domain architecture pattern.

Entities

  1. PrescriptionEntity - The aggregate root entity representing a medical prescription with:

    • Client and residential park identification
    • Start and end dates for the prescription's validity
    • Issue date and issuing doctor information
    • ICD-10 diagnostic codes
    • Comments and additional information
    • List of prescribed treatments (BenefitPositionData)
    • Status information
    • Approval details
    • Reference to preceding prescriptions
  2. ApprovalValueObject - Value object containing approval details with:

    • Approval date
    • Approving entity information
    • Approval status
    • Comments or notes
  3. PrescriptionDeviations - Value object representing changes between prescription versions with:

    • Deviation type (metadata, status, treatments)
    • Description of changes
  4. PrescriptionClientDetails - Value object containing client details relevant to prescriptions with:

    • Client identification
    • Client personal information
    • Prescription details

Key Operations

Prescription Management

  • Create new prescriptions with treatments and diagnoses
  • Update existing prescriptions with modified information
  • Approve prescriptions with appropriate authorization
  • Delete prescriptions when necessary
  • Track changes between prescription versions

Prescription Retrieval

  • Get prescriptions by ID
  • Get prescriptions for a specific client
  • Get prescriptions within a date range
  • Find prescriptions for multiple clients
  • Retrieve client diagnoses from prescriptions

Validation

  • Validate prescription details against business rules
  • Validate treatment benefits for medical appropriateness
  • Validate prescription dates for consistency
  • Validate approval information
  • Validate relationships with preceding prescriptions

Notification

  • Notify observers about prescription changes
  • Track and communicate prescription status updates

Integration with Other Domains

The Prescription domain integrates with several other domains:

  1. Client Domain - Prescriptions are associated with clients
  2. Residential Park Domain - Prescriptions are organized by residential parks
  3. Benefit Domain - Prescriptions include benefit positions as treatments
  4. Calendar Domain - Prescriptions generate entries in benefit calendars
  5. Tour Planning Domain - Prescribed treatments influence tour planning