@beinformed/ui 1.48.1 → 1.49.3

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 (111) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/esm/hooks/useForm.js +17 -2
  3. package/esm/hooks/useForm.js.map +1 -1
  4. package/esm/models/attributes/AttributeModel.js +2 -1
  5. package/esm/models/attributes/AttributeModel.js.map +1 -1
  6. package/esm/models/attributes/ChoiceAttributeModel.js +16 -1
  7. package/esm/models/attributes/ChoiceAttributeModel.js.map +1 -1
  8. package/esm/models/attributes/ChoiceAttributeOptionCollection.js +10 -3
  9. package/esm/models/attributes/ChoiceAttributeOptionCollection.js.map +1 -1
  10. package/esm/models/concepts/ConceptDetailModel.js +7 -0
  11. package/esm/models/concepts/ConceptDetailModel.js.map +1 -1
  12. package/esm/models/form/FormModel.js +22 -2
  13. package/esm/models/form/FormModel.js.map +1 -1
  14. package/esm/models/form/FormObjectModel.js +9 -1
  15. package/esm/models/form/FormObjectModel.js.map +1 -1
  16. package/esm/modularui/ModularUIRequest.js +1 -1
  17. package/esm/modularui/ModularUIRequest.js.map +1 -1
  18. package/esm/redux/_modularui/ModularUIActions.js +4 -10
  19. package/esm/redux/_modularui/ModularUIActions.js.map +1 -1
  20. package/esm/redux/actions/FormAttributeSet.js +22 -6
  21. package/esm/redux/actions/FormAttributeSet.js.map +1 -1
  22. package/esm/redux/actions/FormAutosubmit.js +9 -1
  23. package/esm/redux/actions/FormAutosubmit.js.map +1 -1
  24. package/esm/redux/actions/FormAutoupdate.js +29 -0
  25. package/esm/redux/actions/FormAutoupdate.js.map +1 -0
  26. package/esm/redux/connectors/FormAttributeSet.js +3 -2
  27. package/esm/redux/connectors/FormAttributeSet.js.map +1 -1
  28. package/esm/redux/types.js.map +1 -1
  29. package/esm/utils/fetch/types.js.map +1 -1
  30. package/lib/hooks/useForm.js +17 -2
  31. package/lib/hooks/useForm.js.flow +22 -7
  32. package/lib/hooks/useForm.js.map +1 -1
  33. package/lib/models/attributes/AttributeModel.js +2 -1
  34. package/lib/models/attributes/AttributeModel.js.flow +2 -1
  35. package/lib/models/attributes/AttributeModel.js.map +1 -1
  36. package/lib/models/attributes/ChoiceAttributeModel.js +16 -1
  37. package/lib/models/attributes/ChoiceAttributeModel.js.flow +23 -2
  38. package/lib/models/attributes/ChoiceAttributeModel.js.map +1 -1
  39. package/lib/models/attributes/ChoiceAttributeOptionCollection.js +10 -3
  40. package/lib/models/attributes/ChoiceAttributeOptionCollection.js.flow +16 -8
  41. package/lib/models/attributes/ChoiceAttributeOptionCollection.js.map +1 -1
  42. package/lib/models/concepts/ConceptDetailModel.js +7 -0
  43. package/lib/models/concepts/ConceptDetailModel.js.flow +8 -0
  44. package/lib/models/concepts/ConceptDetailModel.js.map +1 -1
  45. package/lib/models/form/FormModel.js +22 -2
  46. package/lib/models/form/FormModel.js.flow +25 -5
  47. package/lib/models/form/FormModel.js.map +1 -1
  48. package/lib/models/form/FormObjectModel.js +9 -1
  49. package/lib/models/form/FormObjectModel.js.flow +9 -1
  50. package/lib/models/form/FormObjectModel.js.map +1 -1
  51. package/lib/modularui/ModularUIRequest.js +1 -1
  52. package/lib/modularui/ModularUIRequest.js.flow +1 -1
  53. package/lib/modularui/ModularUIRequest.js.map +1 -1
  54. package/lib/redux/_modularui/ModularUIActions.js +4 -10
  55. package/lib/redux/_modularui/ModularUIActions.js.flow +8 -16
  56. package/lib/redux/_modularui/ModularUIActions.js.map +1 -1
  57. package/lib/redux/actions/FormAttributeSet.js +22 -6
  58. package/lib/redux/actions/FormAttributeSet.js.flow +36 -11
  59. package/lib/redux/actions/FormAttributeSet.js.map +1 -1
  60. package/lib/redux/actions/FormAutosubmit.js +10 -1
  61. package/lib/redux/actions/FormAutosubmit.js.flow +10 -3
  62. package/lib/redux/actions/FormAutosubmit.js.map +1 -1
  63. package/lib/redux/actions/FormAutoupdate.js +37 -0
  64. package/lib/redux/actions/FormAutoupdate.js.flow +43 -0
  65. package/lib/redux/actions/FormAutoupdate.js.map +1 -0
  66. package/lib/redux/connectors/FormAttributeSet.js +3 -2
  67. package/lib/redux/connectors/FormAttributeSet.js.flow +4 -2
  68. package/lib/redux/connectors/FormAttributeSet.js.map +1 -1
  69. package/lib/redux/types.js.flow +1 -0
  70. package/lib/redux/types.js.map +1 -1
  71. package/lib/utils/fetch/types.js.flow +2 -1
  72. package/lib/utils/fetch/types.js.map +1 -1
  73. package/package.json +1 -1
  74. package/src/hooks/useForm.js +22 -7
  75. package/src/models/attributes/AttributeModel.js +2 -1
  76. package/src/models/attributes/ChoiceAttributeModel.js +23 -2
  77. package/src/models/attributes/ChoiceAttributeOptionCollection.js +16 -8
  78. package/src/models/concepts/ConceptDetailModel.js +8 -0
  79. package/src/models/form/FormModel.js +25 -5
  80. package/src/models/form/FormObjectModel.js +9 -1
  81. package/src/modularui/ModularUIRequest.js +1 -1
  82. package/src/redux/_modularui/ModularUIActions.js +8 -16
  83. package/src/redux/actions/FormAttributeSet.js +36 -11
  84. package/src/redux/actions/FormAutosubmit.js +10 -3
  85. package/src/redux/actions/FormAutoupdate.js +43 -0
  86. package/src/redux/connectors/FormAttributeSet.js +4 -2
  87. package/src/redux/types.js +1 -0
  88. package/src/utils/fetch/types.js +2 -1
  89. package/types/hooks/useI18n.d.ts +1 -1
  90. package/types/models/application/ApplicationModel.d.ts +7 -0
  91. package/types/models/attributes/AttributeModel.d.ts +4 -3
  92. package/types/models/attributes/ChoiceAttributeModel.d.ts +4 -0
  93. package/types/models/attributes/ChoiceAttributeOptionCollection.d.ts +1 -1
  94. package/types/models/attributes/ChoiceAttributeOptionModel.d.ts +2 -1
  95. package/types/models/attributes/input-constraints/ConstraintModel.d.ts +1 -1
  96. package/types/models/base/ResourceCollection.d.ts +2 -1
  97. package/types/models/base/ResourceModel.d.ts +3 -2
  98. package/types/models/concepts/BusinessScenarioModel.d.ts +1 -1
  99. package/types/models/concepts/ConceptRelationModel.d.ts +19 -4
  100. package/types/models/content/ContentModel.d.ts +4 -0
  101. package/types/models/content/ContentTOCModel.d.ts +4 -0
  102. package/types/models/form/FormModel.d.ts +7 -1
  103. package/types/models/form/FormObjectModel.d.ts +11 -2
  104. package/types/models/links/normalizeLinkJSON.d.ts +2 -2
  105. package/types/models/list/ListModel.d.ts +4 -0
  106. package/types/models/panels/GroupingPanelModel.d.ts +4 -0
  107. package/types/models/tab/TabModel.d.ts +4 -0
  108. package/types/models/types.d.ts +2 -1
  109. package/types/models/user/UserServicesModel.d.ts +7 -0
  110. package/types/redux/types.d.ts +1 -0
  111. package/types/utils/fetch/types.d.ts +2 -1
