devsofttech_hms_ci4/app/Controllers
DevSoftTech Server 37c3592f69 ABDM: auto-expire stale pending consent requests after 1 hour
Previously, clicking 'Fetch ABDM Records' when a prior consent request was
stuck in REQUESTED/PENDING (no GRANTED/DENIED callback ever received from
the ABDM bridge/PHR - e.g. patient never opened/approved it in their PHR
app) would just resume/re-poll that same dead request indefinitely, since
getLatestAbdmSyncSnapshot() always prioritized the existing REQUESTED
request over starting a new one.

Now:
- getLatestAbdmSyncSnapshot() computes the age of a REQUESTED/PENDING
  snapshot's updated_at and marks restart_required = true once it has
  been pending for more than ABDM_PENDING_STALE_SECONDS (1 hour).
- abdm_content_auto_flow() honors this flag: when the last sync is stale,
  it no longer resumes the old request_id and instead falls through to
  create a brand-new consent_request against the bridge.

Verified locally: a 6h-old stale REQUESTED request for a test ABHA was
correctly abandoned and a fresh consent_request was created and granted
on the next 'Fetch ABDM Records' click, instead of re-polling the dead
request.
2026-07-28 14:36:15 +05:30
..
Billing Add ABDM M3 fetch option to Ayushman claim sheet 2026-07-19 01:19:56 +05:30
Setting ABDM Gateway settings: add admin UI toggle for SSL certificate verification 2026-07-28 03:47:06 +05:30
AbdmBridgeLog.php feat(abdm): proper FHIR bundles for lab reports and IPD discharge 2026-05-23 04:41:59 +05:30
AbdmCodingPanel.php feat: SNOMED background coding pipeline + ABDM Coding Panel 2026-05-19 20:40:27 +05:30
AbdmGateway.php Harden ABDM bridge auth flow and sync handling 2026-07-28 00:14:49 +05:30
AbdmHiu.php Add ABDM documents and patient profile sync UI 2026-07-16 18:23:40 +05:30
AbdmOpdQueue.php Implement ABDM bridge health record flows 2026-07-20 03:02:09 +05:30
AbdmSync.php ABDM M2 care-context outbound sync and server cron automation 2026-07-23 15:12:46 +05:30
AbdmTaskBoard.php ABDM records/push: treat 201/409 as submitted, persist record IDs, and update OPD UI state 2026-07-21 01:32:30 +05:30
Abha.php Harden ABDM bridge auth flow and sync handling 2026-07-28 00:14:49 +05:30
BaseController.php Implement OPD template builder, doctor template selection, and OPD print integration fixes 2026-02-27 19:44:36 +05:30
Diagnosis.php mPDF: normalize numeric font-weights across template PDF renderers 2026-07-02 10:27:46 +05:30
DoctorDocument.php mPDF: normalize numeric font-weights across template PDF renderers 2026-07-02 10:27:46 +05:30
Finance.php feat: ABDM OPD Queue + ABHA Register flow + patient ABHA search fix 2026-05-16 04:21:31 +05:30
HealthplixCallback.php Fix HealthPlix fetch parsing and refine sidebar headings 2026-04-28 07:28:34 +05:30
HealthplixGateway.php feat: add HealthPlix OPD sync flow with settings, diagnostics, and sync ID persistence 2026-04-27 08:32:51 +05:30
Home.php Add dedicated Save Settings button for user preferences 2026-04-28 13:54:46 +05:30
Immunization.php Add E-Atria immunization master sync 2026-07-19 01:00:43 +05:30
Invoice.php Fix payment request receipt content and PDF print 2026-04-10 04:16:17 +05:30
Ipd_discharge.php ABDM M2 care-context outbound sync and server cron automation 2026-07-23 15:12:46 +05:30
IpdPatient.php feat: Complete bed management system with transfer and time tracking 2026-06-09 08:39:48 +05:30
Item.php Implement OPD template builder, doctor template selection, and OPD print integration fixes 2026-02-27 19:44:36 +05:30
ItemIpd.php feat(ipd-charges): group delete, sort order, Up/Down buttons, foldable billing panels 2026-04-18 06:56:38 +05:30
Medical.php Medical GST: persist item tax breakup and add backfill 2026-07-02 22:35:34 +05:30
OcasePathLap.php Implement OPD template builder, doctor template selection, and OPD print integration fixes 2026-02-27 19:44:36 +05:30
Opd_prescription.php ABDM records/push: treat 201/409 as submitted, persist record IDs, and update OPD UI state 2026-07-21 01:32:30 +05:30
Opd.php ABDM HIU callback hardening, OPD ABHA optional confirm, and AJAX memory cleanup 2026-07-10 00:09:35 +05:30
Opdcase.php Add OPD appointment time capture and storage with date+time display 2026-04-28 07:59:47 +05:30
OrgPacking.php Implement OPD template builder, doctor template selection, and OPD print integration fixes 2026-02-27 19:44:36 +05:30
Package.php Implement OPD template builder, doctor template selection, and OPD print integration fixes 2026-02-27 19:44:36 +05:30
Patient.php ABDM: auto-expire stale pending consent requests after 1 hour 2026-07-28 14:36:15 +05:30
Payment_Medical.php Implement OPD template builder, doctor template selection, and OPD print integration fixes 2026-02-27 19:44:36 +05:30
Report.php Add refer doctor filter to diagnosis report 2026-04-09 19:11:39 +05:30
Setup.php Fix: {{advice}} prints as-is (no Hindi/AI conversion); fix Schema Diff truncation 2026-04-16 12:31:42 +05:30
Storestock.php feat: update storestock flow and ABDM bridge handling 2026-06-18 17:38:20 +05:30