Closed Nitive closed 8 months ago
I need to be able to overwrite some of the fields in FHIR resources schemas in my custom resources.
Let's say I need to extend Communication resource to allow have references to Person in sender field.
Person
sender
I'm extending the schema like this
Communication {:zen/tags #{zen/schema zen.fhir/base-schema} :type zen/map :zen.fhir/type "Communication" :zen.fhir/version "0.5.3" :confirms #{hl7-fhir-r4-core.Communication/schema} :keys {:sender {:confirms #{zenbox/Reference} :zen.fhir/reference {:refers #{hl7-fhir-r4-core.Person/schema hl7-fhir-r4-core.Patient/schema hl7-fhir-r4-core.PractitionerRole/schema hl7-fhir-r4-core.HealthcareService/schema hl7-fhir-r4-core.Organization/schema hl7-fhir-r4-core.Device/schema hl7-fhir-r4-core.Practitioner/schema hl7-fhir-r4-core.RelatedPerson/schema}}} :zen/desc "Message sender"}}}
But instead of validating the fields using the new schema the field is validated against both schemas
resourceType: "Person" (no validation messages expected)
resourceType: "Person"
resourceType: "BadInput" (only 1 validation message expected)
resourceType: "BadInput"
This will be resolved with FHIR Schema engine
I need the following improvement
I need to be able to overwrite some of the fields in FHIR resources schemas in my custom resources.
Let's say I need to extend Communication resource to allow have references to
Person
insender
field.I'm extending the schema like this
But instead of validating the fields using the new schema the field is validated against both schemas
resourceType: "Person"
(no validation messages expected)resourceType: "BadInput"
(only 1 validation message expected)