@evoke-platform/ui-components 1.4.0-testing.1 → 1.4.0-testing.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.
- package/dist/published/components/custom/CriteriaBuilder/CriteriaBuilder.js +1 -17
- package/dist/published/components/custom/CriteriaBuilder/ValueEditor.js +23 -8
- package/dist/published/components/custom/CriteriaBuilder/index.d.ts +2 -1
- package/dist/published/components/custom/CriteriaBuilder/index.js +2 -1
- package/dist/published/components/custom/CriteriaBuilder/utils.d.ts +13 -0
- package/dist/published/components/custom/CriteriaBuilder/utils.js +58 -1
- package/dist/published/components/custom/Form/Common/Form.js +20 -21
- package/dist/published/components/custom/Form/Common/FormComponentWrapper.js +2 -1
- package/dist/published/components/custom/Form/FormComponents/ObjectComponent/ObjectComponent.d.ts +2 -0
- package/dist/published/components/custom/Form/FormComponents/ObjectComponent/ObjectComponent.js +75 -26
- package/dist/published/components/custom/Form/FormComponents/RepeatableFieldComponent/ActionDialog.d.ts +5 -2
- package/dist/published/components/custom/Form/FormComponents/RepeatableFieldComponent/ActionDialog.js +4 -6
- package/dist/published/components/custom/Form/FormComponents/RepeatableFieldComponent/RepeatableField.js +3 -1
- package/dist/published/components/custom/Form/FormComponents/RepeatableFieldComponent/RepeatableFieldComponent.js +31 -13
- package/dist/published/components/custom/Form/tests/Form.test.d.ts +1 -0
- package/dist/published/components/custom/Form/tests/Form.test.js +112 -0
- package/dist/published/components/custom/Form/tests/test-data.d.ts +13 -0
- package/dist/published/components/custom/Form/tests/test-data.js +282 -0
- package/dist/published/components/custom/Form/utils.d.ts +10 -4
- package/dist/published/components/custom/Form/utils.js +133 -52
- package/dist/published/components/custom/HistoryLog/DisplayedProperty.d.ts +2 -1
- package/dist/published/components/custom/HistoryLog/DisplayedProperty.js +5 -2
- package/dist/published/components/custom/HistoryLog/HistoryData.d.ts +1 -0
- package/dist/published/components/custom/HistoryLog/HistoryData.js +9 -3
- package/dist/published/components/custom/HistoryLog/index.js +24 -2
- package/dist/published/components/custom/index.d.ts +1 -1
- package/dist/published/components/custom/index.js +1 -1
- package/dist/published/index.d.ts +1 -1
- package/dist/published/index.js +1 -1
- package/package.json +2 -3
@@ -0,0 +1,112 @@
|
|
1
|
+
import { ApiServices } from '@evoke-platform/context';
|
2
|
+
import { render, screen, waitFor, within } from '@testing-library/react';
|
3
|
+
import userEvent from '@testing-library/user-event';
|
4
|
+
import axios from 'axios';
|
5
|
+
import { isEqual } from 'lodash';
|
6
|
+
import { http, HttpResponse } from 'msw';
|
7
|
+
import { setupServer } from 'msw/node';
|
8
|
+
import React from 'react';
|
9
|
+
import { it } from 'vitest';
|
10
|
+
import Form from '../Common/Form';
|
11
|
+
import { licenseObject, npLicense, npSpecialtyType1, npSpecialtyType2, rnLicense, rnSpecialtyType1, rnSpecialtyType2, specialtyObject, specialtyTypeObject, } from './test-data';
|
12
|
+
const removePoppers = () => {
|
13
|
+
const portalSelectors = ['.MuiAutocomplete-popper'];
|
14
|
+
portalSelectors.forEach((selector) => {
|
15
|
+
// eslint-disable-next-line testing-library/no-node-access
|
16
|
+
document.querySelectorAll(selector).forEach((el) => el.remove());
|
17
|
+
});
|
18
|
+
};
|
19
|
+
describe('Form component', () => {
|
20
|
+
let server;
|
21
|
+
let apiServices;
|
22
|
+
beforeAll(() => {
|
23
|
+
server = setupServer(http.get('/data/objects/specialtyType/effective', () => HttpResponse.json(specialtyTypeObject)), http.get('/data/objects/license/effective', () => HttpResponse.json(licenseObject)), http.get('/data/objects/license/instances', () => {
|
24
|
+
return HttpResponse.json([rnLicense, npLicense]);
|
25
|
+
}), http.get('/data/objects/specialtyType/instances', (req) => {
|
26
|
+
const filter = new URL(req.request.url).searchParams.get('filter');
|
27
|
+
if (filter) {
|
28
|
+
const whereFilter = JSON.parse(filter).where;
|
29
|
+
// The two objects in the array of conditions in the "where" filter represent the potential filters that can be applied when retrieving "specialty" instances.
|
30
|
+
// The first object is for the the validation criteria, but it is empty if the "license" field, which is referenced in the validation criteria, hasn't been filled out yet.
|
31
|
+
// The second object is for the search criteria which the user enters in the "specialty" field, but it is empty if no search text has been entered.
|
32
|
+
if (isEqual(whereFilter, { and: [{}, {}] }))
|
33
|
+
return HttpResponse.json([
|
34
|
+
rnSpecialtyType1,
|
35
|
+
rnSpecialtyType2,
|
36
|
+
npSpecialtyType1,
|
37
|
+
npSpecialtyType2,
|
38
|
+
]);
|
39
|
+
else if (isEqual(whereFilter, { and: [{ 'licenseType.id': 'rnLicenseType' }, {}] }))
|
40
|
+
return HttpResponse.json([rnSpecialtyType1, rnSpecialtyType2]);
|
41
|
+
else if (isEqual(whereFilter, { and: [{ 'licenseType.id': 'npLicenseType' }, {}] }))
|
42
|
+
return HttpResponse.json([npSpecialtyType1, npSpecialtyType2]);
|
43
|
+
}
|
44
|
+
}));
|
45
|
+
server.listen();
|
46
|
+
});
|
47
|
+
beforeEach(() => {
|
48
|
+
apiServices = new ApiServices(axios.create());
|
49
|
+
});
|
50
|
+
afterAll(() => {
|
51
|
+
server.close();
|
52
|
+
});
|
53
|
+
afterEach(() => {
|
54
|
+
server.resetHandlers();
|
55
|
+
removePoppers();
|
56
|
+
});
|
57
|
+
describe('validation criteria', () => {
|
58
|
+
it(`filters related object field with validation criteria that references a related object's nested data`, async () => {
|
59
|
+
const user = userEvent.setup();
|
60
|
+
server.use(http.get('/data/objects/license/instances/rnLicense', (req) => {
|
61
|
+
const expand = new URL(req.request.url).searchParams.get('expand');
|
62
|
+
if (expand === 'licenseType.id') {
|
63
|
+
return HttpResponse.json(rnLicense);
|
64
|
+
}
|
65
|
+
}));
|
66
|
+
render(React.createElement(Form, { actionId: '_create', actionType: 'create', object: specialtyObject, apiServices: apiServices }));
|
67
|
+
const license = await screen.findByRole('combobox', { name: 'License' });
|
68
|
+
// Validate that specialty type dropdown is rendering all options
|
69
|
+
let specialtyType = await screen.findByRole('combobox', { name: 'Specialty Type' });
|
70
|
+
await user.click(specialtyType);
|
71
|
+
let openAutocomplete = await screen.findByRole('listbox');
|
72
|
+
await within(openAutocomplete).findByRole('option', { name: 'RN Specialty Type #1' });
|
73
|
+
await within(openAutocomplete).findByRole('option', { name: 'RN Specialty Type #2' });
|
74
|
+
await within(openAutocomplete).findByRole('option', { name: 'NP Specialty Type #1' });
|
75
|
+
await within(openAutocomplete).findByRole('option', { name: 'NP Specialty Type #2' });
|
76
|
+
// Close the specialty type dropdown
|
77
|
+
removePoppers();
|
78
|
+
// Select a license from the dropdown
|
79
|
+
await user.click(license);
|
80
|
+
const rnLicenseOption = await screen.findByRole('option', { name: 'RN License' });
|
81
|
+
await user.click(rnLicenseOption);
|
82
|
+
// Validate that specialty type dropdown is only rendering specialty types that are associated with the selected license.
|
83
|
+
specialtyType = await screen.findByRole('combobox', { name: 'Specialty Type' });
|
84
|
+
await user.click(specialtyType);
|
85
|
+
openAutocomplete = await screen.findByRole('listbox');
|
86
|
+
await within(openAutocomplete).findByRole('option', { name: 'RN Specialty Type #1' });
|
87
|
+
await within(openAutocomplete).findByRole('option', { name: 'RN Specialty Type #2' });
|
88
|
+
await waitFor(() => expect(within(openAutocomplete).queryByRole('option', { name: 'NP Specialty Type #1' })).to.be.null);
|
89
|
+
await waitFor(() => expect(within(openAutocomplete).queryByRole('option', { name: 'NP Specialty Type #2' })).to.be.null);
|
90
|
+
});
|
91
|
+
it(`filters related object field with validation criteria that references a defaulted related object's nested data`, async () => {
|
92
|
+
const user = userEvent.setup();
|
93
|
+
server.use(http.get('/data/objects/license/instances/rnLicense', (req) => {
|
94
|
+
const expand = new URL(req.request.url).searchParams.get('expand');
|
95
|
+
if (expand === 'licenseType.id') {
|
96
|
+
return HttpResponse.json(rnLicense);
|
97
|
+
}
|
98
|
+
}));
|
99
|
+
render(React.createElement(Form, { actionId: '_create', actionType: 'create', object: specialtyObject, apiServices: apiServices, associatedObject: { propertyId: 'license', instanceId: 'rnLicense' } }));
|
100
|
+
// Validate that the license field is hidden
|
101
|
+
await waitFor(() => expect(screen.queryByRole('combobox', { name: 'License' })).to.be.null);
|
102
|
+
// Validate that specialty type dropdown is only rendering specialty types that are associated with the selected license.
|
103
|
+
const specialtyType = await screen.findByRole('combobox', { name: 'Specialty Type' });
|
104
|
+
await user.click(specialtyType);
|
105
|
+
const openAutocomplete = await screen.findByRole('listbox');
|
106
|
+
await within(openAutocomplete).findByRole('option', { name: 'RN Specialty Type #1' });
|
107
|
+
await within(openAutocomplete).findByRole('option', { name: 'RN Specialty Type #2' });
|
108
|
+
await waitFor(() => expect(within(openAutocomplete).queryByRole('option', { name: 'NP Specialty Type #1' })).to.be.null);
|
109
|
+
await waitFor(() => expect(within(openAutocomplete).queryByRole('option', { name: 'NP Specialty Type #2' })).to.be.null);
|
110
|
+
});
|
111
|
+
});
|
112
|
+
});
|
@@ -0,0 +1,13 @@
|
|
1
|
+
import { Obj, ObjectInstance } from '@evoke-platform/context';
|
2
|
+
export declare const licenseObject: Obj;
|
3
|
+
export declare const licenseTypeObject: Obj;
|
4
|
+
export declare const specialtyObject: Obj;
|
5
|
+
export declare const specialtyTypeObject: Obj;
|
6
|
+
export declare const rnLicense: ObjectInstance;
|
7
|
+
export declare const npLicense: ObjectInstance;
|
8
|
+
export declare const rnLicenseType: ObjectInstance;
|
9
|
+
export declare const npLicesneType: ObjectInstance;
|
10
|
+
export declare const rnSpecialtyType1: ObjectInstance;
|
11
|
+
export declare const rnSpecialtyType2: ObjectInstance;
|
12
|
+
export declare const npSpecialtyType1: ObjectInstance;
|
13
|
+
export declare const npSpecialtyType2: ObjectInstance;
|
@@ -0,0 +1,282 @@
|
|
1
|
+
// Objects
|
2
|
+
export const licenseObject = {
|
3
|
+
id: 'license',
|
4
|
+
name: 'License',
|
5
|
+
properties: [
|
6
|
+
{
|
7
|
+
id: 'name',
|
8
|
+
name: 'License Number',
|
9
|
+
type: 'string',
|
10
|
+
},
|
11
|
+
{
|
12
|
+
id: 'status',
|
13
|
+
name: 'Status',
|
14
|
+
type: 'string',
|
15
|
+
enum: ['Active', 'Inactive'],
|
16
|
+
},
|
17
|
+
{
|
18
|
+
id: 'licenseType',
|
19
|
+
name: 'License Type',
|
20
|
+
type: 'object',
|
21
|
+
objectId: 'licenseType',
|
22
|
+
},
|
23
|
+
],
|
24
|
+
actions: [
|
25
|
+
{
|
26
|
+
id: '_update',
|
27
|
+
name: 'Update',
|
28
|
+
type: 'update',
|
29
|
+
outputEvent: 'License Updated',
|
30
|
+
},
|
31
|
+
{
|
32
|
+
id: '_delete',
|
33
|
+
name: 'Delete',
|
34
|
+
type: 'delete',
|
35
|
+
outputEvent: 'License Deleted',
|
36
|
+
},
|
37
|
+
{
|
38
|
+
id: '_create',
|
39
|
+
name: 'Create',
|
40
|
+
type: 'create',
|
41
|
+
outputEvent: 'License Created',
|
42
|
+
},
|
43
|
+
],
|
44
|
+
};
|
45
|
+
export const licenseTypeObject = {
|
46
|
+
id: 'licenseType',
|
47
|
+
name: 'License Type',
|
48
|
+
properties: [
|
49
|
+
{
|
50
|
+
id: 'name',
|
51
|
+
name: 'Name',
|
52
|
+
type: 'string',
|
53
|
+
},
|
54
|
+
{
|
55
|
+
id: 'licenseNumberPrefix',
|
56
|
+
name: 'License Number Prefix',
|
57
|
+
type: 'string',
|
58
|
+
},
|
59
|
+
],
|
60
|
+
actions: [
|
61
|
+
{
|
62
|
+
id: '_update',
|
63
|
+
name: 'Update',
|
64
|
+
type: 'update',
|
65
|
+
outputEvent: 'License Type Updated',
|
66
|
+
},
|
67
|
+
{
|
68
|
+
id: '_delete',
|
69
|
+
name: 'Delete',
|
70
|
+
type: 'delete',
|
71
|
+
outputEvent: 'License Type Deleted',
|
72
|
+
},
|
73
|
+
{
|
74
|
+
id: '_create',
|
75
|
+
name: 'Create',
|
76
|
+
type: 'create',
|
77
|
+
outputEvent: 'License Type Created',
|
78
|
+
},
|
79
|
+
],
|
80
|
+
};
|
81
|
+
export const specialtyObject = {
|
82
|
+
id: 'specialty',
|
83
|
+
name: 'Specialty',
|
84
|
+
properties: [
|
85
|
+
{
|
86
|
+
id: 'name',
|
87
|
+
name: 'Name',
|
88
|
+
type: 'string',
|
89
|
+
},
|
90
|
+
{
|
91
|
+
id: 'specialtyType',
|
92
|
+
name: 'Specialty Type',
|
93
|
+
type: 'object',
|
94
|
+
objectId: 'specialtyType',
|
95
|
+
},
|
96
|
+
{
|
97
|
+
id: 'license',
|
98
|
+
name: 'License',
|
99
|
+
type: 'object',
|
100
|
+
objectId: 'license',
|
101
|
+
},
|
102
|
+
],
|
103
|
+
actions: [
|
104
|
+
{
|
105
|
+
id: '_update',
|
106
|
+
name: 'Update',
|
107
|
+
type: 'update',
|
108
|
+
outputEvent: 'Specialty Updated',
|
109
|
+
},
|
110
|
+
{
|
111
|
+
id: '_delete',
|
112
|
+
name: 'Delete',
|
113
|
+
type: 'delete',
|
114
|
+
outputEvent: 'Specialty Deleted',
|
115
|
+
},
|
116
|
+
{
|
117
|
+
id: '_create',
|
118
|
+
name: 'Create',
|
119
|
+
type: 'create',
|
120
|
+
outputEvent: 'Specialty Created',
|
121
|
+
parameters: [
|
122
|
+
{
|
123
|
+
id: 'name',
|
124
|
+
name: 'Name',
|
125
|
+
type: 'string',
|
126
|
+
},
|
127
|
+
{
|
128
|
+
id: 'specialtyType',
|
129
|
+
name: 'Specialty Type',
|
130
|
+
type: 'object',
|
131
|
+
objectId: 'specialtyType',
|
132
|
+
validation: {
|
133
|
+
criteria: {
|
134
|
+
$and: [{ 'licenseType.id': '{{{input.license.licenseType.id}}}' }],
|
135
|
+
},
|
136
|
+
},
|
137
|
+
},
|
138
|
+
{
|
139
|
+
id: 'license',
|
140
|
+
name: 'License',
|
141
|
+
type: 'object',
|
142
|
+
objectId: 'license',
|
143
|
+
},
|
144
|
+
],
|
145
|
+
form: {
|
146
|
+
entries: [
|
147
|
+
{
|
148
|
+
parameterId: 'name',
|
149
|
+
type: 'input',
|
150
|
+
display: {
|
151
|
+
label: 'Name',
|
152
|
+
},
|
153
|
+
},
|
154
|
+
{
|
155
|
+
parameterId: 'specialtyType',
|
156
|
+
type: 'input',
|
157
|
+
display: {
|
158
|
+
label: 'Specialty Type',
|
159
|
+
relatedObjectDisplay: 'dropdown',
|
160
|
+
},
|
161
|
+
},
|
162
|
+
{
|
163
|
+
parameterId: 'license',
|
164
|
+
type: 'input',
|
165
|
+
display: {
|
166
|
+
label: 'License',
|
167
|
+
relatedObjectDisplay: 'dropdown',
|
168
|
+
},
|
169
|
+
},
|
170
|
+
],
|
171
|
+
},
|
172
|
+
},
|
173
|
+
],
|
174
|
+
};
|
175
|
+
export const specialtyTypeObject = {
|
176
|
+
id: 'specialtyType',
|
177
|
+
name: 'Specialty Type',
|
178
|
+
properties: [
|
179
|
+
{
|
180
|
+
id: 'name',
|
181
|
+
name: 'Name',
|
182
|
+
type: 'string',
|
183
|
+
},
|
184
|
+
{
|
185
|
+
id: 'licenseType',
|
186
|
+
name: 'License Type',
|
187
|
+
type: 'object',
|
188
|
+
objectId: 'licenseType',
|
189
|
+
},
|
190
|
+
],
|
191
|
+
actions: [
|
192
|
+
{
|
193
|
+
id: '_update',
|
194
|
+
name: 'Update',
|
195
|
+
type: 'update',
|
196
|
+
outputEvent: 'Specialty Type Updated',
|
197
|
+
},
|
198
|
+
{
|
199
|
+
id: '_delete',
|
200
|
+
name: 'Delete',
|
201
|
+
type: 'delete',
|
202
|
+
outputEvent: 'Specialty Type Deleted',
|
203
|
+
},
|
204
|
+
{
|
205
|
+
id: '_create',
|
206
|
+
name: 'Create',
|
207
|
+
type: 'create',
|
208
|
+
outputEvent: 'Specialty Type Created',
|
209
|
+
},
|
210
|
+
],
|
211
|
+
};
|
212
|
+
// Instances
|
213
|
+
export const rnLicense = {
|
214
|
+
id: 'rnLicense',
|
215
|
+
objectId: 'license',
|
216
|
+
name: 'RN License',
|
217
|
+
licenseType: {
|
218
|
+
id: 'rnLicenseType',
|
219
|
+
name: 'RN License Type',
|
220
|
+
},
|
221
|
+
status: 'Active',
|
222
|
+
};
|
223
|
+
export const npLicense = {
|
224
|
+
id: 'npLicense',
|
225
|
+
objectId: 'license',
|
226
|
+
name: 'NP License',
|
227
|
+
licenseType: {
|
228
|
+
id: 'npLicenseType',
|
229
|
+
name: 'NP License Type',
|
230
|
+
},
|
231
|
+
status: 'Active',
|
232
|
+
};
|
233
|
+
export const rnLicenseType = {
|
234
|
+
id: 'rnLicenseType',
|
235
|
+
objectId: 'licenseType',
|
236
|
+
name: 'RN License Type',
|
237
|
+
licenseNumberPrefix: 'RN',
|
238
|
+
};
|
239
|
+
export const npLicesneType = {
|
240
|
+
id: 'npLicenseType',
|
241
|
+
objectId: 'licenseType',
|
242
|
+
name: 'NP License Type',
|
243
|
+
licenseNumberPrefix: 'NP',
|
244
|
+
};
|
245
|
+
export const rnSpecialtyType1 = {
|
246
|
+
id: 'specialtyType1',
|
247
|
+
objectId: 'specialtyType',
|
248
|
+
name: 'RN Specialty Type #1',
|
249
|
+
int: 1,
|
250
|
+
licenseType: {
|
251
|
+
id: 'rnLicenseType',
|
252
|
+
name: 'RN License Type',
|
253
|
+
},
|
254
|
+
};
|
255
|
+
export const rnSpecialtyType2 = {
|
256
|
+
id: 'specialtyType2',
|
257
|
+
objectId: 'specialtyType',
|
258
|
+
name: 'RN Specialty Type #2',
|
259
|
+
int: 1,
|
260
|
+
licenseType: {
|
261
|
+
id: 'rnLicenseType',
|
262
|
+
name: 'RN License Type',
|
263
|
+
},
|
264
|
+
};
|
265
|
+
export const npSpecialtyType1 = {
|
266
|
+
id: 'specialtyType3',
|
267
|
+
objectId: 'specialtyType',
|
268
|
+
name: 'NP Specialty Type #1',
|
269
|
+
licenseType: {
|
270
|
+
id: 'npLicenseType',
|
271
|
+
name: 'NP License Type',
|
272
|
+
},
|
273
|
+
};
|
274
|
+
export const npSpecialtyType2 = {
|
275
|
+
id: 'specialtyType4',
|
276
|
+
objectId: 'specialtyType',
|
277
|
+
name: 'NP Specialty Type #2',
|
278
|
+
licenseType: {
|
279
|
+
id: 'npLicenseType',
|
280
|
+
name: 'NP License Type',
|
281
|
+
},
|
282
|
+
};
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { ActionInput, ActionInputType, ApiServices, FormEntry, InputParameter, InputParameterReference, Obj, ObjectInstance, Property, PropertyType } from '@evoke-platform/context';
|
1
|
+
import { ActionInput, ActionInputType, ApiServices, FormEntry, InputParameter, InputParameterReference, Obj, ObjectInstance, Property, PropertyType, UserAccount } from '@evoke-platform/context';
|
2
2
|
import { ReactComponent } from '@formio/react';
|
3
3
|
import { LocalDateTime } from '@js-joda/core';
|
4
4
|
import { AutocompleteOption } from '../../core';
|
@@ -21,7 +21,11 @@ export declare function getMiddleObject(instance: ObjectInstance, property: Prop
|
|
21
21
|
} | undefined;
|
22
22
|
export declare function getMiddleInstance(instanceId: string, property: Property, middleObjectInstances: ObjectInstance[]): ObjectInstance | undefined;
|
23
23
|
export declare function getPrefixedUrl(url: string): string;
|
24
|
-
export declare function
|
24
|
+
export declare function flattenFormComponents(components?: ActionInput[]): ActionInput[];
|
25
|
+
export declare function addObjectPropertiesToComponentProps(properties: Property[], formComponents: any[], allCriteriaInputs?: string[], instance?: ObjectInstance, objectPropertyInputProps?: ObjectPropertyInputProps, associatedObject?: {
|
26
|
+
instanceId?: string;
|
27
|
+
propertyId?: string;
|
28
|
+
}, autoSave?: (data: Record<string, unknown>) => void, readOnly?: boolean, defaultPages?: Record<string, string>, navigateTo?: (path: string) => void, queryAddresses?: (query: string) => Promise<Address[]>, apiServices?: ApiServices, isModal?: boolean, fieldHeight?: 'small' | 'medium', richTextEditor?: typeof ReactComponent): Promise<ActionInput[]>;
|
25
29
|
export declare function getDefaultValue(initialValue: unknown, selectOptions?: AutocompleteOption[]): unknown;
|
26
30
|
export declare const buildComponentPropsFromObjectProperties: (properties: Property[], objectId: string, instance?: ObjectInstance, objectPropertyInputProps?: ObjectPropertyInputProps, hasActionPermissions?: boolean, autoSave?: ((data: Record<string, unknown>) => void) | undefined, readOnly?: boolean, queryAddresses?: ((query: string) => Promise<Address[]>) | undefined, isModal?: boolean, fieldHeight?: 'small' | 'medium', richTextEditor?: typeof ReactComponent) => unknown[];
|
27
31
|
export declare const buildComponentPropsFromDocumentProperties: (documentProperties: [string, unknown][], readOnly?: boolean, autoSave?: ((data: Record<string, unknown>) => void) | undefined, fieldHeight?: 'small' | 'medium') => {
|
@@ -35,8 +39,10 @@ export declare const buildComponentPropsFromDocumentProperties: (documentPropert
|
|
35
39
|
}[];
|
36
40
|
export declare const OPERATOR_MAP: Record<string, string>;
|
37
41
|
export declare function transformToWhere(mongoQuery: object): Record<string, unknown>;
|
38
|
-
export declare function updateCriteriaInputs(criteria: Record<string, unknown>,
|
39
|
-
export declare function
|
42
|
+
export declare function updateCriteriaInputs(criteria: Record<string, unknown>, data: Record<string, unknown>, user?: UserAccount): Record<string, unknown>;
|
43
|
+
export declare function getCriteriaInputs(criteria?: Record<string, unknown>): string[];
|
44
|
+
export declare function getAllCriteriaInputs(components: ActionInput[] | InputParameter[]): string[];
|
45
|
+
export declare function populateInstanceWithNestedData(instanceId: string, objectId: string, paths: string[], apiServices: ApiServices): Promise<ObjectInstance>;
|
40
46
|
export declare function isPropertyVisible(conditional: {
|
41
47
|
when: string;
|
42
48
|
show: boolean;
|