7.4 KiB
7.4 KiB
ABDM M2 Test Session Handover & Verification Guide
Date: 2026-09-30
Branch: main
Latest Commits:
6bd2430—fix(abdm-m1): sanitize otp error text, hide bridge request id, add beneficiary name to consenta33b376—feat(abdm-m2): add HIP link modal and care context discovery on patient registrationccd5909—docs: remove technical URLs, database fields and developer codes from user help guidef7c3052—feat(abdm-m2): enable care context discovery and direct linking for invoice records
Live Environment: demo.e-atria.net (10.8.0.1//var/www/html/hms_etria)
1. Executive Summary
This session verified and configured end-to-end readiness for ABDM Milestone 2 (M2) testing across all supported Health Information (HI) types:
- OPConsultRecord (OPD Consultations & Prescriptions)
- DiagnosticReportRecord (Laboratory & Radiology Reports)
- DischargeSummaryRecord (IPD Discharge Summaries)
- ImmunizationRecord (Vaccination Records)
- InvoiceRecord (OPD, IPD, and General Charges Invoices)
All features have been unit tested (57/57 tests passing, 495 assertions), committed, pushed to origin/main, and deployed live to https://demo.e-atria.net/.
2. Key Changes Implemented
A. Patient Registration & ABHA Management Integration
- File: Patient_V.php
- Included
partials/abdm_hip_link_modal.phpon the Patient Registration view so the HIP link modal can be opened from registration screens. - Added hidden
input_abha_addresstoform.form1so ABHA addresses are seamlessly submitted and saved topatient_master. - Added a dedicated 4th card under Patient Management → ABHA Management tab:
- Link Records to ABHA (HIP) button (
openAbdmHipLinkModal()) - Send Deep Link SMS button (
openAbdmHipSmsModal())
- Link Records to ABHA (HIP) button (
- Included
B. Instant Care Context Discovery for New Patients
- File: AbdmGateway.php
- Updated
findCareContextsForPatient()to queryopd_masterin addition toopd_prescription. - Previously, a care context was only discoverable after a doctor wrote a prescription or finalized a lab report.
- Now, as soon as an OPD consultation appointment / slip is created at the reception desk, the visit is instantly discoverable and linkable as
OPD-{patientId}-S{opdId}-{YYYYMMDD}with titleOPConsultRecord - Dr. {DoctorName} - {Date}. - Added unit test
testDiscoversOpdMasterVisitWhenPrescriptionNotCreatedin CareContextDiscoveryTest.php.
- Updated
C. 14-Digit ABHA Number & @sbx Address Dual Resolution
- File: AbdmGateway.php
- Enhanced
hipPatientCareContexts()so that if an ABHA address field contains a 14-digit numeric ABHA ID (or formattedXX-XXXX-XXXX-XXXX), it queries bothabha_addressandabha_idinpatient_master.
- Enhanced
D. Invoice Care Context Discovery & Direct Linking
- Files: AbdmTaskBoard.php, task_board.php, AbdmGateway.php, abdm_hip_link_modal.php
- Integrated
HI Type: InvoiceRecordcare contexts on the ABDM Work Task Board Invoice panel. - Linked
patient_masterto retrieveabha_id/abha_addressacross OPD, IPD, and Charges invoices. - Auto-generated standard care contexts:
INVOICE-OPD-{billId}-{date},INVOICE-CHG-{billId}-{date},INVOICE-IPD-{billId}-{date}. - Enabled the Link Context button on invoice rows with complete task context (
task_type: 'invoice_publish',source: invoiceSource,entity_id: billId). - Added NRCES-compliant Invoice FHIR Bundle bridge push (
share_invoice_source_bundle) directly upon linking from the modal. - Added dynamic DOM updates on the Task Board table row to reflect
LINKEDstatus, update badges, and show care context references immediately upon link confirmation. - Added unit test
testDiscoversInvoiceCareContextWhenInvoiceTaskRequestedin CareContextDiscoveryTest.php.
- Integrated
E. M1 Feedback Updates (Retained & Verified)
- Normalized invalid OTP error alerts strictly to
"Incorrect OTP"(or attempts exceeded message). - Removed internal
Bridge Request ID: REQ-...from user-facing screens. - Added healthcare worker declaration and beneficiary name consent input field before Aadhaar OTP dispatch.
3. M2 Testing Step-by-Step Walkthrough
Step 1: Register Patient & Create Visit Slip
- Open Patient Management → New Person on
https://demo.e-atria.net/. - Register patient with Mobile Number, Name, Gender, DOB.
- On patient record screen, click Appointment For OPD and assign a doctor to generate the OPD slip.
- Care context
OPD-{patientId}-S{opdId}-{YYYYMMDD}is now live and linkable.
Step 2: Test HIP-Initiated Linking (Method 4 Demographic Auth)
- In patient profile or ABHA Management, click Link Records to ABHA (HIP) (or click Link Context on any Task Board card).
- Enter the patient's ABHA address (e.g.,
user@sbx). - Patient demographics (Full Name, Gender, YOB) are pre-filled/verified.
- Select the care contexts (OPD consultation, invoice, lab/radiology, discharge summary).
- Click Link Selected Records (Demographic Auth).
- The gateway returns a JWT Link Token and links the care context to the ABHA account.
Step 3: Test Deep Link SMS (sms/notify2)
- On the same modal, switch to Deep Link SMS (sms/notify2) tab.
- Confirm the 10-digit mobile number and click Send Deep Link SMS.
- ABDM dispatches an SMS with an app deep link to the patient's mobile device.
Step 4: Test User-Initiated Discovery & Linking (from ABHA PHR App)
- Open the ABDM Sandbox ABHA / PHR app on a smartphone.
- Search for the facility: Dev Softtech (Facility ID:
IN0510000871). - Search by patient mobile number or ABHA address.
- Select the discovered care contexts and request OTP.
- Verify OTP to confirm the linking.
Step 5: Test Health Record View (FHIR Bundles in PHR App)
- Doctor submits clinical notes/prescription in OPD Prescription editor (or saves findings in Radiology Report Editor, or prints/generates an Invoice).
- In the PHR app, tap on the linked hospital and tap Fetch Records / Pull Records.
- The HMS generates and transfers the encrypted FHIR bundle (
OPConsultRecord,DiagnosticReportRecord, orInvoiceRecord). - Patient views findings, medications, and invoices directly in the PHR app.
4. Test Suite & Verification Results
# Full PHPUnit Suite Execution
php vendor/phpunit/phpunit/phpunit --no-coverage
# Result
OK (57 tests, 495 assertions)
Tests: 57, Assertions: 495, Failures: 0. 100% PASS.
5. Deployment Commands Reference
# Windows deployment to remote server (10.8.0.1)
& "C:\Program Files\PuTTY\plink.exe" -ssh -batch -pw "bishT@9720958717H" root@10.8.0.1 "cd /var/www/html/hms_etria && git pull origin main && php spark cache:clear"