@huntsman-cancer-institute/cod 16.0.1 → 17.0.1

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.
Files changed (56) hide show
  1. package/cod.module.d.ts +30 -31
  2. package/components/attribute-absolute.component.d.ts +28 -28
  3. package/components/attribute-base.d.ts +135 -135
  4. package/components/attribute-container.component.d.ts +50 -50
  5. package/components/attribute-default.component.d.ts +20 -20
  6. package/components/attribute-edit.component.d.ts +15 -15
  7. package/components/attribute-flex.component.d.ts +25 -25
  8. package/date/date-util.d.ts +9 -9
  9. package/esm2022/cod.module.mjs +114 -119
  10. package/esm2022/components/attribute-absolute.component.mjs +104 -104
  11. package/esm2022/components/attribute-base.mjs +564 -564
  12. package/esm2022/components/attribute-container.component.mjs +155 -155
  13. package/esm2022/components/attribute-default.component.mjs +63 -63
  14. package/esm2022/components/attribute-edit.component.mjs +33 -33
  15. package/esm2022/components/attribute-flex.component.mjs +58 -58
  16. package/esm2022/date/date-util.mjs +59 -59
  17. package/esm2022/huntsman-cancer-institute-cod.mjs +4 -4
  18. package/esm2022/index.mjs +20 -21
  19. package/esm2022/model/attribute-choice.entity.mjs +1 -1
  20. package/esm2022/model/attribute-configuration.dto.mjs +1 -1
  21. package/esm2022/model/attribute-configuration.entity.mjs +1 -1
  22. package/esm2022/model/attribute-container.entity.mjs +1 -1
  23. package/esm2022/model/attribute-dictionary.entity.mjs +1 -1
  24. package/esm2022/model/attribute-long-text.entity.mjs +1 -1
  25. package/esm2022/model/attribute-value-grid-row.entity.mjs +1 -1
  26. package/esm2022/model/attribute-value-set.entity.mjs +1 -1
  27. package/esm2022/model/attribute-value.entity.mjs +2 -2
  28. package/esm2022/model/attribute.entity.mjs +1 -1
  29. package/esm2022/model/dictionary-entries.dto.mjs +2 -2
  30. package/esm2022/model/extractable-field-status.entity.mjs +1 -1
  31. package/esm2022/model/graphical-attribute.entity.mjs +1 -1
  32. package/esm2022/model/pre-eval.dto.mjs +2 -2
  33. package/esm2022/pipes/is-group-attribute.pipe.mjs +32 -32
  34. package/esm2022/services/attribute.service.mjs +1211 -1211
  35. package/fesm2022/huntsman-cancer-institute-cod.mjs +2289 -2542
  36. package/fesm2022/huntsman-cancer-institute-cod.mjs.map +1 -1
  37. package/index.d.ts +26 -27
  38. package/model/attribute-choice.entity.d.ts +16 -16
  39. package/model/attribute-configuration.dto.d.ts +13 -13
  40. package/model/attribute-configuration.entity.d.ts +12 -12
  41. package/model/attribute-container.entity.d.ts +9 -9
  42. package/model/attribute-dictionary.entity.d.ts +12 -12
  43. package/model/attribute-long-text.entity.d.ts +4 -4
  44. package/model/attribute-value-grid-row.entity.d.ts +7 -7
  45. package/model/attribute-value-set.entity.d.ts +11 -11
  46. package/model/attribute-value.entity.d.ts +28 -28
  47. package/model/attribute.entity.d.ts +26 -26
  48. package/model/dictionary-entries.dto.d.ts +6 -6
  49. package/model/extractable-field-status.entity.d.ts +8 -8
  50. package/model/graphical-attribute.entity.d.ts +13 -13
  51. package/model/pre-eval.dto.d.ts +5 -5
  52. package/package.json +16 -8
  53. package/pipes/is-group-attribute.pipe.d.ts +13 -13
  54. package/services/attribute.service.d.ts +263 -263
  55. package/components/attribute-configuration.component.d.ts +0 -52
  56. package/esm2022/components/attribute-configuration.component.mjs +0 -263
