Skip to content

an internal tool for healthcare facilities to track when clinicians (doctors, nurses, etc.) visit patients. Think of it as a digital logbook for patient care.

Notifications You must be signed in to change notification settings

unsaid-u/medflow

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Medflow

An internal tool for healthcare facilities to track when clinicians (doctors, nurses, etc.) visit patients. Think of it as a digital logbook for patient care.

Description

Medflow is a full-stack web application that provides healthcare professionals with an intuitive platform to manage patient visits, track clinician information, and maintain organized medical records. Built with modern technologies, it offers a clean, responsive interface for efficient healthcare practice management.

Functional Requirements

Core Features

  • Patient Management: Create, view, and manage patient records with comprehensive information
  • Clinician Management: Handle clinician profiles, specialties, and credentials
  • Visit Tracking: Log and monitor patient visits with detailed notes and visit types
  • User Authentication: Secure login and registration system for clinicians
  • Dashboard Interface: Clean, intuitive navigation with real-time data display
  • Data Pagination: Efficient handling of large datasets with server-side pagination

Technical Features

  • RESTful API: Complete backend API with proper validation and error handling
  • Database Management: SQLite database with Knex.js migrations and Objection.js ORM
  • Security: Password hashing, input validation, and CORS protection

Tech Stack

Backend

  • Node.js with Express.js framework
  • SQLite database with Knex.js query builder
  • Objection.js ORM for data modeling
  • bcryptjs for password hashing
  • AJV for request validation
  • CORS for cross-origin resource sharing

Frontend

  • React.js with modern hooks and context API
  • Material-UI for component library and styling
  • React Router for navigation and routing
  • Styled Components for custom styling

Local Setup

Prerequisites

  • Node.js (v14 or higher)
  • npm or yarn package manager

Server Setup

  1. Install dependencies

    npm install
  2. Run database migrations

    npm run migrate:up
  3. Add dummy data (for patients, clients, visits, for better testing experience)

    cd server/local/dummy
    sh run.dummydata.sh
  4. Start the development server

    npm run dev

    The server will start on http://localhost:3001

Client Setup

  1. Navigate to client directory

    cd client
  2. Install dependencies

    npm install
  3. Start the development server

    npm start

    The client will start on http://localhost:3000

Register a new user (clinician)
Using those creds login
You will be able access the dashboard

API Endpoints

Authentication

  • POST /api/v1/auth/login - Clinician login
  • POST /api/v1/auth/register - Clinician registration (this creates a new Clinician)

Patients

  • GET /api/v1/patients - Get all patients (with pagination)
  • GET /api/v1/patients/:id - Get patient by ID

Clinicians

  • GET /api/v1/clinicians - Get all clinicians (with pagination)

Visits

  • GET /api/v1/visits - Get all visits (with pagination)
  • POST /api/v1/visits - Create new visit

Database Schema

Patients Table

  • id (Primary Key)
  • name (Required)
  • email (Required, Unique)
  • profile_image (Optional)
  • contact (Required)
  • address (Optional)
  • dob (Required)
  • created_at, updated_at (Timestamps)

Clinicians Table

  • id (Primary Key)
  • name (Required)
  • password (Required, Hashed)
  • specialty (Required)
  • email (Required, Unique)
  • profile_image (Optional)
  • contact (Required)
  • created_at, updated_at (Timestamps)

Visits Table

  • id (Primary Key)
  • clinician_id (Foreign Key)
  • patient_id (Foreign Key)
  • patient_name (Required)
  • visit_type (Optional, Default: "general")
  • notes (Optional)
  • created_at, updated_at (Timestamps)

Available Scripts

Server Scripts

  • npm start - Start production server
  • npm run dev - Start development server with nodemon
  • npm run migrate:up - Run all pending migrations
  • npm run migrate:down - Rollback last migration
  • npm run migrate:single - Run single migration

Client Scripts

  • npm start - Start development server
  • npm run build - Build for production
  • npm test - Run tests
  • npm run eject - Eject from Create React App

Future Scope

Planned Features

  • Advanced Authentication: JWT tokens with refresh mechanism
  • File Upload: Profile image upload functionality
  • check In/Out: Check in/out capability for doctors visiting patients
  • Advanced Search: Full-text search capabilities
  • Admin login: Admin login for managing clinicians and patients

Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Author

Utkarsh - GitHub , email

Support

For support and questions, please open an issue on the GitHub repository.

About

an internal tool for healthcare facilities to track when clinicians (doctors, nurses, etc.) visit patients. Think of it as a digital logbook for patient care.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •