chronic-care / mcc-project

MCC eCare Plan project planning and documentation
Apache License 2.0
0 stars 1 forks source link

Revise FHIR query approach in eCarePlanner #393

Closed kbertodatti closed 5 days ago

kbertodatti commented 5 months ago

Investigate alternative query API that allows PatientID to be specified as a parameter instead of the .Patient with the library.

drdavec commented 5 months ago

I tested a revised use of FHIR query in MyCarePlanner and it works perfectly. Pass the patientID as a query argument. Use Client.request instead of Client.patient.request

Instead of using: let resourcePath = 'Condition?category=problem-list-item&clinical-status=active' client.patient.request(resourcePath)

Use this: const patientArgs = '&patient=' + client.patient.id (or, use any other Patient.id instead of the one from client) client.request(resourcePath+patientArgs)