@saltcorn/data 0.9.0-beta.1 → 0.9.0-beta.10
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/base-plugin/actions.d.ts +294 -14
- package/dist/base-plugin/actions.d.ts.map +1 -1
- package/dist/base-plugin/actions.js +20 -3
- package/dist/base-plugin/actions.js.map +1 -1
- package/dist/base-plugin/fieldviews.d.ts +9 -0
- package/dist/base-plugin/fieldviews.d.ts.map +1 -1
- package/dist/base-plugin/fieldviews.js +10 -0
- package/dist/base-plugin/fieldviews.js.map +1 -1
- package/dist/base-plugin/fileviews.d.ts +8 -0
- package/dist/base-plugin/fileviews.js +8 -0
- package/dist/base-plugin/fileviews.js.map +1 -1
- package/dist/base-plugin/index.d.ts +451 -397
- package/dist/base-plugin/index.d.ts.map +1 -1
- package/dist/base-plugin/types.d.ts +252 -162
- package/dist/base-plugin/types.d.ts.map +1 -1
- package/dist/base-plugin/types.js +78 -6
- package/dist/base-plugin/types.js.map +1 -1
- package/dist/base-plugin/viewtemplates/edit.d.ts.map +1 -1
- package/dist/base-plugin/viewtemplates/edit.js +58 -32
- package/dist/base-plugin/viewtemplates/edit.js.map +1 -1
- package/dist/base-plugin/viewtemplates/feed.d.ts +1 -1
- package/dist/base-plugin/viewtemplates/feed.d.ts.map +1 -1
- package/dist/base-plugin/viewtemplates/feed.js +27 -6
- package/dist/base-plugin/viewtemplates/feed.js.map +1 -1
- package/dist/base-plugin/viewtemplates/show.d.ts +2 -1
- package/dist/base-plugin/viewtemplates/show.d.ts.map +1 -1
- package/dist/base-plugin/viewtemplates/show.js +17 -3
- package/dist/base-plugin/viewtemplates/show.js.map +1 -1
- package/dist/base-plugin/viewtemplates/viewable_fields.d.ts +2 -2
- package/dist/base-plugin/viewtemplates/viewable_fields.d.ts.map +1 -1
- package/dist/base-plugin/viewtemplates/viewable_fields.js +24 -10
- package/dist/base-plugin/viewtemplates/viewable_fields.js.map +1 -1
- package/dist/db/fixtures.d.ts.map +1 -1
- package/dist/db/fixtures.js +33 -3
- package/dist/db/fixtures.js.map +1 -1
- package/dist/db/state.d.ts +5 -2
- package/dist/db/state.d.ts.map +1 -1
- package/dist/db/state.js +14 -2
- package/dist/db/state.js.map +1 -1
- package/dist/diagram/node_extract_utils.d.ts.map +1 -1
- package/dist/diagram/node_extract_utils.js +3 -1
- package/dist/diagram/node_extract_utils.js.map +1 -1
- package/dist/models/config.d.ts.map +1 -1
- package/dist/models/config.js +15 -0
- package/dist/models/config.js.map +1 -1
- package/dist/models/eventlog.d.ts +1 -0
- package/dist/models/eventlog.d.ts.map +1 -1
- package/dist/models/eventlog.js +4 -0
- package/dist/models/eventlog.js.map +1 -1
- package/dist/models/field.d.ts.map +1 -1
- package/dist/models/field.js +6 -2
- package/dist/models/field.js.map +1 -1
- package/dist/models/model.d.ts.map +1 -1
- package/dist/models/model.js +12 -2
- package/dist/models/model.js.map +1 -1
- package/dist/models/model_instance.d.ts +1 -1
- package/dist/models/model_instance.d.ts.map +1 -1
- package/dist/models/model_instance.js +24 -1
- package/dist/models/model_instance.js.map +1 -1
- package/dist/models/table.d.ts +2 -2
- package/dist/models/table.d.ts.map +1 -1
- package/dist/models/table.js +40 -23
- package/dist/models/table.js.map +1 -1
- package/dist/models/tag_entry.d.ts +2 -1
- package/dist/models/tag_entry.d.ts.map +1 -1
- package/dist/models/tag_entry.js.map +1 -1
- package/dist/models/workflow.d.ts +2 -0
- package/dist/models/workflow.d.ts.map +1 -1
- package/dist/models/workflow.js +6 -2
- package/dist/models/workflow.js.map +1 -1
- package/dist/plugin-helper.d.ts.map +1 -1
- package/dist/plugin-helper.js +54 -2
- package/dist/plugin-helper.js.map +1 -1
- package/dist/tests/exact_views.test.js +1 -1
- package/dist/tests/exact_views.test.js.map +1 -1
- package/dist/web-mobile-commons.d.ts +6 -1
- package/dist/web-mobile-commons.d.ts.map +1 -1
- package/dist/web-mobile-commons.js +205 -1
- package/dist/web-mobile-commons.js.map +1 -1
- package/package.json +7 -7
|
@@ -1,98 +1,4 @@
|
|
|
1
1
|
export const types: ({
|
|
2
|
-
name: string;
|
|
3
|
-
sql_name: string;
|
|
4
|
-
js_type: string;
|
|
5
|
-
contract: () => Function;
|
|
6
|
-
fieldviews: {
|
|
7
|
-
show: {
|
|
8
|
-
isEdit: boolean;
|
|
9
|
-
run: (v: any) => any;
|
|
10
|
-
};
|
|
11
|
-
checkboxes: {
|
|
12
|
-
isEdit: boolean;
|
|
13
|
-
run: (v: any) => any;
|
|
14
|
-
};
|
|
15
|
-
TrueFalse: {
|
|
16
|
-
isEdit: boolean;
|
|
17
|
-
run: (v: any) => "" | "True" | "False";
|
|
18
|
-
};
|
|
19
|
-
edit: {
|
|
20
|
-
isEdit: boolean;
|
|
21
|
-
configFields: {
|
|
22
|
-
name: string;
|
|
23
|
-
label: string;
|
|
24
|
-
type: string;
|
|
25
|
-
attributes: {
|
|
26
|
-
options: string[];
|
|
27
|
-
};
|
|
28
|
-
}[];
|
|
29
|
-
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
30
|
-
};
|
|
31
|
-
switch: {
|
|
32
|
-
isEdit: boolean;
|
|
33
|
-
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
34
|
-
};
|
|
35
|
-
tristate: {
|
|
36
|
-
isEdit: boolean;
|
|
37
|
-
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
38
|
-
};
|
|
39
|
-
};
|
|
40
|
-
attributes: object[];
|
|
41
|
-
readFromFormRecord: (rec: any, name: string) => boolean | null;
|
|
42
|
-
read: (v: object) => boolean | null;
|
|
43
|
-
readFromDB: (v: object) => object;
|
|
44
|
-
listAs: (v: object) => object;
|
|
45
|
-
validate: () => boolean;
|
|
46
|
-
} | {
|
|
47
|
-
name: string;
|
|
48
|
-
sql_name: string;
|
|
49
|
-
js_type: string;
|
|
50
|
-
contract: () => Function;
|
|
51
|
-
attributes: object[];
|
|
52
|
-
fieldviews: {
|
|
53
|
-
show: {
|
|
54
|
-
isEdit: boolean;
|
|
55
|
-
run: (d: any, req: any) => any;
|
|
56
|
-
};
|
|
57
|
-
showDay: {
|
|
58
|
-
isEdit: boolean;
|
|
59
|
-
run: (d: any, req: any) => any;
|
|
60
|
-
};
|
|
61
|
-
format: {
|
|
62
|
-
isEdit: boolean;
|
|
63
|
-
configFields: {
|
|
64
|
-
name: string;
|
|
65
|
-
label: string;
|
|
66
|
-
type: string;
|
|
67
|
-
sublabel: string;
|
|
68
|
-
}[];
|
|
69
|
-
run: (d: any, req: any, options: any) => any;
|
|
70
|
-
};
|
|
71
|
-
relative: {
|
|
72
|
-
isEdit: boolean;
|
|
73
|
-
run: (d: any, req: any) => string;
|
|
74
|
-
};
|
|
75
|
-
yearsAgo: {
|
|
76
|
-
isEdit: boolean;
|
|
77
|
-
run: (d: any, req: any) => string;
|
|
78
|
-
};
|
|
79
|
-
edit: {
|
|
80
|
-
isEdit: boolean;
|
|
81
|
-
blockDisplay: boolean;
|
|
82
|
-
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
83
|
-
};
|
|
84
|
-
editDay: {
|
|
85
|
-
isEdit: boolean;
|
|
86
|
-
blockDisplay: boolean;
|
|
87
|
-
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
88
|
-
};
|
|
89
|
-
};
|
|
90
|
-
presets: {
|
|
91
|
-
Now: () => Date;
|
|
92
|
-
};
|
|
93
|
-
read: (v: object, attrs: object) => object;
|
|
94
|
-
validate: () => boolean;
|
|
95
|
-
} | {
|
|
96
2
|
name: string;
|
|
97
3
|
sql_name: string;
|
|
98
4
|
js_type: string;
|
|
@@ -103,16 +9,30 @@ export const types: ({
|
|
|
103
9
|
fieldviews: {
|
|
104
10
|
as_text: {
|
|
105
11
|
isEdit: boolean;
|
|
12
|
+
description: string;
|
|
106
13
|
run: (s: any) => string;
|
|
107
14
|
};
|
|
108
15
|
preFormatted: {
|
|
109
16
|
isEdit: boolean;
|
|
17
|
+
description: string;
|
|
110
18
|
run: (s: any) => any;
|
|
111
19
|
};
|
|
112
20
|
code: {
|
|
113
21
|
isEdit: boolean;
|
|
22
|
+
description: string;
|
|
114
23
|
run: (s: any) => any;
|
|
115
24
|
};
|
|
25
|
+
ellipsize: {
|
|
26
|
+
isEdit: boolean;
|
|
27
|
+
configFields: {
|
|
28
|
+
name: string;
|
|
29
|
+
label: string;
|
|
30
|
+
type: string;
|
|
31
|
+
default: number;
|
|
32
|
+
}[];
|
|
33
|
+
description: string;
|
|
34
|
+
run: (s: any, req: any, attrs?: {}) => string;
|
|
35
|
+
};
|
|
116
36
|
as_link: {
|
|
117
37
|
configFields: {
|
|
118
38
|
name: string;
|
|
@@ -120,20 +40,24 @@ export const types: ({
|
|
|
120
40
|
type: string;
|
|
121
41
|
sublabel: string;
|
|
122
42
|
}[];
|
|
43
|
+
description: string;
|
|
123
44
|
isEdit: boolean;
|
|
124
45
|
run: (s: any, req: any, attrs?: {}) => any;
|
|
125
46
|
};
|
|
126
47
|
img_from_url: {
|
|
127
48
|
isEdit: boolean;
|
|
49
|
+
description: string;
|
|
128
50
|
run: (s: any, req: any, attrs: any) => any;
|
|
129
51
|
};
|
|
130
52
|
as_header: {
|
|
131
53
|
isEdit: boolean;
|
|
54
|
+
description: string;
|
|
132
55
|
run: (s: any) => any;
|
|
133
56
|
};
|
|
134
57
|
edit: {
|
|
135
58
|
isEdit: boolean;
|
|
136
59
|
blockDisplay: boolean;
|
|
60
|
+
description: string;
|
|
137
61
|
configFields: (field: any) => ({
|
|
138
62
|
name: string;
|
|
139
63
|
label: string;
|
|
@@ -161,6 +85,7 @@ export const types: ({
|
|
|
161
85
|
fill_formula_btn: {
|
|
162
86
|
isEdit: boolean;
|
|
163
87
|
blockDisplay: boolean;
|
|
88
|
+
description: string;
|
|
164
89
|
configFields: ({
|
|
165
90
|
name: string;
|
|
166
91
|
label: string;
|
|
@@ -205,6 +130,7 @@ export const types: ({
|
|
|
205
130
|
make_unique: {
|
|
206
131
|
isEdit: boolean;
|
|
207
132
|
blockDisplay: boolean;
|
|
133
|
+
description: string;
|
|
208
134
|
configFields: ({
|
|
209
135
|
name: string;
|
|
210
136
|
label: string;
|
|
@@ -232,6 +158,7 @@ export const types: ({
|
|
|
232
158
|
textarea: {
|
|
233
159
|
isEdit: boolean;
|
|
234
160
|
blockDisplay: boolean;
|
|
161
|
+
description: string;
|
|
235
162
|
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
236
163
|
};
|
|
237
164
|
radio_group: {
|
|
@@ -241,11 +168,13 @@ export const types: ({
|
|
|
241
168
|
name: string;
|
|
242
169
|
label: string;
|
|
243
170
|
}[];
|
|
171
|
+
description: string;
|
|
244
172
|
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
245
173
|
};
|
|
246
174
|
checkbox_group: {
|
|
247
175
|
isEdit: boolean;
|
|
248
176
|
isFilter: boolean;
|
|
177
|
+
description: string;
|
|
249
178
|
configFields: {
|
|
250
179
|
type: string;
|
|
251
180
|
name: string;
|
|
@@ -256,6 +185,7 @@ export const types: ({
|
|
|
256
185
|
password: {
|
|
257
186
|
isEdit: boolean;
|
|
258
187
|
blockDisplay: boolean;
|
|
188
|
+
description: string;
|
|
259
189
|
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
260
190
|
};
|
|
261
191
|
};
|
|
@@ -284,11 +214,13 @@ export const types: ({
|
|
|
284
214
|
fieldviews: {
|
|
285
215
|
show: {
|
|
286
216
|
isEdit: boolean;
|
|
217
|
+
description: string;
|
|
287
218
|
run: (s: any) => string;
|
|
288
219
|
};
|
|
289
220
|
edit: {
|
|
290
221
|
isEdit: boolean;
|
|
291
222
|
blockDisplay: boolean;
|
|
223
|
+
description: string;
|
|
292
224
|
configFields: {
|
|
293
225
|
name: string;
|
|
294
226
|
label: string;
|
|
@@ -303,6 +235,7 @@ export const types: ({
|
|
|
303
235
|
required: boolean;
|
|
304
236
|
}[];
|
|
305
237
|
isEdit: boolean;
|
|
238
|
+
description: string;
|
|
306
239
|
blockDisplay: boolean;
|
|
307
240
|
run: (nm: any, v: any, attrs: {} | undefined, cls: any, required: any, field: any) => any;
|
|
308
241
|
};
|
|
@@ -315,6 +248,7 @@ export const types: ({
|
|
|
315
248
|
isEdit: boolean;
|
|
316
249
|
isFilter: boolean;
|
|
317
250
|
blockDisplay: boolean;
|
|
251
|
+
description: string;
|
|
318
252
|
run: (nm: any, v: any, attrs: {} | undefined, cls: any, required: any, field: any, state?: {}) => any;
|
|
319
253
|
};
|
|
320
254
|
progress_bar: {
|
|
@@ -330,6 +264,7 @@ export const types: ({
|
|
|
330
264
|
required?: undefined;
|
|
331
265
|
})[];
|
|
332
266
|
isEdit: boolean;
|
|
267
|
+
description: string;
|
|
333
268
|
run: (v: any, req: any, attrs?: {}) => any;
|
|
334
269
|
};
|
|
335
270
|
heat_cell: {
|
|
@@ -365,6 +300,7 @@ export const types: ({
|
|
|
365
300
|
attributes?: undefined;
|
|
366
301
|
})[];
|
|
367
302
|
isEdit: boolean;
|
|
303
|
+
description: string;
|
|
368
304
|
run: (v: any, req: any, attrs?: {}) => any;
|
|
369
305
|
};
|
|
370
306
|
above_input: {
|
|
@@ -390,6 +326,7 @@ export const types: ({
|
|
|
390
326
|
run: (nm: any, v: any, attrs: {} | undefined, cls: any, required: any, field: any, state?: {}) => any;
|
|
391
327
|
};
|
|
392
328
|
show_star_rating: {
|
|
329
|
+
description: string;
|
|
393
330
|
configFields: (field: any) => {
|
|
394
331
|
name: string;
|
|
395
332
|
type: string;
|
|
@@ -401,6 +338,7 @@ export const types: ({
|
|
|
401
338
|
run: (v: any, req: any, attrs?: {}) => any;
|
|
402
339
|
};
|
|
403
340
|
edit_star_rating: {
|
|
341
|
+
description: string;
|
|
404
342
|
configFields: (field: any) => {
|
|
405
343
|
name: string;
|
|
406
344
|
type: string;
|
|
@@ -416,6 +354,27 @@ export const types: ({
|
|
|
416
354
|
validate_attributes: ({ min, max }: object) => boolean;
|
|
417
355
|
read: (v: object) => object;
|
|
418
356
|
validate: ({ min, max }: object) => boolean;
|
|
357
|
+
} | {
|
|
358
|
+
name: string;
|
|
359
|
+
sql_name: string;
|
|
360
|
+
js_type: string;
|
|
361
|
+
contract: () => Function;
|
|
362
|
+
fieldviews: {
|
|
363
|
+
show: {
|
|
364
|
+
isEdit: boolean;
|
|
365
|
+
description: string;
|
|
366
|
+
run: (s: any) => any;
|
|
367
|
+
};
|
|
368
|
+
edit: {
|
|
369
|
+
isEdit: boolean;
|
|
370
|
+
blockDisplay: boolean;
|
|
371
|
+
description: string;
|
|
372
|
+
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
373
|
+
};
|
|
374
|
+
};
|
|
375
|
+
attributes: object[];
|
|
376
|
+
read: (v: object) => object;
|
|
377
|
+
validate: () => boolean;
|
|
419
378
|
} | {
|
|
420
379
|
name: string;
|
|
421
380
|
sql_name: string;
|
|
@@ -427,11 +386,13 @@ export const types: ({
|
|
|
427
386
|
fieldviews: {
|
|
428
387
|
show: {
|
|
429
388
|
isEdit: boolean;
|
|
389
|
+
description: string;
|
|
430
390
|
run: (s: any) => string;
|
|
431
391
|
};
|
|
432
392
|
edit: {
|
|
433
393
|
isEdit: boolean;
|
|
434
394
|
blockDisplay: boolean;
|
|
395
|
+
description: string;
|
|
435
396
|
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
436
397
|
};
|
|
437
398
|
number_slider: {
|
|
@@ -441,6 +402,7 @@ export const types: ({
|
|
|
441
402
|
required: boolean;
|
|
442
403
|
}[];
|
|
443
404
|
isEdit: boolean;
|
|
405
|
+
description: string;
|
|
444
406
|
blockDisplay: boolean;
|
|
445
407
|
run: (nm: any, v: any, attrs: {} | undefined, cls: any, required: any, field: any) => any;
|
|
446
408
|
};
|
|
@@ -453,6 +415,7 @@ export const types: ({
|
|
|
453
415
|
isEdit: boolean;
|
|
454
416
|
isFilter: boolean;
|
|
455
417
|
blockDisplay: boolean;
|
|
418
|
+
description: string;
|
|
456
419
|
run: (nm: any, v: any, attrs: {} | undefined, cls: any, required: any, field: any, state?: {}) => any;
|
|
457
420
|
};
|
|
458
421
|
progress_bar: {
|
|
@@ -468,6 +431,7 @@ export const types: ({
|
|
|
468
431
|
required?: undefined;
|
|
469
432
|
})[];
|
|
470
433
|
isEdit: boolean;
|
|
434
|
+
description: string;
|
|
471
435
|
run: (v: any, req: any, attrs?: {}) => any;
|
|
472
436
|
};
|
|
473
437
|
heat_cell: {
|
|
@@ -503,6 +467,7 @@ export const types: ({
|
|
|
503
467
|
attributes?: undefined;
|
|
504
468
|
})[];
|
|
505
469
|
isEdit: boolean;
|
|
470
|
+
description: string;
|
|
506
471
|
run: (v: any, req: any, attrs?: {}) => any;
|
|
507
472
|
};
|
|
508
473
|
above_input: {
|
|
@@ -526,175 +491,230 @@ export const types: ({
|
|
|
526
491
|
sql_name: string;
|
|
527
492
|
js_type: string;
|
|
528
493
|
contract: () => Function;
|
|
494
|
+
attributes: object[];
|
|
529
495
|
fieldviews: {
|
|
530
496
|
show: {
|
|
531
497
|
isEdit: boolean;
|
|
532
|
-
|
|
498
|
+
description: string;
|
|
499
|
+
run: (d: any, req: any) => any;
|
|
500
|
+
};
|
|
501
|
+
showDay: {
|
|
502
|
+
isEdit: boolean;
|
|
503
|
+
description: string;
|
|
504
|
+
run: (d: any, req: any) => any;
|
|
505
|
+
};
|
|
506
|
+
format: {
|
|
507
|
+
isEdit: boolean;
|
|
508
|
+
description: string;
|
|
509
|
+
configFields: {
|
|
510
|
+
name: string;
|
|
511
|
+
label: string;
|
|
512
|
+
type: string;
|
|
513
|
+
sublabel: string;
|
|
514
|
+
}[];
|
|
515
|
+
run: (d: any, req: any, options: any) => any;
|
|
516
|
+
};
|
|
517
|
+
relative: {
|
|
518
|
+
isEdit: boolean;
|
|
519
|
+
description: string;
|
|
520
|
+
run: (d: any, req: any) => string;
|
|
521
|
+
};
|
|
522
|
+
yearsAgo: {
|
|
523
|
+
isEdit: boolean;
|
|
524
|
+
description: string;
|
|
525
|
+
run: (d: any, req: any) => string;
|
|
533
526
|
};
|
|
534
527
|
edit: {
|
|
535
528
|
isEdit: boolean;
|
|
536
529
|
blockDisplay: boolean;
|
|
530
|
+
description: string;
|
|
531
|
+
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
532
|
+
};
|
|
533
|
+
editDay: {
|
|
534
|
+
isEdit: boolean;
|
|
535
|
+
blockDisplay: boolean;
|
|
536
|
+
description: string;
|
|
537
|
+
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
538
|
+
};
|
|
539
|
+
};
|
|
540
|
+
presets: {
|
|
541
|
+
Now: () => Date;
|
|
542
|
+
};
|
|
543
|
+
read: (v: object, attrs: object) => object;
|
|
544
|
+
validate: () => boolean;
|
|
545
|
+
} | {
|
|
546
|
+
name: string;
|
|
547
|
+
sql_name: string;
|
|
548
|
+
js_type: string;
|
|
549
|
+
contract: () => Function;
|
|
550
|
+
fieldviews: {
|
|
551
|
+
show: {
|
|
552
|
+
isEdit: boolean;
|
|
553
|
+
description: string;
|
|
554
|
+
run: (v: any) => any;
|
|
555
|
+
};
|
|
556
|
+
checkboxes: {
|
|
557
|
+
isEdit: boolean;
|
|
558
|
+
description: string;
|
|
559
|
+
run: (v: any) => any;
|
|
560
|
+
};
|
|
561
|
+
TrueFalse: {
|
|
562
|
+
isEdit: boolean;
|
|
563
|
+
description: string;
|
|
564
|
+
run: (v: any) => "" | "True" | "False";
|
|
565
|
+
};
|
|
566
|
+
edit: {
|
|
567
|
+
isEdit: boolean;
|
|
568
|
+
description: string;
|
|
569
|
+
configFields: {
|
|
570
|
+
name: string;
|
|
571
|
+
label: string;
|
|
572
|
+
type: string;
|
|
573
|
+
attributes: {
|
|
574
|
+
options: string[];
|
|
575
|
+
};
|
|
576
|
+
}[];
|
|
577
|
+
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
578
|
+
};
|
|
579
|
+
switch: {
|
|
580
|
+
isEdit: boolean;
|
|
581
|
+
description: string;
|
|
582
|
+
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
583
|
+
};
|
|
584
|
+
tristate: {
|
|
585
|
+
isEdit: boolean;
|
|
586
|
+
description: string;
|
|
537
587
|
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
538
588
|
};
|
|
539
589
|
};
|
|
540
590
|
attributes: object[];
|
|
541
|
-
|
|
591
|
+
readFromFormRecord: (rec: any, name: string) => boolean | null;
|
|
592
|
+
read: (v: object) => boolean | null;
|
|
593
|
+
readFromDB: (v: object) => object;
|
|
594
|
+
listAs: (v: object) => object;
|
|
542
595
|
validate: () => boolean;
|
|
543
596
|
})[];
|
|
544
597
|
export const viewtemplates: ({
|
|
545
598
|
name: string;
|
|
546
599
|
description: string;
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
}, state:
|
|
553
|
-
|
|
554
|
-
}) => Promise<
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
}
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
}, { actionQuery }: {
|
|
565
|
-
actionQuery: any;
|
|
566
|
-
}) => Promise<any>;
|
|
567
|
-
};
|
|
568
|
-
queries: ({ table_id, viewname, configuration: { columns }, req, res, exttable_name, }: {
|
|
600
|
+
configuration_workflow: (req: object) => import("../models/workflow");
|
|
601
|
+
run: (table_id: string, viewname: string, { list_view, show_view, list_width, subtables }: {
|
|
602
|
+
list_view: string;
|
|
603
|
+
show_view: string;
|
|
604
|
+
subtables: object;
|
|
605
|
+
}, state: any, extraArgs: any, { getRowQuery }: {
|
|
606
|
+
getRowQuery: any;
|
|
607
|
+
}) => Promise<div>;
|
|
608
|
+
get_state_fields: (table_id: any, viewname: any, { list_view, show_view }: {
|
|
609
|
+
list_view: string;
|
|
610
|
+
show_view: any;
|
|
611
|
+
}) => Promise<object[]>;
|
|
612
|
+
display_state_form: ({ list_view, _omit_state_form }: {
|
|
613
|
+
list_view: string;
|
|
614
|
+
_omit_state_form: boolean;
|
|
615
|
+
}) => boolean;
|
|
616
|
+
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
569
617
|
table_id: any;
|
|
570
618
|
viewname: any;
|
|
571
619
|
configuration: {
|
|
572
620
|
columns: any;
|
|
621
|
+
default_state: any;
|
|
573
622
|
};
|
|
574
623
|
req: any;
|
|
575
|
-
res: any;
|
|
576
|
-
exttable_name: any;
|
|
577
624
|
}) => {
|
|
578
|
-
|
|
579
|
-
json: any;
|
|
580
|
-
}>;
|
|
581
|
-
distinctValuesQuery(state: any): Promise<{
|
|
582
|
-
distinct_values: {};
|
|
583
|
-
role: any;
|
|
584
|
-
}>;
|
|
625
|
+
getRowQuery(uniques: any): Promise<import("@saltcorn/db-common/internal").Row | null>;
|
|
585
626
|
};
|
|
627
|
+
connectedObjects: ({ list_view, subtables }: {
|
|
628
|
+
list_view: any;
|
|
629
|
+
subtables: any;
|
|
630
|
+
}) => Promise<{
|
|
631
|
+
embeddedViews: import("../models/view")[];
|
|
632
|
+
}>;
|
|
586
633
|
} | {
|
|
587
634
|
name: string;
|
|
588
635
|
description: string;
|
|
589
636
|
configuration_workflow: (req: object) => import("../models/workflow");
|
|
590
|
-
run: (table_id: number, viewname: string,
|
|
591
|
-
req: object;
|
|
592
|
-
res: object;
|
|
593
|
-
}, { editQuery }: {
|
|
594
|
-
editQuery: any;
|
|
595
|
-
}) => Promise<import("../models/form")>;
|
|
596
|
-
runMany: (table_id: number, viewname: string, { columns, layout, auto_save, split_paste }: {
|
|
597
|
-
columns: any;
|
|
598
|
-
layout: any;
|
|
599
|
-
}, state: State, extra: object, { editManyQuery, getRowQuery, optionsQuery }: {
|
|
600
|
-
editManyQuery: any;
|
|
601
|
-
getRowQuery: any;
|
|
602
|
-
optionsQuery: any;
|
|
603
|
-
}) => Promise<import("../models/form")[]>;
|
|
604
|
-
runPost: (table_id: number, viewname: string, { columns, layout, fixed, view_when_done, formula_destinations, auto_save, destination_type, dest_url_formula, page_when_done, }: {
|
|
637
|
+
run: (table_id: string | number, viewname: string, { columns, view_to_create, create_view_display, create_view_label, default_state, create_view_location, create_link_style, create_link_size, }: {
|
|
605
638
|
columns: object[];
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
saveFileQuery: any;
|
|
619
|
-
optionsQuery: any;
|
|
620
|
-
getRowByIdQuery: any;
|
|
621
|
-
}, remote: any) => Promise<void>;
|
|
622
|
-
get_state_fields: (table_id: any, viewname: any, { columns }: {
|
|
623
|
-
columns: any;
|
|
624
|
-
}) => Promise<object[]>;
|
|
639
|
+
view_to_create?: string | undefined;
|
|
640
|
+
create_view_display: string;
|
|
641
|
+
create_view_label?: string | undefined;
|
|
642
|
+
default_state?: object | undefined;
|
|
643
|
+
create_view_location?: string | undefined;
|
|
644
|
+
}, stateWithId?: object | undefined, extraOpts: object, { listQuery }: {
|
|
645
|
+
listQuery: any;
|
|
646
|
+
}) => Promise<any>;
|
|
647
|
+
view_quantity: string;
|
|
648
|
+
get_state_fields: (table_id: string, viewname: any, { columns }: {
|
|
649
|
+
columns: object[];
|
|
650
|
+
}) => Function;
|
|
625
651
|
initial_config: Function;
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
}
|
|
640
|
-
|
|
641
|
-
|
|
652
|
+
on_delete: (table_id: any, viewname: string, { default_state }: {
|
|
653
|
+
default_state: any;
|
|
654
|
+
}) => Promise<void>;
|
|
655
|
+
routes: {
|
|
656
|
+
run_action: (table_id: number, viewname: any, { columns, layout }: {
|
|
657
|
+
columns: object[];
|
|
658
|
+
layout: any;
|
|
659
|
+
}, body: object, { req, res }: {
|
|
660
|
+
req: object;
|
|
661
|
+
res: any;
|
|
662
|
+
}, { getRowQuery }: {
|
|
663
|
+
getRowQuery: any;
|
|
664
|
+
}) => Promise<object>;
|
|
665
|
+
};
|
|
666
|
+
display_state_form: (opts: object) => boolean;
|
|
667
|
+
default_state_form: ({ default_state }: object) => boolean;
|
|
668
|
+
getStringsForI18n({ columns, create_view_label }: {
|
|
669
|
+
columns: any;
|
|
670
|
+
create_view_label: any;
|
|
642
671
|
}): string[];
|
|
643
|
-
queries: ({ table_id, name, configuration: { columns, default_state
|
|
672
|
+
queries: ({ table_id, exttable_name, name, configuration: { columns, default_state }, req, }: {
|
|
644
673
|
table_id: any;
|
|
674
|
+
exttable_name: any;
|
|
645
675
|
name: any;
|
|
646
676
|
configuration: {
|
|
647
677
|
columns: any;
|
|
648
678
|
default_state: any;
|
|
649
|
-
layout: any;
|
|
650
|
-
auto_save: any;
|
|
651
|
-
split_paste: any;
|
|
652
|
-
destination_type: any;
|
|
653
679
|
};
|
|
654
680
|
req: any;
|
|
655
|
-
res: any;
|
|
656
681
|
}) => {
|
|
657
|
-
|
|
658
|
-
editManyQuery(state: any, { limit, offset, orderBy, orderDesc, where }: {
|
|
659
|
-
limit: any;
|
|
660
|
-
offset: any;
|
|
661
|
-
orderBy: any;
|
|
662
|
-
orderDesc: any;
|
|
663
|
-
where: any;
|
|
664
|
-
}): Promise<{
|
|
665
|
-
table: import("../models/table") | null;
|
|
666
|
-
fields: import("../models/field")[];
|
|
682
|
+
listQuery(state: any, stateHash: any): Promise<{
|
|
667
683
|
rows: import("@saltcorn/db-common/internal").Row[];
|
|
684
|
+
rowCount: number;
|
|
668
685
|
}>;
|
|
669
|
-
|
|
670
|
-
error: string;
|
|
671
|
-
} | {
|
|
672
|
-
success: any;
|
|
673
|
-
}>;
|
|
674
|
-
tryUpdateQuery(row: any, id: any): Promise<any>;
|
|
675
|
-
saveFileQuery(fieldVal: any, fieldId: any, fieldView: any, row: any): Promise<string | number>;
|
|
676
|
-
authorizePostQuery(body: any, table_id: any): Promise<boolean | "" | null | undefined>;
|
|
677
|
-
authorizeGetQuery(query: any, table_id: any): Promise<string | boolean | null | undefined>;
|
|
678
|
-
getRowQuery(table_id: any, view_select: any, row_id: any): Promise<import("@saltcorn/db-common/internal").Row[]>;
|
|
679
|
-
getRowByIdQuery(id: any): Promise<import("@saltcorn/db-common/internal").Row | null>;
|
|
680
|
-
actionQuery(): Promise<{
|
|
681
|
-
json: any;
|
|
682
|
-
}>;
|
|
683
|
-
optionsQuery(reftable_name: any, type: any, attributes: any, where: any): Promise<any>;
|
|
684
|
-
updateMatchingQuery(where: any, updateVals: any, repeatFields: any, childRows: any): Promise<any[] | {
|
|
685
|
-
rowError: any;
|
|
686
|
-
inEditError?: undefined;
|
|
687
|
-
error?: undefined;
|
|
688
|
-
} | {
|
|
689
|
-
inEditError: any;
|
|
690
|
-
rowError?: undefined;
|
|
691
|
-
error?: undefined;
|
|
692
|
-
} | {
|
|
693
|
-
error: any;
|
|
694
|
-
rowError?: undefined;
|
|
695
|
-
inEditError?: undefined;
|
|
696
|
-
}>;
|
|
686
|
+
getRowQuery(id: any): Promise<import("@saltcorn/db-common/internal").Row | null>;
|
|
697
687
|
};
|
|
688
|
+
configCheck: (view: any) => Promise<{
|
|
689
|
+
errors: string[];
|
|
690
|
+
warnings: string[];
|
|
691
|
+
}>;
|
|
692
|
+
connectedObjects: (configuration: any) => Promise<import("@saltcorn/types/base_types").ConnectedObjects>;
|
|
693
|
+
} | {
|
|
694
|
+
name: string;
|
|
695
|
+
description: string;
|
|
696
|
+
get_state_fields: () => object[];
|
|
697
|
+
configuration_workflow: (req: object) => import("../models/workflow");
|
|
698
|
+
run: (table_id: string, viewname: string, { columns, layout, page_title, page_title_formula }: {
|
|
699
|
+
columns: object[];
|
|
700
|
+
layout: object;
|
|
701
|
+
page_title?: string | undefined;
|
|
702
|
+
page_title_formula: boolean;
|
|
703
|
+
}, state: object, extra: object, { showQuery }: {
|
|
704
|
+
showQuery: any;
|
|
705
|
+
}) => Promise<string>;
|
|
706
|
+
runMany: (table_id: number, viewname: string, { columns, layout }: {
|
|
707
|
+
columns: object[];
|
|
708
|
+
layout: object;
|
|
709
|
+
}, state: object, extra: object, { runManyQuery }: {
|
|
710
|
+
runManyQuery: any;
|
|
711
|
+
}) => Promise<object[]>;
|
|
712
|
+
renderRows: (table: object, viewname: string, { columns, layout }: {
|
|
713
|
+
columns: object[];
|
|
714
|
+
layout: object;
|
|
715
|
+
}, extra: object, rows: object[], state: any) => Promise<string>;
|
|
716
|
+
initial_config: Function;
|
|
717
|
+
display_state_form: boolean;
|
|
698
718
|
routes: {
|
|
699
719
|
run_action: (table_id: number, viewname: any, { columns, layout }: {
|
|
700
720
|
columns: object[];
|
|
@@ -705,33 +725,85 @@ export const viewtemplates: ({
|
|
|
705
725
|
}, { actionQuery }: {
|
|
706
726
|
actionQuery: any;
|
|
707
727
|
}) => Promise<object>;
|
|
708
|
-
|
|
728
|
+
};
|
|
729
|
+
getStringsForI18n({ layout }: {
|
|
730
|
+
layout: object;
|
|
731
|
+
}): string[];
|
|
732
|
+
queries: ({ table_id, exttable_name, name, configuration: { columns, layout }, req, res, }: {
|
|
733
|
+
table_id: any;
|
|
734
|
+
exttable_name: any;
|
|
735
|
+
name: any;
|
|
736
|
+
configuration: {
|
|
709
737
|
columns: any;
|
|
710
738
|
layout: any;
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
}
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
739
|
+
};
|
|
740
|
+
req: any;
|
|
741
|
+
res: any;
|
|
742
|
+
}) => {
|
|
743
|
+
showQuery(state: any, fields: any): Promise<{
|
|
744
|
+
rows: null;
|
|
745
|
+
message: string;
|
|
746
|
+
} | {
|
|
747
|
+
rows: import("@saltcorn/db-common/internal").Row[];
|
|
748
|
+
message: null;
|
|
749
|
+
}>;
|
|
750
|
+
runManyQuery(state: any, { where, limit, offset, joinFieldsExtra, orderBy, orderDesc }: {
|
|
751
|
+
where: any;
|
|
752
|
+
limit: any;
|
|
753
|
+
offset: any;
|
|
754
|
+
joinFieldsExtra: any;
|
|
755
|
+
orderBy: any;
|
|
756
|
+
orderDesc: any;
|
|
757
|
+
}): Promise<import("@saltcorn/db-common/internal").Row[]>;
|
|
758
|
+
actionQuery(): Promise<{
|
|
759
|
+
json: any;
|
|
760
|
+
}>;
|
|
729
761
|
};
|
|
730
762
|
configCheck: (view: any) => Promise<{
|
|
731
763
|
errors: string[];
|
|
732
764
|
warnings: string[];
|
|
733
765
|
}>;
|
|
734
766
|
connectedObjects: (configuration: any) => Promise<import("@saltcorn/types/base_types").ConnectedObjects>;
|
|
767
|
+
} | {
|
|
768
|
+
name: string;
|
|
769
|
+
description: string;
|
|
770
|
+
configuration_workflow: (req: object) => import("../models/workflow");
|
|
771
|
+
run: (table_id: number, viewname: string, { show_view, order_field, descending, view_to_create, create_view_display, in_card, view_decoration, initial_open_accordions, title_formula, masonry_columns, rows_per_page, hide_pagination, create_view_label, create_view_location, create_link_style, create_link_size, always_create_view, include_fml, empty_view, ...cols }: {
|
|
772
|
+
show_view: string;
|
|
773
|
+
order_field: name;
|
|
774
|
+
descending: boolean;
|
|
775
|
+
view_to_create?: string | undefined;
|
|
776
|
+
create_view_display: string;
|
|
777
|
+
in_card: boolean;
|
|
778
|
+
masonry_columns: string;
|
|
779
|
+
rows_per_page?: number | undefined;
|
|
780
|
+
hide_pagination: boolean;
|
|
781
|
+
create_view_label?: string | undefined;
|
|
782
|
+
create_view_location?: string | undefined;
|
|
783
|
+
always_create_view: boolean;
|
|
784
|
+
cols: any;
|
|
785
|
+
}, state: object, extraArgs: any, { countRowsQuery }: {
|
|
786
|
+
countRowsQuery: any;
|
|
787
|
+
}) => Promise<div>;
|
|
788
|
+
get_state_fields: (table_id: number, viewname: any, { show_view }: {
|
|
789
|
+
show_view: any;
|
|
790
|
+
}) => Promise<import("../models/field")>;
|
|
791
|
+
display_state_form: boolean;
|
|
792
|
+
getStringsForI18n({ create_view_label }: {
|
|
793
|
+
create_view_label: any;
|
|
794
|
+
}): string[] | Object[];
|
|
795
|
+
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
796
|
+
table_id: any;
|
|
797
|
+
viewname: any;
|
|
798
|
+
configuration: {
|
|
799
|
+
columns: any;
|
|
800
|
+
default_state: any;
|
|
801
|
+
};
|
|
802
|
+
req: any;
|
|
803
|
+
}) => {
|
|
804
|
+
countRowsQuery(state: any): Promise<number>;
|
|
805
|
+
};
|
|
806
|
+
connectedObjects: (configuration: any) => Promise<import("@saltcorn/types/base_types").ConnectedObjects>;
|
|
735
807
|
} | {
|
|
736
808
|
name: string;
|
|
737
809
|
description: string;
|
|
@@ -836,169 +908,145 @@ export const viewtemplates: ({
|
|
|
836
908
|
name: string;
|
|
837
909
|
description: string;
|
|
838
910
|
configuration_workflow: (req: object) => import("../models/workflow");
|
|
839
|
-
run: (table_id: number, viewname: string,
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
countRowsQuery: any;
|
|
855
|
-
}) => Promise<div>;
|
|
856
|
-
get_state_fields: (table_id: number, viewname: any, { show_view }: {
|
|
857
|
-
show_view: any;
|
|
858
|
-
}) => Promise<import("../models/field")>;
|
|
859
|
-
display_state_form: boolean;
|
|
860
|
-
getStringsForI18n({ create_view_label }: {
|
|
861
|
-
create_view_label: any;
|
|
862
|
-
}): string[] | Object[];
|
|
863
|
-
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
864
|
-
table_id: any;
|
|
865
|
-
viewname: any;
|
|
866
|
-
configuration: {
|
|
867
|
-
columns: any;
|
|
868
|
-
default_state: any;
|
|
869
|
-
};
|
|
870
|
-
req: any;
|
|
871
|
-
}) => {
|
|
872
|
-
countRowsQuery(state: any): Promise<number>;
|
|
873
|
-
};
|
|
874
|
-
connectedObjects: (configuration: any) => Promise<import("@saltcorn/types/base_types").ConnectedObjects>;
|
|
875
|
-
} | {
|
|
876
|
-
name: string;
|
|
877
|
-
description: string;
|
|
878
|
-
get_state_fields: () => object[];
|
|
879
|
-
configuration_workflow: (req: object) => import("../models/workflow");
|
|
880
|
-
run: (table_id: string, viewname: string, { columns, layout, page_title, page_title_formula }: {
|
|
881
|
-
columns: object[];
|
|
882
|
-
layout: object;
|
|
883
|
-
page_title?: string | undefined;
|
|
884
|
-
page_title_formula: boolean;
|
|
885
|
-
}, state: object, extra: object, { showQuery }: {
|
|
886
|
-
showQuery: any;
|
|
887
|
-
}) => Promise<string>;
|
|
888
|
-
runMany: (table_id: number, viewname: string, { columns, layout }: {
|
|
911
|
+
run: (table_id: number, viewname: string, cfg: any, state: string, { res, req }: {
|
|
912
|
+
req: object;
|
|
913
|
+
res: object;
|
|
914
|
+
}, { editQuery }: {
|
|
915
|
+
editQuery: any;
|
|
916
|
+
}) => Promise<import("../models/form")>;
|
|
917
|
+
runMany: (table_id: number, viewname: string, { columns, layout, auto_save, split_paste }: {
|
|
918
|
+
columns: any;
|
|
919
|
+
layout: any;
|
|
920
|
+
}, state: State, extra: object, { editManyQuery, getRowQuery, optionsQuery }: {
|
|
921
|
+
editManyQuery: any;
|
|
922
|
+
getRowQuery: any;
|
|
923
|
+
optionsQuery: any;
|
|
924
|
+
}) => Promise<import("../models/form")[]>;
|
|
925
|
+
runPost: (table_id: number, viewname: string, { columns, layout, fixed, view_when_done, formula_destinations, auto_save, destination_type, dest_url_formula, page_when_done, }: {
|
|
889
926
|
columns: object[];
|
|
890
|
-
layout:
|
|
891
|
-
|
|
892
|
-
|
|
927
|
+
layout: Layout;
|
|
928
|
+
fixed: object;
|
|
929
|
+
view_when_done: boolean;
|
|
930
|
+
formula_destinations: object[];
|
|
931
|
+
}, state: object, body: any, { res, req, redirect }: {
|
|
932
|
+
res: object;
|
|
933
|
+
req: object;
|
|
934
|
+
redirect: string;
|
|
935
|
+
}, { tryInsertQuery, tryUpdateQuery, getRowQuery, saveFileQuery, optionsQuery, getRowByIdQuery, }: {
|
|
936
|
+
tryInsertQuery: any;
|
|
937
|
+
tryUpdateQuery: any;
|
|
938
|
+
getRowQuery: any;
|
|
939
|
+
saveFileQuery: any;
|
|
940
|
+
optionsQuery: any;
|
|
941
|
+
getRowByIdQuery: any;
|
|
942
|
+
}, remote: any) => Promise<void>;
|
|
943
|
+
get_state_fields: (table_id: any, viewname: any, { columns }: {
|
|
944
|
+
columns: any;
|
|
893
945
|
}) => Promise<object[]>;
|
|
894
|
-
renderRows: (table: object, viewname: string, { columns, layout }: {
|
|
895
|
-
columns: object[];
|
|
896
|
-
layout: object;
|
|
897
|
-
}, extra: object, rows: object[], state: any) => Promise<string>;
|
|
898
946
|
initial_config: Function;
|
|
899
947
|
display_state_form: boolean;
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
}
|
|
948
|
+
authorise_post: ({ body, table_id, req }: {
|
|
949
|
+
body: object;
|
|
950
|
+
table_id: string;
|
|
951
|
+
req: object;
|
|
952
|
+
}, { authorizePostQuery }: {
|
|
953
|
+
authorizePostQuery: any;
|
|
954
|
+
}) => Promise<boolean>;
|
|
955
|
+
authorise_get: ({ query, table_id, req }: {
|
|
956
|
+
query: object;
|
|
957
|
+
rest: any;
|
|
958
|
+
}, { authorizeGetQuery }: {
|
|
959
|
+
authorizeGetQuery: any;
|
|
960
|
+
}) => Promise<boolean>;
|
|
911
961
|
getStringsForI18n({ layout }: {
|
|
912
|
-
layout:
|
|
962
|
+
layout: Layout;
|
|
913
963
|
}): string[];
|
|
914
|
-
queries: ({ table_id,
|
|
964
|
+
queries: ({ table_id, name, configuration: { columns, default_state, layout, auto_save, split_paste, destination_type, }, req, res, }: {
|
|
915
965
|
table_id: any;
|
|
916
|
-
exttable_name: any;
|
|
917
966
|
name: any;
|
|
918
967
|
configuration: {
|
|
919
968
|
columns: any;
|
|
969
|
+
default_state: any;
|
|
920
970
|
layout: any;
|
|
971
|
+
auto_save: any;
|
|
972
|
+
split_paste: any;
|
|
973
|
+
destination_type: any;
|
|
921
974
|
};
|
|
922
975
|
req: any;
|
|
923
976
|
res: any;
|
|
924
977
|
}) => {
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
message: string;
|
|
928
|
-
} | {
|
|
929
|
-
rows: import("@saltcorn/db-common/internal").Row[];
|
|
930
|
-
message: null;
|
|
931
|
-
}>;
|
|
932
|
-
runManyQuery(state: any, { where, limit, offset, orderBy, orderDesc }: {
|
|
933
|
-
where: any;
|
|
978
|
+
editQuery(state: any, mobileReferrer: any): Promise<import("../models/form")>;
|
|
979
|
+
editManyQuery(state: any, { limit, offset, orderBy, orderDesc, where }: {
|
|
934
980
|
limit: any;
|
|
935
981
|
offset: any;
|
|
936
982
|
orderBy: any;
|
|
937
983
|
orderDesc: any;
|
|
938
|
-
|
|
984
|
+
where: any;
|
|
985
|
+
}): Promise<{
|
|
986
|
+
table: import("../models/table") | null;
|
|
987
|
+
fields: import("../models/field")[];
|
|
988
|
+
rows: import("@saltcorn/db-common/internal").Row[];
|
|
989
|
+
}>;
|
|
990
|
+
tryInsertQuery(row: any): Promise<{
|
|
991
|
+
error: string;
|
|
992
|
+
} | {
|
|
993
|
+
success: any;
|
|
994
|
+
}>;
|
|
995
|
+
tryUpdateQuery(row: any, id: any): Promise<any>;
|
|
996
|
+
saveFileQuery(fieldVal: any, fieldId: any, fieldView: any, row: any): Promise<string | number>;
|
|
997
|
+
authorizePostQuery(body: any, table_id: any): Promise<boolean | "" | null | undefined>;
|
|
998
|
+
authorizeGetQuery(query: any, table_id: any): Promise<string | boolean | null | undefined>;
|
|
999
|
+
getRowQuery(table_id: any, view_select: any, row_id: any): Promise<import("@saltcorn/db-common/internal").Row[]>;
|
|
1000
|
+
getRowByIdQuery(id: any): Promise<import("@saltcorn/db-common/internal").Row | null>;
|
|
939
1001
|
actionQuery(): Promise<{
|
|
940
1002
|
json: any;
|
|
941
1003
|
}>;
|
|
1004
|
+
optionsQuery(reftable_name: any, type: any, attributes: any, where: any): Promise<any>;
|
|
1005
|
+
updateMatchingQuery(where: any, updateVals: any, repeatFields: any, childRows: any): Promise<any[] | {
|
|
1006
|
+
rowError: any;
|
|
1007
|
+
inEditError?: undefined;
|
|
1008
|
+
error?: undefined;
|
|
1009
|
+
} | {
|
|
1010
|
+
inEditError: any;
|
|
1011
|
+
rowError?: undefined;
|
|
1012
|
+
error?: undefined;
|
|
1013
|
+
} | {
|
|
1014
|
+
error: any;
|
|
1015
|
+
rowError?: undefined;
|
|
1016
|
+
inEditError?: undefined;
|
|
1017
|
+
}>;
|
|
942
1018
|
};
|
|
943
|
-
configCheck: (view: any) => Promise<{
|
|
944
|
-
errors: string[];
|
|
945
|
-
warnings: string[];
|
|
946
|
-
}>;
|
|
947
|
-
connectedObjects: (configuration: any) => Promise<import("@saltcorn/types/base_types").ConnectedObjects>;
|
|
948
|
-
} | {
|
|
949
|
-
name: string;
|
|
950
|
-
description: string;
|
|
951
|
-
configuration_workflow: (req: object) => import("../models/workflow");
|
|
952
|
-
run: (table_id: string | number, viewname: string, { columns, view_to_create, create_view_display, create_view_label, default_state, create_view_location, create_link_style, create_link_size, }: {
|
|
953
|
-
columns: object[];
|
|
954
|
-
view_to_create?: string | undefined;
|
|
955
|
-
create_view_display: string;
|
|
956
|
-
create_view_label?: string | undefined;
|
|
957
|
-
default_state?: object | undefined;
|
|
958
|
-
create_view_location?: string | undefined;
|
|
959
|
-
}, stateWithId?: object | undefined, extraOpts: object, { listQuery }: {
|
|
960
|
-
listQuery: any;
|
|
961
|
-
}) => Promise<any>;
|
|
962
|
-
view_quantity: string;
|
|
963
|
-
get_state_fields: (table_id: string, viewname: any, { columns }: {
|
|
964
|
-
columns: object[];
|
|
965
|
-
}) => Function;
|
|
966
|
-
initial_config: Function;
|
|
967
|
-
on_delete: (table_id: any, viewname: string, { default_state }: {
|
|
968
|
-
default_state: any;
|
|
969
|
-
}) => Promise<void>;
|
|
970
1019
|
routes: {
|
|
971
1020
|
run_action: (table_id: number, viewname: any, { columns, layout }: {
|
|
972
1021
|
columns: object[];
|
|
973
1022
|
layout: any;
|
|
974
|
-
}, body:
|
|
1023
|
+
}, body: any, { req, res }: {
|
|
975
1024
|
req: object;
|
|
976
1025
|
res: any;
|
|
977
|
-
}, {
|
|
978
|
-
|
|
1026
|
+
}, { actionQuery }: {
|
|
1027
|
+
actionQuery: any;
|
|
979
1028
|
}) => Promise<object>;
|
|
980
|
-
|
|
981
|
-
display_state_form: (opts: object) => boolean;
|
|
982
|
-
default_state_form: ({ default_state }: object) => boolean;
|
|
983
|
-
getStringsForI18n({ columns, create_view_label }: {
|
|
984
|
-
columns: any;
|
|
985
|
-
create_view_label: any;
|
|
986
|
-
}): string[];
|
|
987
|
-
queries: ({ table_id, exttable_name, name, configuration: { columns, default_state }, req, }: {
|
|
988
|
-
table_id: any;
|
|
989
|
-
exttable_name: any;
|
|
990
|
-
name: any;
|
|
991
|
-
configuration: {
|
|
1029
|
+
update_matching_rows: (table_id: any, viewname: any, { columns, layout, fixed, view_when_done, formula_destinations, auto_save, destination_type, dest_url_formula, page_when_done, }: {
|
|
992
1030
|
columns: any;
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1031
|
+
layout: any;
|
|
1032
|
+
fixed: any;
|
|
1033
|
+
view_when_done: any;
|
|
1034
|
+
formula_destinations: any;
|
|
1035
|
+
auto_save: any;
|
|
1036
|
+
destination_type: any;
|
|
1037
|
+
dest_url_formula: any;
|
|
1038
|
+
page_when_done: any;
|
|
1039
|
+
}, body: any, { req, res, redirect }: {
|
|
1040
|
+
req: any;
|
|
1041
|
+
res: any;
|
|
1042
|
+
redirect: any;
|
|
1043
|
+
}, { updateMatchingQuery, getRowQuery, saveFileQuery, optionsQuery, getRowByIdQuery, }: {
|
|
1044
|
+
updateMatchingQuery: any;
|
|
1045
|
+
getRowQuery: any;
|
|
1046
|
+
saveFileQuery: any;
|
|
1047
|
+
optionsQuery: any;
|
|
1048
|
+
getRowByIdQuery: any;
|
|
1049
|
+
}) => Promise<void>;
|
|
1002
1050
|
};
|
|
1003
1051
|
configCheck: (view: any) => Promise<{
|
|
1004
1052
|
errors: string[];
|
|
@@ -1008,39 +1056,45 @@ export const viewtemplates: ({
|
|
|
1008
1056
|
} | {
|
|
1009
1057
|
name: string;
|
|
1010
1058
|
description: string;
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
}, state:
|
|
1017
|
-
|
|
1018
|
-
}) => Promise<
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1059
|
+
get_state_fields: () => object[];
|
|
1060
|
+
configuration_workflow: () => import("../models/workflow");
|
|
1061
|
+
run: (table_id: number, viewname: string, { columns, layout }: {
|
|
1062
|
+
columns: object[];
|
|
1063
|
+
layout: object;
|
|
1064
|
+
}, state: object, extra: object, { distinctValuesQuery }: {
|
|
1065
|
+
distinctValuesQuery: any;
|
|
1066
|
+
}) => Promise<Layout>;
|
|
1067
|
+
initial_config: () => Promise<object>;
|
|
1068
|
+
display_state_form: boolean;
|
|
1069
|
+
getStringsForI18n({ layout }: {
|
|
1070
|
+
layout: any;
|
|
1071
|
+
}): string[];
|
|
1072
|
+
routes: {
|
|
1073
|
+
run_action: (table_id: any, viewname: any, config: any, body: any, { req, res }: {
|
|
1074
|
+
req: any;
|
|
1075
|
+
res: any;
|
|
1076
|
+
}, { actionQuery }: {
|
|
1077
|
+
actionQuery: any;
|
|
1078
|
+
}) => Promise<any>;
|
|
1079
|
+
};
|
|
1080
|
+
queries: ({ table_id, viewname, configuration: { columns }, req, res, exttable_name, }: {
|
|
1028
1081
|
table_id: any;
|
|
1029
1082
|
viewname: any;
|
|
1030
1083
|
configuration: {
|
|
1031
1084
|
columns: any;
|
|
1032
|
-
default_state: any;
|
|
1033
1085
|
};
|
|
1034
1086
|
req: any;
|
|
1087
|
+
res: any;
|
|
1088
|
+
exttable_name: any;
|
|
1035
1089
|
}) => {
|
|
1036
|
-
|
|
1090
|
+
actionQuery(state: any, rndid: any): Promise<{
|
|
1091
|
+
json: any;
|
|
1092
|
+
}>;
|
|
1093
|
+
distinctValuesQuery(state: any): Promise<{
|
|
1094
|
+
distinct_values: {};
|
|
1095
|
+
role: any;
|
|
1096
|
+
}>;
|
|
1037
1097
|
};
|
|
1038
|
-
connectedObjects: ({ list_view, subtables }: {
|
|
1039
|
-
list_view: any;
|
|
1040
|
-
subtables: any;
|
|
1041
|
-
}) => Promise<{
|
|
1042
|
-
embeddedViews: import("../models/view")[];
|
|
1043
|
-
}>;
|
|
1044
1098
|
})[];
|
|
1045
1099
|
import fileviews = require("./fileviews");
|
|
1046
1100
|
import actions = require("./actions");
|