@@ -1,263 +1,263 @@
1
- import { InjectionToken } from "@angular/core";
2
- import { HttpClient } from "@angular/common/http";
3
- import { Router } from "@angular/router";
4
- import { BehaviorSubject, Observable, Subject } from "rxjs";
5
- import { DictionaryService } from "@huntsman-cancer-institute/dictionary-service";
6
- import { Attribute } from "../model/attribute.entity";
7
- import { AttributeChoice } from "../model/attribute-choice.entity";
8
- import { AttributeValue } from "../model/attribute-value.entity";
9
- import { AttributeConfiguration } from "../model/attribute-configuration.entity";
10
- import { AttributeValueSet } from "../model/attribute-value-set.entity";
11
- import { AttributeConfigurationDTO } from "../model/attribute-configuration.dto";
12
- import { AttributeValueGridRow } from "../model/attribute-value-grid-row.entity";
13
- import { DictionaryEntriesDTO } from "../model/dictionary-entries.dto";
14
- import * as i0 from "@angular/core";
15
- export declare let ATTRIBUTE_ENDPOINT: InjectionToken<string>;
16
- export declare const BOOLEAN: string[];
17
- export declare const EXTENDED_BOOLEAN: string[];
18
- /**
19
- * A service created for each attribute configuration instance. This makes calls to the backend to get the configuration
20
- * and value set. It also stores common data that different attributes might need (e.g. a list of attribute choices).
21
- */
22
- export declare class AttributeService {
23
- private dictionaryService;
24
- private http;
25
- private router;
26
- private attributeEndpoint;
27
- newAttributeConfiguration: AttributeConfiguration;
28
- idAttributeConfiguration: number;
29
- idFilter1: number;
30
- idFilter2: number;
31
- idAttributeValueSet: number;
32
- idParentObject: number;
33
- boundData: any;
34
- attributeContextLoadingSubject: BehaviorSubject<boolean>;
35
- attributeContextListSubject: BehaviorSubject<any[]>;
36
- attributeSecurityContextListSubject: BehaviorSubject<any[]>;
37
- filter1ListSubject: BehaviorSubject<any[]>;
38
- filter2ListSubject: BehaviorSubject<any[]>;
39
- dictionaryListSubject: BehaviorSubject<any[]>;
40
- postConfigurationSubject: Subject<boolean>;
41
- attributeConfigurationDimensionSubject: BehaviorSubject<any>;
42
- attributeConfigurationListSubject: BehaviorSubject<AttributeConfigurationDTO[]>;
43
- attributeConfigurationListLoadingSubject: BehaviorSubject<boolean>;
44
- attributeConfigurationDTOSubject: BehaviorSubject<AttributeConfigurationDTO>;
45
- attributeConfigurationSubject: BehaviorSubject<AttributeConfiguration>;
46
- attributeValueSetSubject: BehaviorSubject<AttributeValueSet>;
47
- attributeValuePushedSubject: Subject<AttributeValue>;
48
- loadingSubject: BehaviorSubject<boolean>;
49
- attributeMap: Map<number, Attribute>;
50
- width: number;
51
- containerUpdated: Subject<boolean>;
52
- gridRowSaved: Subject<AttributeValueGridRow>;
53
- gridRowDeleted: Subject<AttributeValueGridRow>;
54
- dirty: BehaviorSubject<boolean>;
55
- updatedAttributeValues: AttributeValue[];
56
- slicedAttributeValues: AttributeValue[];
57
- private uniqueId;
58
- constructor(dictionaryService: DictionaryService, http: HttpClient, router: Router, attributeEndpoint: string);
59
- setBoundData(boundData: any): void;
60
- getAttributeValueCountByAttribute(idAttribute: number): Observable<number>;
61
- getAttributeValueCountByContainer(idAttributeContainer: number): Observable<number>;
62
- getDictionaryValueCount(idAttributeDictionary: number): Observable<number>;
63
- fetchAttributeContext(): void;
64
- getDictionaryEntries(attribute: Attribute, values: AttributeValue[], groupAttributeRowId?: number, referencedAttributeValue?: AttributeValue): Observable<DictionaryEntriesDTO>;
65
- getJsonEntryFromNode(node: any): any;
66
- private preEvaluateXpath;
67
- private sortAttributeSecurityContextList;
68
- fetchAttributeConfigurationList(codeAttributeSecurityContext?: string): void;
69
- private sortAttributeConfigurationList;
70
- clear(): void;
71
- createAttributeConfiguration(attributeConfiguration: AttributeConfiguration): void;
72
- setAttributeConfigurationById(idAttributeConfiguration: number, idAttributeValueSet: number, idParentObject: number): void;
73
- /**
74
- * Sets the attribute configuration identifiers to be used by this service. This prompts a new configuration
75
- * request to be made.
76
- *
77
- * @param {number} idFilter1
78
- * @param {number} idFilter2
79
- */
80
- /**
81
- * Sets the id of the attribute value set. This will prompt a request to pull this from the backend.
82
- *
83
- * @param {number} idAttributeValueSet
84
- */
85
- setAttributeValueSet(idAttributeValueSet: number, idParentObject: number): void;
86
- /**
87
- * The request to download the attribute configuration.
88
- */
89
- fetchAttributeConfiguration(idAttributeValueSet: number, idParentObject: number): void;
90
- setAttributeConfiguration(attributeConfiguration: AttributeConfiguration): void;
91
- /**
92
- * The request to pull the attribute value set.
93
- * Required the AttributeConfiguration to be pre-loaded
94
- */
95
- fetchAttributeValueSet(idParentObject: number): void;
96
- getBaseWindowDimension(baseWindowTemplate: string): void;
97
- /**
98
- * Currently a simple notifier that the configuration or attribute value set has changed and components may need to be refreshed.
99
- *
100
- */
101
- notifyAttributes(): void;
102
- /**
103
- * Post the attribute configuration after editing. Post the entire thing as it cascades down. The editor allows you
104
- * to modify every container and only then save the entire configuration.
105
- *
106
- * @param {AttributeConfiguration} attributeConfiguration
107
- */
108
- postAttributeConfiguration(attributeConfiguration: AttributeConfiguration): void;
109
- /**
110
- * Put the attribute value set. When editing, attributes already post their updated values to this services under
111
- * a separate array. What we do is merge in these updated or created values with the current attribute value set (avs).
112
- * While doing this, set the id of the avs and nullify any negative ids.
113
- */
114
- updateAttributeValueSet(): Subject<AttributeValueSet>;
115
- /**
116
- * Get the attributeConfigurationSubject.
117
- *
118
- * @returns {BehaviorSubject<AttributeConfiguration>}
119
- */
120
- getAttributeConfigurationSubject(): BehaviorSubject<AttributeConfiguration>;
121
- getDirtySubject(): BehaviorSubject<boolean>;
122
- /**
123
- * Get the attributeValueSetSubject;
124
- *
125
- * @returns {BehaviorSubject<AttributeValueSet>}
126
- */
127
- getAttributeValueSet(): BehaviorSubject<AttributeValueSet>;
128
- /**
129
- * Get the attributeValuePushedSubject;
130
- *
131
- * @returns {Subject<AttributeValue>}
132
- */
133
- getAttributeValuePushedSubject(): Subject<AttributeValue>;
134
- /**
135
- * Get all attribute values based upon the idAttribute.
136
- *
137
- * @param {number} idAttributes
138
- * @returns {AttributeValue[]}
139
- */
140
- getAttributeValues(idAttribute: number, groupAttributeRowId: number): AttributeValue[];
141
- /**
142
- * Get all child attributes of the idAttribute. Most likely for attributes that define columns of a grid.
143
- *
144
- * @param {number} idAttribute
145
- * @returns {Attribute[]}
146
- */
147
- getGroupAttributes(idAttribute: number): Attribute[];
148
- /**
149
- * Set the width which is a requirement of the absolute positioning.
150
- *
151
- * @param {number} width
152
- */
153
- setWidth(width: number): void;
154
- /**
155
- * Get the width.
156
- *
157
- * @returns {number}
158
- */
159
- getWidth(): number;
160
- /**
161
- * Get the array of attribute choices for the idAttribute.
162
- *
163
- * @param {number} idAttribute
164
- * @returns {AttributeChoice[]}
165
- */
166
- getAttributeChoices(idAttribute: number): AttributeChoice[];
167
- getLoadingSubject(): Subject<boolean>;
168
- /**
169
- * Get the containerUpdated subject.
170
- *
171
- * @returns {Subject<number>}
172
- */
173
- getContainerUpdated(): Subject<boolean>;
174
- getGridRowSavedSubject(): Subject<AttributeValueGridRow>;
175
- getGridRowDeletedSubject(): Subject<AttributeValueGridRow>;
176
- /**
177
- * Clear the updated and deleted attribute value arrays.
178
- *
179
- */
180
- clearUpdatedAttributeValues(): void;
181
- /**
182
- * Clear the updated and deleted grid row attributes for the specified grid row
183
- *
184
- */
185
- clearUpdatedGridRowAttributeValues(groupAttributeRowId: number): void;
186
- saveGridRowAttributeValues(idGroupAttribute: number, groupAttributeRowId: number): void;
187
- deleteGridRowAttributeValues(idGroupAttribute: number, groupAttributeRowId: number): void;
188
- /**
189
- * Push an attribute to the attribute map.
190
- *
191
- * @param {Attribute} attribute
192
- */
193
- pushAttribute(attribute: Attribute): void;
194
- pushAttributeValueMultiChoice(attributeValue: AttributeValue): void;
195
- pushAttributeValueMultiDict(attributeValue: AttributeValue): void;
196
- /**
197
- * Push a new or updated attribute value. The current one is just removed and the new one appended to the array.
198
- *
199
- * @param {AttributeValue} attributeValue
200
- */
201
- pushAttributeValue(attributeValue: AttributeValue): void;
202
- /**
203
- * For pushing multiple attribute values at once. This would typically be for a multi choice.
204
- *
205
- * @param {Attribute} attribute
206
- * @param {AttributeValue[]} attributeValues
207
- */
208
- pushAttributeValues(attribute: Attribute, attributeValues: AttributeValue[]): void;
209
- /**
210
- * Push a value in the case where an attribute value doesn't exist.
211
- *
212
- * @param {Attribute} attribute
213
- * @param value
214
- */
215
- pushValue(attribute: Attribute, value: any): void;
216
- /**
217
- * Remove an attribute value. Typically in the case of a multi select where the unselected value is removed.
218
- *
219
- * @param {Attribute} attribute
220
- * @param {AttributeChoice} attributeChoice
221
- */
222
- spliceAttributeValueChoice(attribute: Attribute, attributeChoice: AttributeChoice): void;
223
- /**
224
- * Remove an attribute value. Typically in the case of a multi select where the unselected value is removed.
225
- *
226
- * @param {Attribute} attribute
227
- * @param {AttributeChoice} attributeChoice
228
- */
229
- spliceAttributeValueDict(attribute: Attribute, value: any): void;
230
- /**
231
- * Get the attribute based upon the idAttribute. This is from the map of attributes.
232
- *
233
- * @param {number} idAttribute
234
- * @returns {Attribute}
235
- */
236
- getAttribute(idAttribute: number): Attribute;
237
- /**
238
- * For the attribute configuration, set all of the negative ids to undefined prior to posting.
239
- *
240
- * @param {AttributeConfiguration} attributeConfiguration
241
- */
242
- setNegativeIdsToUndefined(attributeConfiguration: AttributeConfiguration): void;
243
- /**
244
- * Creates a display name for the attribute configuration based on the context code and id.
245
- *
246
- * @param {AttributeConfiguration} configuration
247
- * @returns {string}
248
- */
249
- getConfigurationName(configuration: AttributeConfigurationDTO): string;
250
- getAttributeConfigurationDTO(cfg: AttributeConfiguration): AttributeConfigurationDTO;
251
- getSecurityCodeContext(code: string): any;
252
- getAttributeContextLoadingSubject(): BehaviorSubject<boolean>;
253
- getFilter1For(codeAttributeContext: string, codeAttributeSecurityContext: string): any[];
254
- getFilter2For(codeAttributeContext: string, codeAttributeSecurityContext: string, idFilter1: number): any[];
255
- /**
256
- * Track new idAttributeValues via a negative number for internal tracking. Remove this fake id prior to post.
257
- *
258
- * @returns {number}
259
- */
260
- getUniqueId(): number;
261
- static ɵfac: i0.ɵɵFactoryDeclaration<AttributeService, never>;
262
- static ɵprov: i0.ɵɵInjectableDeclaration<AttributeService>;
263
- }
1
+ import { InjectionToken } from "@angular/core";
2
+ import { HttpClient } from "@angular/common/http";
3
+ import { Router } from "@angular/router";
4
+ import { BehaviorSubject, Observable, Subject } from "rxjs";
5
+ import { DictionaryService } from "@huntsman-cancer-institute/dictionary-service";
6
+ import { Attribute } from "../model/attribute.entity";
7
+ import { AttributeChoice } from "../model/attribute-choice.entity";
8
+ import { AttributeValue } from "../model/attribute-value.entity";
9
+ import { AttributeConfiguration } from "../model/attribute-configuration.entity";
10
+ import { AttributeValueSet } from "../model/attribute-value-set.entity";
11
+ import { AttributeConfigurationDTO } from "../model/attribute-configuration.dto";
12
+ import { AttributeValueGridRow } from "../model/attribute-value-grid-row.entity";
13
+ import { DictionaryEntriesDTO } from "../model/dictionary-entries.dto";
14
+ import * as i0 from "@angular/core";
15
+ export declare let ATTRIBUTE_ENDPOINT: InjectionToken<string>;
16
+ export declare const BOOLEAN: string[];
17
+ export declare const EXTENDED_BOOLEAN: string[];
18
+ /**
19
+ * A service created for each attribute configuration instance. This makes calls to the backend to get the configuration
20
+ * and value set. It also stores common data that different attributes might need (e.g. a list of attribute choices).
21
+ */
22
+ export declare class AttributeService {
23
+ private dictionaryService;
24
+ private http;
25
+ private router;
26
+ private attributeEndpoint;
27
+ newAttributeConfiguration: AttributeConfiguration;
28
+ idAttributeConfiguration: number;
29
+ idFilter1: number;
30
+ idFilter2: number;
31
+ idAttributeValueSet: number;
32
+ idParentObject: number;
33
+ boundData: any;
34
+ attributeContextLoadingSubject: BehaviorSubject<boolean>;
35
+ attributeContextListSubject: BehaviorSubject<any[]>;
36
+ attributeSecurityContextListSubject: BehaviorSubject<any[]>;
37
+ filter1ListSubject: BehaviorSubject<any[]>;
38
+ filter2ListSubject: BehaviorSubject<any[]>;
39
+ dictionaryListSubject: BehaviorSubject<any[]>;
40
+ postConfigurationSubject: Subject<boolean>;
41
+ attributeConfigurationDimensionSubject: BehaviorSubject<any>;
42
+ attributeConfigurationListSubject: BehaviorSubject<AttributeConfigurationDTO[]>;
43
+ attributeConfigurationListLoadingSubject: BehaviorSubject<boolean>;
44
+ attributeConfigurationDTOSubject: BehaviorSubject<AttributeConfigurationDTO>;
45
+ attributeConfigurationSubject: BehaviorSubject<AttributeConfiguration>;
46
+ attributeValueSetSubject: BehaviorSubject<AttributeValueSet>;
47
+ attributeValuePushedSubject: Subject<AttributeValue>;
48
+ loadingSubject: BehaviorSubject<boolean>;
49
+ attributeMap: Map<number, Attribute>;
50
+ width: number;
51
+ containerUpdated: Subject<boolean>;
52
+ gridRowSaved: Subject<AttributeValueGridRow>;
53
+ gridRowDeleted: Subject<AttributeValueGridRow>;
54
+ dirty: BehaviorSubject<boolean>;
55
+ updatedAttributeValues: AttributeValue[];
56
+ slicedAttributeValues: AttributeValue[];
57
+ private uniqueId;
58
+ constructor(dictionaryService: DictionaryService, http: HttpClient, router: Router, attributeEndpoint: string);
59
+ setBoundData(boundData: any): void;
60
+ getAttributeValueCountByAttribute(idAttribute: number): Observable<number>;
61
+ getAttributeValueCountByContainer(idAttributeContainer: number): Observable<number>;
62
+ getDictionaryValueCount(idAttributeDictionary: number): Observable<number>;
63
+ fetchAttributeContext(): void;
64
+ getDictionaryEntries(attribute: Attribute, values: AttributeValue[], groupAttributeRowId?: number, referencedAttributeValue?: AttributeValue): Observable<DictionaryEntriesDTO>;
65
+ getJsonEntryFromNode(node: any): any;
66
+ private preEvaluateXpath;
67
+ private sortAttributeSecurityContextList;
68
+ fetchAttributeConfigurationList(codeAttributeSecurityContext?: string): void;
69
+ private sortAttributeConfigurationList;
70
+ clear(): void;
71
+ createAttributeConfiguration(attributeConfiguration: AttributeConfiguration): void;
72
+ setAttributeConfigurationById(idAttributeConfiguration: number, idAttributeValueSet: number, idParentObject: number): void;
73
+ /**
74
+ * Sets the attribute configuration identifiers to be used by this service. This prompts a new configuration
75
+ * request to be made.
76
+ *
77
+ * @param {number} idFilter1
78
+ * @param {number} idFilter2
79
+ */
80
+ /**
81
+ * Sets the id of the attribute value set. This will prompt a request to pull this from the backend.
82
+ *
83
+ * @param {number} idAttributeValueSet
84
+ */
85
+ setAttributeValueSet(idAttributeValueSet: number, idParentObject: number): void;
86
+ /**
87
+ * The request to download the attribute configuration.
88
+ */
89
+ fetchAttributeConfiguration(idAttributeValueSet: number, idParentObject: number): void;
90
+ setAttributeConfiguration(attributeConfiguration: AttributeConfiguration): void;
91
+ /**
92
+ * The request to pull the attribute value set.
93
+ * Required the AttributeConfiguration to be pre-loaded
94
+ */
95
+ fetchAttributeValueSet(idParentObject: number): void;
96
+ getBaseWindowDimension(baseWindowTemplate: string): void;
97
+ /**
98
+ * Currently a simple notifier that the configuration or attribute value set has changed and components may need to be refreshed.
99
+ *
100
+ */
101
+ notifyAttributes(): void;
102
+ /**
103
+ * Post the attribute configuration after editing. Post the entire thing as it cascades down. The editor allows you
104
+ * to modify every container and only then save the entire configuration.
105
+ *
106
+ * @param {AttributeConfiguration} attributeConfiguration
107
+ */
108
+ postAttributeConfiguration(attributeConfiguration: AttributeConfiguration): void;
109
+ /**
110
+ * Put the attribute value set. When editing, attributes already post their updated values to this services under
111
+ * a separate array. What we do is merge in these updated or created values with the current attribute value set (avs).
112
+ * While doing this, set the id of the avs and nullify any negative ids.
113
+ */
114
+ updateAttributeValueSet(): Subject<AttributeValueSet>;
115
+ /**
116
+ * Get the attributeConfigurationSubject.
117
+ *
118
+ * @returns {BehaviorSubject<AttributeConfiguration>}
119
+ */
120
+ getAttributeConfigurationSubject(): BehaviorSubject<AttributeConfiguration>;
121
+ getDirtySubject(): BehaviorSubject<boolean>;
122
+ /**
123
+ * Get the attributeValueSetSubject;
124
+ *
125
+ * @returns {BehaviorSubject<AttributeValueSet>}
126
+ */
127
+ getAttributeValueSet(): BehaviorSubject<AttributeValueSet>;
128
+ /**
129
+ * Get the attributeValuePushedSubject;
130
+ *
131
+ * @returns {Subject<AttributeValue>}
132
+ */
133
+ getAttributeValuePushedSubject(): Subject<AttributeValue>;
134
+ /**
135
+ * Get all attribute values based upon the idAttribute.
136
+ *
137
+ * @param {number} idAttributes
138
+ * @returns {AttributeValue[]}
139
+ */
140
+ getAttributeValues(idAttribute: number, groupAttributeRowId: number): AttributeValue[];
141
+ /**
142
+ * Get all child attributes of the idAttribute. Most likely for attributes that define columns of a grid.
143
+ *
144
+ * @param {number} idAttribute
145
+ * @returns {Attribute[]}
146
+ */
147
+ getGroupAttributes(idAttribute: number): Attribute[];
148
+ /**
149
+ * Set the width which is a requirement of the absolute positioning.
150
+ *
151
+ * @param {number} width
152
+ */
153
+ setWidth(width: number): void;
154
+ /**
155
+ * Get the width.
156
+ *
157
+ * @returns {number}
158
+ */
159
+ getWidth(): number;
160
+ /**
161
+ * Get the array of attribute choices for the idAttribute.
162
+ *
163
+ * @param {number} idAttribute
164
+ * @returns {AttributeChoice[]}
165
+ */
166
+ getAttributeChoices(idAttribute: number): AttributeChoice[];
167
+ getLoadingSubject(): Subject<boolean>;
168
+ /**
169
+ * Get the containerUpdated subject.
170
+ *
171
+ * @returns {Subject<number>}
172
+ */
173
+ getContainerUpdated(): Subject<boolean>;
174
+ getGridRowSavedSubject(): Subject<AttributeValueGridRow>;
175
+ getGridRowDeletedSubject(): Subject<AttributeValueGridRow>;
176
+ /**
177
+ * Clear the updated and deleted attribute value arrays.
178
+ *
179
+ */
180
+ clearUpdatedAttributeValues(): void;
181
+ /**
182
+ * Clear the updated and deleted grid row attributes for the specified grid row
183
+ *
184
+ */
185
+ clearUpdatedGridRowAttributeValues(groupAttributeRowId: number): void;
186
+ saveGridRowAttributeValues(idGroupAttribute: number, groupAttributeRowId: number): void;
187
+ deleteGridRowAttributeValues(idGroupAttribute: number, groupAttributeRowId: number): void;
188
+ /**
189
+ * Push an attribute to the attribute map.
190
+ *
191
+ * @param {Attribute} attribute
192
+ */
193
+ pushAttribute(attribute: Attribute): void;
194
+ pushAttributeValueMultiChoice(attributeValue: AttributeValue): void;
195
+ pushAttributeValueMultiDict(attributeValue: AttributeValue): void;
196
+ /**
197
+ * Push a new or updated attribute value. The current one is just removed and the new one appended to the array.
198
+ *
199
+ * @param {AttributeValue} attributeValue
200
+ */
201
+ pushAttributeValue(attributeValue: AttributeValue): void;
202
+ /**
203
+ * For pushing multiple attribute values at once. This would typically be for a multi choice.
204
+ *
205
+ * @param {Attribute} attribute
206
+ * @param {AttributeValue[]} attributeValues
207
+ */
208
+ pushAttributeValues(attribute: Attribute, attributeValues: AttributeValue[]): void;
209
+ /**
210
+ * Push a value in the case where an attribute value doesn't exist.
211
+ *
212
+ * @param {Attribute} attribute
213
+ * @param value
214
+ */
215
+ pushValue(attribute: Attribute, value: any): void;
216
+ /**
217
+ * Remove an attribute value. Typically in the case of a multi select where the unselected value is removed.
218
+ *
219
+ * @param {Attribute} attribute
220
+ * @param {AttributeChoice} attributeChoice
221
+ */
222
+ spliceAttributeValueChoice(attribute: Attribute, attributeChoice: AttributeChoice): void;
223
+ /**
224
+ * Remove an attribute value. Typically in the case of a multi select where the unselected value is removed.
225
+ *
226
+ * @param {Attribute} attribute
227
+ * @param {AttributeChoice} attributeChoice
228
+ */
229
+ spliceAttributeValueDict(attribute: Attribute, value: any): void;
230
+ /**
231
+ * Get the attribute based upon the idAttribute. This is from the map of attributes.
232
+ *
233
+ * @param {number} idAttribute
234
+ * @returns {Attribute}
235
+ */
236
+ getAttribute(idAttribute: number): Attribute;
237
+ /**
238
+ * For the attribute configuration, set all of the negative ids to undefined prior to posting.
239
+ *
240
+ * @param {AttributeConfiguration} attributeConfiguration
241
+ */
242
+ setNegativeIdsToUndefined(attributeConfiguration: AttributeConfiguration): void;
243
+ /**
244
+ * Creates a display name for the attribute configuration based on the context code and id.
245
+ *
246
+ * @param {AttributeConfiguration} configuration
247
+ * @returns {string}
248
+ */
249
+ getConfigurationName(configuration: AttributeConfigurationDTO): string;
250
+ getAttributeConfigurationDTO(cfg: AttributeConfiguration): AttributeConfigurationDTO;
251
+ getSecurityCodeContext(code: string): any;
252
+ getAttributeContextLoadingSubject(): BehaviorSubject<boolean>;
253
+ getFilter1For(codeAttributeContext: string, codeAttributeSecurityContext: string): any[];
254
+ getFilter2For(codeAttributeContext: string, codeAttributeSecurityContext: string, idFilter1: number): any[];
255
+ /**
256
+ * Track new idAttributeValues via a negative number for internal tracking. Remove this fake id prior to post.
257
+ *
258
+ * @returns {number}
259
+ */
260
+ getUniqueId(): number;
261
+ static ɵfac: i0.ɵɵFactoryDeclaration<AttributeService, never>;
262
+ static ɵprov: i0.ɵɵInjectableDeclaration<AttributeService>;
263
+ }
@@ -1,52 +0,0 @@
1
- import { ChangeDetectorRef, ElementRef, TemplateRef, QueryList, Renderer2, SimpleChange, OnInit, OnDestroy } from "@angular/core";
2
- import { Subject, Subscription } from "rxjs";
3
- import { NgbAccordion, NgbModal, NgbPanel } from "@ng-bootstrap/ng-bootstrap";
4
- import { AccordionNavComponent } from "@huntsman-cancer-institute/misc";
5
- import { AttributeService } from "../services/attribute.service";
6
- import { AttributeConfiguration } from "../model/attribute-configuration.entity";
7
- import { AttributeValueSet } from "../model/attribute-value-set.entity";
8
- import { AttributeContainer } from "../model/attribute-container.entity";
9
- import * as i0 from "@angular/core";
10
- /**
11
- * This component should be added on to any screen that displays an entity with an idAttributeValueSet. This configuration
12
- * represents the parent of separate containers, which in turn contain attributes which display those values in the
13
- * attributeValueSet.
14
- */
15
- export declare class AttributeConfigurationComponent implements OnInit, OnDestroy {
16
- private attributeService;
17
- private elementRef;
18
- private renderer;
19
- private changeDetectorRef;
20
- private modalService;
21
- classList: string;
22
- idAttributeValueSet: number;
23
- idParentObject: number;
24
- accordionNav: AccordionNavComponent;
25
- editInline: boolean;
26
- editPopup: boolean;
27
- editable: boolean;
28
- vPanels: QueryList<NgbPanel>;
29
- cPanels: QueryList<NgbPanel>;
30
- attributeConfiguration: AttributeConfiguration;
31
- attributeValueSet: AttributeValueSet;
32
- loadingSubject: Subject<boolean>;
33
- editContainer: AttributeContainer;
34
- windowDimension: any;
35
- subscriptions: Subscription;
36
- constructor(attributeService: AttributeService, elementRef: ElementRef, renderer: Renderer2, changeDetectorRef: ChangeDetectorRef, modalService: NgbModal);
37
- /**
38
- * Upon init, subscribe to the configuration and value set.
39
- */
40
- ngOnInit(): void;
41
- set boundData(value: any);
42
- ngOnDestroy(): void;
43
- set accordion(accordion: NgbAccordion);
44
- ngOnChanges(changes: {
45
- [propName: string]: SimpleChange;
46
- }): void;
47
- getAttributeService(): AttributeService;
48
- edit(modal: TemplateRef<any>, editContainer: AttributeContainer): void;
49
- post(): void;
50
- static ɵfac: i0.ɵɵFactoryDeclaration<AttributeConfigurationComponent, never>;
51
- static ɵcmp: i0.ɵɵComponentDeclaration<AttributeConfigurationComponent, "hci-attribute-configuration", never, { "idAttributeValueSet": { "alias": "idAttributeValueSet"; "required": false; }; "idParentObject": { "alias": "idParentObject"; "required": false; }; "accordionNav": { "alias": "accordionNav"; "required": false; }; "editInline": { "alias": "editInline"; "required": false; }; "editPopup": { "alias": "editPopup"; "required": false; }; "editable": { "alias": "editable"; "required": false; }; "boundData": { "alias": "boundData"; "required": false; }; }, {}, ["cPanels"], ["*"], false, never>;
52
- }