make sure that supportedResources always includes USCore resources.

This commit is contained in:
Jason Kulatunga 2022-11-06 19:35:22 -08:00
parent aa479fd655
commit 3a13d2d4ac
3 changed files with 5 additions and 46 deletions

View File

@ -16,28 +16,7 @@ export class AthenaClient extends FHIR401Client implements IClient {
* @constructor
*/
async SyncAll(db: IDatabaseRepository): Promise<UpsertSummary> {
const supportedResources: string[] = [
"AllergyIntolerance",
//"Binary",
"CarePlan",
"CareTeam",
"Condition",
"Device",
"DiagnosticReport",
"DocumentReference",
"Encounter",
"Goal",
"Immunization",
//"Location",
//"Medication",
//"MedicationRequest",
"Observation",
//"Organization",
//"Patient",
//"Practitioner",
"Procedure",
//"Provenance",
]
const supportedResources: string[] = this.usCoreResources
return this.SyncAllByResourceName(db, supportedResources)
}

View File

@ -18,23 +18,13 @@ export class EpicClient extends FHIR401Client implements IClient {
* @constructor
*/
async SyncAll(db: IDatabaseRepository): Promise<UpsertSummary> {
const supportedResources: string[] = [
"AllergyIntolerance",
"CarePlan",
"CareTeam",
"Condition",
const supportedResources: string[] = this.usCoreResources.concat([
"Consent",
"Device",
"Encounter",
"FamilyMemberHistory",
"Goal",
"Immunization",
"InsurancePlan",
"MedicationRequest",
"NutritionOrder",
"Observation",
"Person",
"Procedure",
"Provenance",
"Questionnaire",
"QuestionnaireResponse",
@ -42,7 +32,7 @@ export class EpicClient extends FHIR401Client implements IClient {
"Schedule",
"ServiceRequest",
"Slot",
]
])
return this.SyncAllByResourceName(db, supportedResources)
}

View File

@ -18,23 +18,13 @@ export class HealthITClient extends FHIR401Client implements IClient {
* @constructor
*/
async SyncAll(db: IDatabaseRepository): Promise<UpsertSummary> {
const supportedResources: string[] = [
"AllergyIntolerance",
"CarePlan",
"CareTeam",
"Condition",
const supportedResources: string[] = this.usCoreResources.concat([
"Consent",
"Device",
"Encounter",
"FamilyMemberHistory",
"Goal",
"Immunization",
"InsurancePlan",
"MedicationRequest",
"NutritionOrder",
"Observation",
"Person",
"Procedure",
"Provenance",
"Questionnaire",
"QuestionnaireResponse",
@ -42,7 +32,7 @@ export class HealthITClient extends FHIR401Client implements IClient {
"Schedule",
"ServiceRequest",
"Slot",
]
])
return this.SyncAllByResourceName(db, supportedResources)
}