gdc-common-utils-ts 2.8.0 → 2.8.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -65,6 +65,7 @@ export declare const IdentityDcrMetadataFields: Readonly<{
|
|
|
65
65
|
readonly ClientName: "client_name";
|
|
66
66
|
readonly ActorDid: "actor_did";
|
|
67
67
|
readonly ProfileDid: "profile_did";
|
|
68
|
+
readonly ClinicalCreatorBinding: "clinical_creator_binding";
|
|
68
69
|
}>;
|
|
69
70
|
/** Device metadata keys nested below `ext_device_info`. */
|
|
70
71
|
export declare const IdentityDeviceInfoFields: Readonly<{
|
|
@@ -65,6 +65,7 @@ export const IdentityDcrMetadataFields = Object.freeze({
|
|
|
65
65
|
ClientName: 'client_name',
|
|
66
66
|
ActorDid: 'actor_did',
|
|
67
67
|
ProfileDid: 'profile_did',
|
|
68
|
+
ClinicalCreatorBinding: 'clinical_creator_binding',
|
|
68
69
|
});
|
|
69
70
|
/** Device metadata keys nested below `ext_device_info`. */
|
|
70
71
|
export const IdentityDeviceInfoFields = Object.freeze({
|
|
@@ -2,6 +2,7 @@ import { ResourceTypesFhirR4 } from '../constants/fhir-resource-types.js';
|
|
|
2
2
|
import { Format } from '../constants/Schemas.js';
|
|
3
3
|
import { IndividualClinicalSections, IndividualLogicalSections, } from '../constants/individual-sections.js';
|
|
4
4
|
import { HealthcareDocumentTypes } from '../constants/healthcare.js';
|
|
5
|
+
import { LOINC_SYSTEM_URL } from '../models/clinical-sections.js';
|
|
5
6
|
import { ObservationCategoryCodes, VitalSignsCodes, VitalSignsUnits, } from '../constants/vital-signs.js';
|
|
6
7
|
import { CommunicationClaim } from '../models/interoperable-claims/communication-claims.js';
|
|
7
8
|
import { CompositionClaim } from '../models/interoperable-claims/composition-claims.js';
|
|
@@ -316,10 +317,13 @@ export class IndividualBundleVault {
|
|
|
316
317
|
.find((entry) => entry?.resource?.resourceType === ResourceTypesFhirR4.Composition);
|
|
317
318
|
const sections = Array.isArray(compositionEntry?.resource?.section) ? compositionEntry.resource.section : [];
|
|
318
319
|
for (const section of sections) {
|
|
319
|
-
const
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
320
|
+
const sectionSystem = asTrimmedString(section?.code?.coding?.[0]?.system);
|
|
321
|
+
const sectionValue = asTrimmedString(section?.code?.coding?.[0]?.code);
|
|
322
|
+
const sectionCode = sectionSystem && sectionValue
|
|
323
|
+
? sectionSystem === LOINC_SYSTEM_URL
|
|
324
|
+
? `LOINC|${sectionValue}`
|
|
325
|
+
: `${sectionSystem}|${sectionValue}`
|
|
326
|
+
: sectionValue;
|
|
323
327
|
if (!sectionCode)
|
|
324
328
|
continue;
|
|
325
329
|
const refs = Array.isArray(section?.entry) ? section.entry : [];
|