@@ -31,11 +31,12 @@ export type RequestBaseOptions = {
31
31
 
32
32
  export type RequestOptions = { ...RequestURLOptions, ...RequestBaseOptions };
33
33
 
34
+ export type UpdateHandler = (newModel: ModularUIModel) => ModularUIModel;
34
35
  export type RequestModularUIOptions = {
35
36
  ...RequestBaseOptions,
36
37
  targetModel?: TargetModel,
37
38
  forceTargetModel?: boolean,
38
- updateModel?: ModularUIModel,
39
+ updateHandler?: UpdateHandler | void,
39
40
  childmodels?: boolean,
40
41
  isValidationRequest?: boolean,
41
42
  removeOnUnmount?: boolean,
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  */
3
- export function useTranslate(): (...any: any[]) => any;
3
+ export function useTranslate(): ((...any) => any);
4
4
  /**
5
5
  */
6
6
  export function useMessage(id: string, defaultMessage?: string, placeholders?: Object | null): any;
@@ -3,6 +3,9 @@
3
3
  */
4
4
  export default class ApplicationModel extends ResourceModel {
5
5
  _userServices: UserServicesModel | null;
6
+ /**
7
+ */
8
+ setChildModels(models: Array<ModularUIModel>): void;
6
9
  /**
7
10
  * Set the userservices for this application
8
11
  */
@@ -32,9 +35,13 @@ export default class ApplicationModel extends ResourceModel {
32
35
  * only available when the user services are available
33
36
  */
34
37
  get userHref(): Href;
38
+ /**
39
+ */
40
+ get userMustChangePassword(): boolean;
35
41
  }
36
42
  import ResourceModel from "../base/ResourceModel";
37
43
  import UserServicesModel from "../user/UserServicesModel";
44
+ import { ModularUIModel } from "../types";
38
45
  import { AuthenticationType } from "../types";
39
46
  import LinkCollection from "../links/LinkCollection";
40
47
  import LinkModel from "../links/LinkModel";
@@ -36,7 +36,7 @@ export default class AttributeModel extends BaseModel {
36
36
  getInitialChildModelLinks(): Array<LinkModel>;
37
37
  /**
38
38
  */
39
- setChildModels(models: Array<ModularUIModel>): void;
39
+ setChildModels(models: Array<ModularUIModel>, errors: Array<ErrorResponse>): void;
40
40
  /**
41
41
  * Set the concept
42
42
  */
@@ -281,7 +281,7 @@ export default class AttributeModel extends BaseModel {
281
281
  /**
282
282
  * Registers a missing error that was received from the server
283
283
  */
284
- addMissingError(): void;
284
+ addMissingError(receivedAttribute?: AttributeType): void;
285
285
  /**
286
286
  */
287
287
  removeMissingError(): void;
@@ -386,10 +386,11 @@ import LinkCollection from "../links/LinkCollection";
386
386
  import LayoutHintRuleCollection from "./layouthint-rules/LayoutHintRuleCollection";
387
387
  import LinkModel from "../links/LinkModel";
388
388
  import { ModularUIModel } from "../types";
389
+ import ErrorResponse from "../error/ErrorResponse";
389
390
  import ContentConfiguration from "../contentconfiguration/ContentConfiguration";
390
391
  import ContentConfigurationElements from "../contentconfiguration/ContentConfigurationElements";
391
392
  import { FormErrorAnchor } from "../types";
392
- import { MessageParameters } from "../../i18n/types";
393
393
  import { AttributeType } from "../types";
394
+ import { MessageParameters } from "../../i18n/types";
394
395
  import AttributeCollection from "./AttributeCollection";
395
396
  import AttributeContent from "./AttributeContent";
@@ -60,6 +60,9 @@ export default class ChoiceAttributeModel extends AttributeModel {
60
60
  * Check if options need to be rendered as tree
61
61
  */
62
62
  get isTree(): boolean;
63
+ /**
64
+ */
65
+ mergeAttribute(oldAttribute: AttributeType, addNotExistingOptions?: boolean, removeNotExistingOptions?: boolean): void;
63
66
  /**
64
67
  * Update attribute by name and value
65
68
  */
@@ -78,4 +81,5 @@ export default class ChoiceAttributeModel extends AttributeModel {
78
81
  import AttributeModel from "./AttributeModel";
79
82
  import ChoiceAttributeOptionCollection from "./ChoiceAttributeOptionCollection";
80
83
  import LinkModel from "../links/LinkModel";
84
+ import { AttributeType } from "../types";
81
85
  import ContentConfigurationElements from "../contentconfiguration/ContentConfigurationElements";
@@ -72,7 +72,7 @@ declare class ChoiceAttributeOptionCollection extends ResourceCollection<ChoiceA
72
72
  get headers(): ListHeaderModel[];
73
73
  /**
74
74
  */
75
- mergeOptions(withOptions: ChoiceAttributeOptionCollection, addNotExistingOptions?: boolean): void;
75
+ mergeOptions(withOptions: ChoiceAttributeOptionCollection, addNotExistingOptions?: boolean, removeNotExistingOptions?: boolean): void;
76
76
  }
77
77
  import ChoiceAttributeOptionModel from "./ChoiceAttributeOptionModel";
78
78
  import ResourceCollection from "../base/ResourceCollection";
@@ -35,7 +35,7 @@ declare class ChoiceAttributeOptionModel extends BaseModel {
35
35
  getInitialChildModelLinks(): Array<LinkModel>;
36
36
  /**
37
37
  */
38
- setChildModels(models: Array<ModularUIModel>): void;
38
+ setChildModels(models: Array<ModularUIModel>, errors: Array<ErrorResponse>): void;
39
39
  /**
40
40
  * Set the concept
41
41
  */
@@ -143,4 +143,5 @@ import AttributeCollection from "./AttributeCollection";
143
143
  import AttributeContent from "./AttributeContent";
144
144
  import LinkModel from "../links/LinkModel";
145
145
  import { ModularUIModel } from "../types";
146
+ import ErrorResponse from "../error/ErrorResponse";
146
147
  import ListItemModel from "../list/ListItemModel";
@@ -5,7 +5,7 @@ export default class ConstraintModel {
5
5
  */
6
6
  constructor(id: string, validateMethod: Function | null, defaultMessage: string | null, parameters: Object | null, useClientsideValidation?: boolean);
7
7
  _id: string;
8
- _validateMethod: (value: any) => boolean;
8
+ _validateMethod: ((value: any) => boolean) | null;
9
9
  _defaultMessage: string | null;
10
10
  _parameters: Object | null;
11
11
  _useClientsideValidation: boolean;
@@ -12,8 +12,9 @@ declare class ResourceCollection<T, IModelWithChildModels> extends BaseCollectio
12
12
  /**
13
13
  * Pass through models for setchildmodels to items of this collection
14
14
  */
15
- setChildModels(models: Array<ModularUIModel>): void;
15
+ setChildModels(models: Array<ModularUIModel>, errors: Array<ErrorResponse>): void;
16
16
  }
17
17
  import BaseCollection from "./BaseCollection";
18
18
  import LinkModel from "../links/LinkModel";
19
19
  import { ModularUIModel } from "../types";
20
+ import ErrorResponse from "../error/ErrorResponse";
@@ -80,7 +80,7 @@ declare class ResourceModel extends BaseModel {
80
80
  /**
81
81
  * Add child models to this model
82
82
  */
83
- addChildModels(models: Array<ModularUIModel>): this;
83
+ addChildModels(models: Array<ModularUIModel>, errors: Array<ErrorResponse>): this;
84
84
  /**
85
85
  * Template to set expanded child models
86
86
  * Use this hook to separate the retrieved child models into the correct models.
@@ -88,7 +88,7 @@ declare class ResourceModel extends BaseModel {
88
88
  * @abstract
89
89
  * @example <caption>Put all models of instance List and GroupingPanel into the panels property</caption>
90
90
  */
91
- setChildModels(models: Array<ModularUIModel>): void;
91
+ setChildModels(models: Array<ModularUIModel>, errors: Array<ErrorResponse>): void;
92
92
  /**
93
93
  */
94
94
  dehydrate(): Object;
@@ -98,4 +98,5 @@ import { ModularUIModel } from "../types";
98
98
  import LinkCollection from "../links/LinkCollection";
99
99
  import LinkModel from "../links/LinkModel";
100
100
  import Href from "../href/Href";
101
+ import ErrorResponse from "../error/ErrorResponse";
101
102
  import ModularUIResponse from "../../modularui/ModularUIResponse";
@@ -4,7 +4,7 @@ export default BusinessScenarioModel;
4
4
  declare class BusinessScenarioModel extends ConceptDetailModel {
5
5
  /**
6
6
  */
7
- static isOfConceptType(conceptTypeHref: string | null, settingName: "STEP" | "PERSONA" | "SCENARIO"): boolean;
7
+ static isOfConceptType(conceptTypeHref: string | null, settingNames: Array<"STEP" | "PERSONA" | "SCENARIO" | "SYSTEM">): boolean;
8
8
  _scenarioSteps: Array<ConceptDetailModel>;
9
9
  /**
10
10
  */
@@ -14,13 +14,12 @@ export default class ConceptRelationModel {
14
14
  */
15
15
  setChildModels(models: Array<ModularUIModel>): void;
16
16
  /**
17
- * Get key of relation
18
17
  */
19
- get key(): string;
18
+ get type(): string;
20
19
  /**
21
- * Get Text fragments
20
+ * Get key of relation
22
21
  */
23
- get textfragments(): textfragmentJSON[];
22
+ get key(): string;
24
23
  /**
25
24
  * Get Label of relation
26
25
  */
@@ -29,6 +28,13 @@ export default class ConceptRelationModel {
29
28
  * Get direction of relation
30
29
  */
31
30
  get direction(): string;
31
+ /**
32
+ * Get type of relation type,
33
+ */
34
+ get relationTypeType(): "None" | "Sub-Class" | "Composition" | "Association" | "Unknown";
35
+ /**
36
+ */
37
+ get condition(): string;
32
38
  /**
33
39
  * Set concept information
34
40
  */
@@ -37,8 +43,17 @@ export default class ConceptRelationModel {
37
43
  * Get other concept
38
44
  */
39
45
  get concept(): ConceptLinkModel;
46
+ /**
47
+ * Get Text fragments
48
+ */
49
+ get textfragments(): textfragmentJSON[];
50
+ /**
51
+ * Get Properties
52
+ */
53
+ get properties(): propertyJSON[];
40
54
  }
41
55
  import ConceptLinkModel from "./ConceptLinkModel";
42
56
  import LinkModel from "../links/LinkModel";
43
57
  import { ModularUIModel } from "../types";
44
58
  import { textfragmentJSON } from "../types";
59
+ import { propertyJSON } from "../types";
@@ -5,6 +5,9 @@ export default class ContentModel extends ResourceModel {
5
5
  _section: SectionModel;
6
6
  _contentType: ContentTypeModel | null;
7
7
  _filterCollection: FilterCollection;
8
+ /**
9
+ */
10
+ setChildModels(models: Array<ModularUIModel>): void;
8
11
  /**
9
12
  * Set concept type
10
13
  */
@@ -69,6 +72,7 @@ import ResourceModel from "../base/ResourceModel";
69
72
  import SectionModel from "./SectionModel";
70
73
  import ContentTypeModel from "./ContentTypeModel";
71
74
  import FilterCollection from "../filters/FilterCollection";
75
+ import { ModularUIModel } from "../types";
72
76
  import ContentLinkModel from "./ContentLinkModel";
73
77
  import SubSectionModel from "./SubSectionModel";
74
78
  import Href from "../href/Href";
@@ -4,6 +4,9 @@
4
4
  export default class ContentTOCModel extends ResourceModel {
5
5
  _contentType: ContentTypeModel | null;
6
6
  _filterCollection: FilterCollection;
7
+ /**
8
+ */
9
+ setChildModels(models: Array<ModularUIModel>): void;
7
10
  /**
8
11
  */
9
12
  set contentType(contentType: ContentTypeModel);
@@ -34,4 +37,5 @@ export default class ContentTOCModel extends ResourceModel {
34
37
  import ResourceModel from "../base/ResourceModel";
35
38
  import ContentTypeModel from "./ContentTypeModel";
36
39
  import FilterCollection from "../filters/FilterCollection";
40
+ import { ModularUIModel } from "../types";
37
41
  import ContentLinkModel from "./ContentLinkModel";
@@ -193,7 +193,7 @@ declare class FormModel extends ResourceModel {
193
193
  */
194
194
  getResultData(): {
195
195
  [key: string]: AttributeSetModel;
196
- };
196
+ } | null;
197
197
  /**
198
198
  */
199
199
  get resultData(): Object;
@@ -280,6 +280,12 @@ declare class FormModel extends ResourceModel {
280
280
  * Merge existing form with new form
281
281
  */
282
282
  update(receivedForm: ModularUIModel): FormModel;
283
+ /**
284
+ * Updates the current form object with new information about the object,
285
+ * like for example a new dynamicschema. Used for autoupdate functionality that makes it possible
286
+ * to update the options of a next missing attribute in a form-tree iq question
287
+ */
288
+ updateCurrentFormObject(receivedForm: ModularUIModel): void;
283
289
  /**
284
290
  */
285
291
  updateValidations(data: any): FormModel;
@@ -40,7 +40,7 @@ export default class FormObjectModel extends BaseModel {
40
40
  getInitialChildModelLinks(): Array<LinkModel>;
41
41
  /**
42
42
  */
43
- setChildModels(models: Array<ModularUIModel>): void;
43
+ setChildModels(models: Array<ModularUIModel>, errors: Array<ErrorResponse>): void;
44
44
  /**
45
45
  * get key
46
46
  */
@@ -53,7 +53,15 @@ export default class FormObjectModel extends BaseModel {
53
53
  */
54
54
  get hasEndResultConfiguration(): boolean;
55
55
  /**
56
- * Indicates if object is dynamic. A dynamic object should be submitted on each attribute change
56
+ * Indicates if object is dynamic.
57
+ *
58
+ * A subtle difference exists between objects for wizard style instrument dialogs and other objects.
59
+ * In the 'missing object' response, wizard style objects will include only the first attribute(s) to be answered,
60
+ * while other objects will include the complete set of attributes of that object.
61
+ *
62
+ * This difference is condensed in the term of 'dynamic objects': these objects start (in the 'missing object' response)
63
+ * with a very select set of attributes to be answered, and each successive 'missing elements' response will include next attributes to be answered.
64
+ * When an object is dynamic, the form contributions will mention a "dynamicObject": true property.
57
65
  */
58
66
  get isDynamic(): boolean;
59
67
  /**
@@ -194,5 +202,6 @@ import ErrorCollection from "../error/ErrorCollection";
194
202
  import { AttributeType } from "../types";
195
203
  import LinkModel from "../links/LinkModel";
196
204
  import { ModularUIModel } from "../types";
205
+ import ErrorResponse from "../error/ErrorResponse";
197
206
  import { FormErrorAnchor } from "../types";
198
207
  import { MessageParameters } from "../../i18n";
@@ -3,7 +3,7 @@ export default normalizeLinkJSON;
3
3
  * Normalize various link formats from services into a concistent format
4
4
  * @private
5
5
  */
6
- declare function normalizeLinkJSON(data: Object, contributions: Object): {
6
+ declare function normalizeLinkJSON(data: Object, contributions: Object): Array<{
7
7
  data: any;
8
8
  contributions: any;
9
- }[];
9
+ }>;
@@ -11,6 +11,9 @@ export default class ListModel extends ResourceModel {
11
11
  _listItemCollection: ListItemCollection;
12
12
  _grouping: GroupingModel;
13
13
  _selfhref: ListHref;
14
+ /**
15
+ */
16
+ setChildModels(models: Array<ModularUIModel>): void;
14
17
  /**
15
18
  * Add detail model to the {ListModel}
16
19
  */
@@ -136,4 +139,5 @@ import ActionCollection from "../actions/ActionCollection";
136
139
  import ListItemCollection from "../list/ListItemCollection";
137
140
  import GroupingModel from "../grouping/GroupingModel";
138
141
  import ListHref from "../href/ListHref";
142
+ import { ModularUIModel } from "../types";
139
143
  import ListItemModel from "../list/ListItemModel";
@@ -6,6 +6,9 @@ export default class GroupingPanelModel extends ResourceModel {
6
6
  /**
7
7
  */
8
8
  get panelLinks(): LinkCollection;
9
+ /**
10
+ */
11
+ setChildModels(models: Array<ModularUIModel>): void;
9
12
  /**
10
13
  * Check if an introtext exists for this caseview
11
14
  */
@@ -37,3 +40,4 @@ export default class GroupingPanelModel extends ResourceModel {
37
40
  import ResourceModel from "../base/ResourceModel";
38
41
  import TaskGroupCollection from "../taskgroup/TaskGroupCollection";
39
42
  import LinkCollection from "../links/LinkCollection";
43
+ import { ModularUIModel } from "../types";
@@ -4,6 +4,9 @@
4
4
  export default class TabModel extends ResourceModel {
5
5
  _actionCollection: ActionCollection;
6
6
  _taskGroupCollection: TaskGroupCollection;
7
+ /**
8
+ */
9
+ setChildModels(models: Array<ModularUIModel>): void;
7
10
  /**
8
11
  */
9
12
  get searchLink(): LinkModel;
@@ -40,5 +43,6 @@ export default class TabModel extends ResourceModel {
40
43
  import ResourceModel from "../base/ResourceModel";
41
44
  import ActionCollection from "../actions/ActionCollection";
42
45
  import TaskGroupCollection from "../taskgroup/TaskGroupCollection";
46
+ import { ModularUIModel } from "../types";
43
47
  import LinkModel from "../links/LinkModel";
44
48
  import LinkCollection from "../links/LinkCollection";
@@ -44,7 +44,7 @@ export interface ILayoutHintRule {
44
44
  }
45
45
  export interface IModelWithChildModels {
46
46
  getInitialChildModelLinks(): Array<LinkModel>;
47
- setChildModels(models: Array<ModularUIModel>): void;
47
+ setChildModels(models: Array<ModularUIModel>, errors: Array<ErrorResponse>): void;
48
48
  }
49
49
  type AuthenticationType = {
50
50
  name: string;
@@ -158,4 +158,5 @@ type ContentData = {
158
158
  import AttributeModel from "./attributes/AttributeModel";
159
159
  import AttributeCollection from "./attributes/AttributeCollection";
160
160
  import LinkModel from "./links/LinkModel";
161
+ import ErrorResponse from "./error/ErrorResponse";
161
162
  export {};
@@ -4,6 +4,13 @@ export default UserServicesModel;
4
4
  */
5
5
  declare class UserServicesModel extends ResourceModel {
6
6
  _user: UserModel | null;
7
+ _mustChangePassword: boolean;
8
+ /**
9
+ */
10
+ set mustChangePassword(mustChangePassword: boolean);
11
+ /**
12
+ */
13
+ get mustChangePassword(): boolean;
7
14
  /**
8
15
  * Set user data
9
16
  */
@@ -4,6 +4,7 @@ type PreferenceValue = string | boolean | {
4
4
  type UpdateFormOptions = {
5
5
  autosubmit: boolean;
6
6
  autosave: boolean;
7
+ autoupdate: boolean;
7
8
  forceUpdate?: boolean;
8
9
  /** Default true: Activate/deactivate the form object validate by an update */
9
10
  validate?: boolean;
@@ -28,11 +28,12 @@ type RequestOptions = {
28
28
  RequestURLOptions: any;
29
29
  RequestBaseOptions: any;
30
30
  };
31
+ type UpdateHandler = (newModel: ModularUIModel) => ModularUIModel;
31
32
  type RequestModularUIOptions = {
32
33
  RequestBaseOptions: any;
33
34
  targetModel?: any;
34
35
  forceTargetModel?: boolean;
35
- updateModel?: ModularUIModel;
36
+ updateHandler?: void | UpdateHandler;
36
37
  childmodels?: boolean;
37
38
  isValidationRequest?: boolean;
38
39
  removeOnUnmount?: boolean;