gdc-common-utils-ts 2.3.10 → 2.3.11
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.
|
@@ -110,6 +110,20 @@ export declare class ClinicalResourceEntryEditor extends BundleEntryEditor {
|
|
|
110
110
|
setLanguage(value?: string | null): this;
|
|
111
111
|
/** Returns the generic `<ResourceType>.language` flat claim when present. */
|
|
112
112
|
getLanguage(): string | undefined;
|
|
113
|
+
/**
|
|
114
|
+
* Assigns the resource to one or more Composition sections.
|
|
115
|
+
*
|
|
116
|
+
* Section placement is document structure, not the resource's clinical
|
|
117
|
+
* category. `BundleEditor.buildDocument()` consumes this
|
|
118
|
+
* `<ResourceType>.section` claim to create `Composition.section.entry`
|
|
119
|
+
* references without overloading fields such as
|
|
120
|
+
* `AllergyIntolerance.category`.
|
|
121
|
+
*/
|
|
122
|
+
setSectionList(sectionCodes: readonly string[]): this;
|
|
123
|
+
/** Returns the explicit Composition section codes staged for this resource. */
|
|
124
|
+
getSectionList(): string[];
|
|
125
|
+
/** Adds one Composition section code while preserving existing assignments. */
|
|
126
|
+
addSection(sectionCode: string): this;
|
|
113
127
|
/** Stores the generic `<ResourceType>.user-selected` flag used by self-managed user flows. */
|
|
114
128
|
setUserSelected(value?: boolean | null): this;
|
|
115
129
|
/** Returns the generic `<ResourceType>.user-selected` flag when present. */
|
|
@@ -279,6 +279,29 @@ export class ClinicalResourceEntryEditor extends BundleEntryEditor {
|
|
|
279
279
|
getLanguage() {
|
|
280
280
|
return this.getScalarClaim(this.getResourceScopedClaimKey('language'));
|
|
281
281
|
}
|
|
282
|
+
/**
|
|
283
|
+
* Assigns the resource to one or more Composition sections.
|
|
284
|
+
*
|
|
285
|
+
* Section placement is document structure, not the resource's clinical
|
|
286
|
+
* category. `BundleEditor.buildDocument()` consumes this
|
|
287
|
+
* `<ResourceType>.section` claim to create `Composition.section.entry`
|
|
288
|
+
* references without overloading fields such as
|
|
289
|
+
* `AllergyIntolerance.category`.
|
|
290
|
+
*/
|
|
291
|
+
setSectionList(sectionCodes) {
|
|
292
|
+
return this.setCsvClaimList(this.getResourceScopedClaimKey('section'), sectionCodes);
|
|
293
|
+
}
|
|
294
|
+
/** Returns the explicit Composition section codes staged for this resource. */
|
|
295
|
+
getSectionList() {
|
|
296
|
+
return this.getCsvClaimList(this.getResourceScopedClaimKey('section'));
|
|
297
|
+
}
|
|
298
|
+
/** Adds one Composition section code while preserving existing assignments. */
|
|
299
|
+
addSection(sectionCode) {
|
|
300
|
+
const normalized = String(sectionCode || '').trim();
|
|
301
|
+
return normalized
|
|
302
|
+
? this.setSectionList([...new Set([...this.getSectionList(), normalized])])
|
|
303
|
+
: this;
|
|
304
|
+
}
|
|
282
305
|
/** Stores the generic `<ResourceType>.user-selected` flag used by self-managed user flows. */
|
|
283
306
|
setUserSelected(value) {
|
|
284
307
|
return this.setBooleanClaim(this.getResourceScopedClaimKey('user-selected'), value);
|