Overview
The Patient Management module is the core of OdontologyApp, providing a centralized system for registering, searching, and managing patient information across your dental clinic.Patient Registration
Creating a New Patient
Patients can be registered through the main patient listing page with comprehensive demographic and medical information. Required Fields:- First name (nombres)
- Last name (apellidos)
- Cedula (National ID) - Must be 11 digits in Dominican format
- Birth date
- Phone number
- Email address
- Sex (masculino, femenino, otro)
- Blood group (e.g., O+, AB-, etc.)
- Allergies / Medical notes
- Branch assignment
Each patient is automatically assigned a unique medical record number (medrecno) starting from 260001. This number is used throughout the system for patient identification.
Database Schema
Patients are stored in thepatients table:
Patient Search and Filtering
Real-time Search
The patient list includes a powerful search feature that queries:- Patient name (first or last name)
- Cedula (National ID)
- Medical record number (medrecno)
Patient List Display
The patient table shows:- Paciente: Full name with medical record ID and cedula
- Edad: Calculated age from birth date
- Teléfono: Contact phone number
- Última visita: Date of last appointment
- Estado: Active/Inactive status badge
- Acciones: View, Edit, Delete buttons (permission-based)
Patient ID Format
Display format:
#PAC-{medrecno}Example: #PAC-260001Status Colors
- Green: Active patient
- Slate: Inactive/On hold
Patient Details View
Patient Profile Page
Access a patient’s complete profile at/patients/{uuid} which includes:
- History
- Odontogram
- Appointments
- Files
- Indications
- Consents
View complete medical history with all clinical records, diagnoses, and treatments.
Patient Header
The patient detail page displays:- Full name and medical record number
- Age calculated from birth date
- Contact information (phone, email)
- Blood group and allergies (highlighted for medical safety)
- Current status
- Edit profile button (permission-based)
Editing Patient Information
Update Patient Data
Patients can be edited by users with theEDIT_PATIENTS permission:
- Click the edit button (✏️) from the patient list or profile
- Modify any field in the modal form
- Click “Actualizar Paciente” to save changes
Validation Rules
- First name: Required, cannot be empty
- Last name: Required, cannot be empty
- Cedula: Required, must be exactly 11 digits (Dominican format)
- Email: Must be valid email format if provided
- Cedula uniqueness: System prevents duplicate cedulas
Deleting Patients
Delete Process
Users withDELETE_PATIENTS permission can remove patients:
- Click the delete button (🗑️) from the patient list
- Confirm the action in the SweetAlert2 modal
- Patient and all related data are permanently removed
Permissions
Patient management requires specific permissions:VIEW_PATIENTS
VIEW_PATIENTS
Access the patient list and view patient profiles. Required for all staff members who need to access patient information.
CREATE_PATIENTS
CREATE_PATIENTS
Register new patients in the system. Typically granted to secretaries and administrative staff.
EDIT_PATIENTS
EDIT_PATIENTS
Modify existing patient information. Essential for keeping patient data up-to-date.
DELETE_PATIENTS
DELETE_PATIENTS
Permanently remove patient records. Should be restricted to administrators only.
PRINT_PATIENTS
PRINT_PATIENTS
Print or export patient files and reports.
Multi-Branch Support
Patients are assigned to a specific branch (sucursal) during registration:- Sucursal Central (Branch ID: 1)
- Sucursal Norte (Branch ID: 2)
- Sucursal Sur (Branch ID: 3)
Age Calculation
The system automatically calculates patient age from the birth date:Mobile Responsive View
The patient list includes a mobile-optimized grid view that displays:- Patient name and ID
- Last visit and contact info
- Age and quick actions
- Status badge
