Skip to content

d3uceY/Lifeville-Hospital-Management-System

Repository files navigation

Lifeville HMS — Frontend

Lifeville HMS is a modern, full-featured Hospital Management System designed for clinical environments. This repository contains the React frontend that communicates with the Lifeville HMS API.


Features

Patient Management

  • Register patients with full demographics, contact details, next of kin, and medical history (allergies, drug history, family history, social history)
  • View, edit, and search patient profiles
  • Patient profile sidebar with quick navigation to all clinical sections

Appointments

  • Schedule, view, edit, and cancel appointments
  • Filter by upcoming, active, and past appointments
  • Appointment status tracking with colour-coded badges

Inpatient Admissions

  • Admit patients to specific wards and beds
  • Track admission details, symptoms, and consultant doctor
  • Discharge patients with a formal discharge summary including final diagnosis (ICD-10-CM), treatment given, outcome, condition at discharge, and follow-up instructions

Vital Signs

  • Record temperature, blood pressure (systolic/diastolic), pulse rate, SpO₂, weight, and height
  • Automatic BMI calculation from weight (kg) and height (cm)
  • Vitals history table per patient with formatted display

Diagnoses

  • Record diagnoses using the ICD-10-CM standard (searchable combobox with debounced live search)
  • View diagnosis history with full ICD code + description display

Lab Test Investigations

  • Prescribe lab tests with an optional AI-generated ordering comment based on the patient's latest physical examination findings
  • Lab scientists can update test results with a status workflow (To Do → In Progress → Done / Failed)
  • AI polish button on the results field to reformat rough entries into structured lab report language
  • Image attachments (up to multiple per result)
  • 2-minute AI cooldown on the ordering comment to prevent excessive regeneration

Physical Examinations

  • System-by-system examination entry (General Appearance, HEENT, Cardiovascular, Respiration, Gastrointestinal, Genitourinary, Gynecology/Obstetrics, Musculoskeletal, Neurological, Skin)
  • AI-generated Findings / Provisional Diagnosis that produces:
    • Key findings narrative
    • Provisional diagnosis with ICD-10-CM code
    • Differential diagnoses with ICD-10-CM codes
    • Suggested workup with specific named investigations

Complaints

  • Record patient complaints with AI polish to rewrite informal entries into formal chief complaint language

Doctor's Notes

  • Record SOAP-style or narrative progress notes with AI polish

Nurse's Notes

  • Record nursing shift observations and interventions with AI polish

Prescriptions

  • Prescribe medications with drug name, dosage, frequency, duration, and instructions
  • Multi-item prescriptions per visit
  • Status tracking (Active, Completed, Cancelled)

Procedures

  • Document clinical procedures performed with comments and timestamps

Discharge Summaries

  • Linked to admissions; view per-admission discharge details including ICD-10-CM final diagnosis

Billing

  • Generate patient invoices linked to admissions or outpatient visits
  • Line-item billing with quantity, unit price, and totals
  • Invoice status tracking (Pending, Partial, Paid, Cancelled)
  • Printable formatted bills

Patient Summary (AI)

  • One-click AI-generated clinical patient summary aggregating vitals trends, diagnoses, complaints, doctor notes, nurse notes, physical exams, lab results, prescriptions, procedures, admissions, discharge summaries, and visits
  • 10-minute server-side cache to avoid redundant AI calls
  • Structured output with bold section headers

Inventory

  • Manage hospital inventory items with stock tracking

Setup & Configuration

  • Hospital settings: name, address, contact info, logo, license number, print footer
  • Prefixes for patient IDs, admission IDs, lab test IDs, bill numbers
  • Currency and print configuration

Real-Time Notifications

  • Socket.IO-powered live notifications for new appointments and other clinical events
  • Notification badge and dismissal

Print System

  • Printable documents for: Admission Records, Prescriptions, Lab Test Results, Physical Examinations, and Bills
  • All documents use a shared hospital header (name, address, contact, license) driven by settings
  • Print opens in a new browser window

Role-Based Access Control

  • Roles: superadmin, doctor, nurse, lab, pharmacist, receptionist
  • UI elements and routes conditionally rendered by role via hasPermission()

Progressive Web App (PWA)

  • Installable, offline-capable
  • Prompt shown when a new version is available

Tech Stack

Layer Technology
Framework React 18 + Vite
Routing React Router v6
Server State TanStack Query (React Query)
Forms React Hook Form + Zod
UI Components shadcn/ui + Tailwind CSS
Global State Zustand
Real-time Socket.IO client
ICD-10 Search Debounced API search via custom IcdSearchCombobox
HTTP Client Axios

Getting Started

Prerequisites

Installation

cd LHMS
npm install

Environment Variables

Create a .env file:

VITE_API_URL=http://localhost:3000/api
VITE_SOCKET_URL=http://localhost:3000

Running

npm run dev

License

MIT

About

Hospital management system with appointment scheduling, patient management, and medical records. PS. "localhost" being the domain is done on purpose

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages