@saltcorn/data 0.7.3-beta.3 → 0.7.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/app-locales/public/da.json +3 -0
- package/dist/base-plugin/actions.d.ts.map +1 -1
- package/dist/base-plugin/actions.js +4 -1
- package/dist/base-plugin/actions.js.map +1 -1
- package/dist/base-plugin/fieldviews.d.ts.map +1 -1
- package/dist/base-plugin/fieldviews.js +7 -0
- package/dist/base-plugin/fieldviews.js.map +1 -1
- package/dist/base-plugin/fileviews.d.ts +19 -0
- package/dist/base-plugin/fileviews.d.ts.map +1 -1
- package/dist/base-plugin/fileviews.js +51 -3
- package/dist/base-plugin/fileviews.js.map +1 -1
- package/dist/base-plugin/index.d.ts +304 -280
- package/dist/base-plugin/index.d.ts.map +1 -1
- package/dist/base-plugin/types.d.ts +110 -80
- package/dist/base-plugin/types.d.ts.map +1 -1
- package/dist/base-plugin/types.js +41 -2
- 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 +5 -2
- package/dist/base-plugin/viewtemplates/edit.js.map +1 -1
- package/dist/base-plugin/viewtemplates/filter.d.ts.map +1 -1
- package/dist/base-plugin/viewtemplates/filter.js +25 -6
- package/dist/base-plugin/viewtemplates/filter.js.map +1 -1
- package/dist/base-plugin/viewtemplates/list.d.ts +2 -1
- package/dist/base-plugin/viewtemplates/list.d.ts.map +1 -1
- package/dist/base-plugin/viewtemplates/list.js +14 -28
- package/dist/base-plugin/viewtemplates/list.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 +10 -32
- package/dist/base-plugin/viewtemplates/show.js.map +1 -1
- package/dist/base-plugin/viewtemplates/viewable_fields.d.ts.map +1 -1
- package/dist/base-plugin/viewtemplates/viewable_fields.js +8 -1
- package/dist/base-plugin/viewtemplates/viewable_fields.js.map +1 -1
- package/dist/db/connect.d.ts.map +1 -1
- package/dist/db/connect.js +11 -5
- package/dist/db/connect.js.map +1 -1
- package/dist/db/fixtures.d.ts.map +1 -1
- package/dist/db/fixtures.js +4 -0
- package/dist/db/fixtures.js.map +1 -1
- package/dist/db/state.d.ts +1 -0
- package/dist/db/state.d.ts.map +1 -1
- package/dist/db/state.js.map +1 -1
- package/dist/migrations/202207022002.d.ts +2 -0
- package/dist/migrations/202207022002.d.ts.map +1 -0
- package/dist/migrations/202207022002.js +4 -0
- package/dist/migrations/202207022002.js.map +1 -0
- package/dist/models/config.js +1 -1
- package/dist/models/config.js.map +1 -1
- package/dist/models/email.d.ts +1 -0
- package/dist/models/email.d.ts.map +1 -1
- package/dist/models/email.js +1 -0
- package/dist/models/email.js.map +1 -1
- package/dist/models/expression.js +1 -1
- package/dist/models/expression.js.map +1 -1
- package/dist/models/field.d.ts +3 -1
- package/dist/models/field.d.ts.map +1 -1
- package/dist/models/field.js +42 -6
- package/dist/models/field.js.map +1 -1
- package/dist/models/form.d.ts.map +1 -1
- package/dist/models/form.js +6 -2
- package/dist/models/form.js.map +1 -1
- package/dist/models/scheduler.d.ts.map +1 -1
- package/dist/models/scheduler.js +33 -28
- package/dist/models/scheduler.js.map +1 -1
- package/dist/models/table.d.ts +6 -0
- package/dist/models/table.d.ts.map +1 -1
- package/dist/models/table.js +68 -6
- package/dist/models/table.js.map +1 -1
- package/dist/models/user.d.ts +7 -0
- package/dist/models/user.d.ts.map +1 -1
- package/dist/models/user.js +14 -2
- package/dist/models/user.js.map +1 -1
- package/dist/models/view.d.ts.map +1 -1
- package/dist/models/view.js +7 -2
- package/dist/models/view.js.map +1 -1
- package/dist/models/workflow.d.ts +3 -0
- package/dist/models/workflow.d.ts.map +1 -1
- package/dist/models/workflow.js +47 -12
- package/dist/models/workflow.js.map +1 -1
- package/dist/plugin-helper.d.ts.map +1 -1
- package/dist/plugin-helper.js +9 -3
- package/dist/plugin-helper.js.map +1 -1
- package/dist/plugin-testing.d.ts.map +1 -1
- package/dist/plugin-testing.js +2 -1
- package/dist/plugin-testing.js.map +1 -1
- package/dist/tests/actions.test.js +3 -3
- package/dist/tests/actions.test.js.map +1 -1
- package/dist/tests/calc.test.js +5 -2
- package/dist/tests/calc.test.js.map +1 -1
- package/dist/tests/exact_views.test.js +5 -3
- package/dist/tests/exact_views.test.js.map +1 -1
- package/dist/tests/fieldviews.test.d.ts +2 -0
- package/dist/tests/fieldviews.test.d.ts.map +1 -0
- package/dist/tests/fieldviews.test.js +74 -0
- package/dist/tests/fieldviews.test.js.map +1 -0
- package/dist/tests/remote_query_helper.d.ts +1 -1
- package/dist/tests/remote_query_helper.d.ts.map +1 -1
- package/dist/tests/remote_query_helper.js +4 -1
- package/dist/tests/remote_query_helper.js.map +1 -1
- package/dist/tests/table.test.js +94 -1
- package/dist/tests/table.test.js.map +1 -1
- package/dist/webpack.config.d.ts +1 -0
- package/dist/webpack.config.js +1 -0
- package/dist/webpack.config.js.map +1 -1
- package/package.json +10 -8
- package/webpack.config.js +82 -0
- package/dist/tsconfig.ref.tsbuildinfo +0 -1
|
@@ -231,7 +231,7 @@ export const types: ({
|
|
|
231
231
|
label: string;
|
|
232
232
|
type: string;
|
|
233
233
|
}[];
|
|
234
|
-
run: (nm: any, v: any, attrs: {} | undefined, cls: any,
|
|
234
|
+
run: (nm: any, v: any, attrs: {} | undefined, cls: any, required: any, field: any, state?: {}) => any;
|
|
235
235
|
};
|
|
236
236
|
below_input: {
|
|
237
237
|
isEdit: boolean;
|
|
@@ -242,93 +242,53 @@ export const types: ({
|
|
|
242
242
|
label: string;
|
|
243
243
|
type: string;
|
|
244
244
|
}[];
|
|
245
|
-
run: (nm: any, v: any, attrs: {} | undefined, cls: any,
|
|
246
|
-
};
|
|
247
|
-
};
|
|
248
|
-
attributes: object[];
|
|
249
|
-
validate_attributes: ({ min, max }: object) => boolean;
|
|
250
|
-
read: (v: object) => object;
|
|
251
|
-
validate: ({ min, max }: object) => boolean;
|
|
252
|
-
} | {
|
|
253
|
-
name: string;
|
|
254
|
-
sql_name: string;
|
|
255
|
-
contract: () => Function;
|
|
256
|
-
fieldviews: {
|
|
257
|
-
show: {
|
|
258
|
-
isEdit: boolean;
|
|
259
|
-
run: (v: any) => any;
|
|
260
|
-
};
|
|
261
|
-
checkboxes: {
|
|
262
|
-
isEdit: boolean;
|
|
263
|
-
run: (v: any) => any;
|
|
264
|
-
};
|
|
265
|
-
TrueFalse: {
|
|
266
|
-
isEdit: boolean;
|
|
267
|
-
run: (v: any) => "" | "True" | "False";
|
|
245
|
+
run: (nm: any, v: any, attrs: {} | undefined, cls: any, required: any, field: any, state?: {}) => any;
|
|
268
246
|
};
|
|
269
|
-
|
|
247
|
+
show_star_rating: {
|
|
248
|
+
configFields: (field: any) => {
|
|
249
|
+
name: string;
|
|
250
|
+
type: string;
|
|
251
|
+
required: boolean;
|
|
252
|
+
default: number;
|
|
253
|
+
}[];
|
|
270
254
|
isEdit: boolean;
|
|
271
|
-
|
|
255
|
+
blockDisplay: boolean;
|
|
256
|
+
run: (v: any, req: any, attrs?: {}) => any;
|
|
272
257
|
};
|
|
273
|
-
|
|
258
|
+
edit_star_rating: {
|
|
259
|
+
configFields: (field: any) => {
|
|
260
|
+
name: string;
|
|
261
|
+
type: string;
|
|
262
|
+
required: boolean;
|
|
263
|
+
default: number;
|
|
264
|
+
}[];
|
|
274
265
|
isEdit: boolean;
|
|
275
|
-
|
|
266
|
+
blockDisplay: boolean;
|
|
267
|
+
run: (nm: any, v: any, attrs: {} | undefined, cls: any, required: any, field: any, state?: {}) => any;
|
|
276
268
|
};
|
|
277
269
|
};
|
|
278
270
|
attributes: object[];
|
|
279
|
-
|
|
280
|
-
read: (v: object) =>
|
|
281
|
-
|
|
282
|
-
listAs: (v: object) => object;
|
|
283
|
-
validate: () => boolean;
|
|
271
|
+
validate_attributes: ({ min, max }: object) => boolean;
|
|
272
|
+
read: (v: object) => object;
|
|
273
|
+
validate: ({ min, max }: object) => boolean;
|
|
284
274
|
} | {
|
|
285
275
|
name: string;
|
|
286
276
|
sql_name: string;
|
|
287
277
|
contract: () => Function;
|
|
288
|
-
attributes: object[];
|
|
289
278
|
fieldviews: {
|
|
290
279
|
show: {
|
|
291
280
|
isEdit: boolean;
|
|
292
|
-
run: (
|
|
293
|
-
};
|
|
294
|
-
showDay: {
|
|
295
|
-
isEdit: boolean;
|
|
296
|
-
run: (d: any, req: any) => any;
|
|
297
|
-
};
|
|
298
|
-
format: {
|
|
299
|
-
isEdit: boolean;
|
|
300
|
-
configFields: {
|
|
301
|
-
name: string;
|
|
302
|
-
label: string;
|
|
303
|
-
type: string;
|
|
304
|
-
sublabel: string;
|
|
305
|
-
}[];
|
|
306
|
-
run: (d: any, req: any, options: any) => string;
|
|
307
|
-
};
|
|
308
|
-
relative: {
|
|
309
|
-
isEdit: boolean;
|
|
310
|
-
run: (d: any, req: any) => string;
|
|
311
|
-
};
|
|
312
|
-
yearsAgo: {
|
|
313
|
-
isEdit: boolean;
|
|
314
|
-
run: (d: any, req: any) => string;
|
|
281
|
+
run: (s: any) => any;
|
|
315
282
|
};
|
|
316
283
|
edit: {
|
|
317
284
|
isEdit: boolean;
|
|
318
285
|
blockDisplay: boolean;
|
|
319
286
|
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
320
287
|
};
|
|
321
|
-
editDay: {
|
|
322
|
-
isEdit: boolean;
|
|
323
|
-
blockDisplay: boolean;
|
|
324
|
-
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
325
|
-
};
|
|
326
|
-
};
|
|
327
|
-
presets: {
|
|
328
|
-
Now: () => Date;
|
|
329
288
|
};
|
|
330
|
-
|
|
331
|
-
|
|
289
|
+
attributes: object[];
|
|
290
|
+
read: (v: object) => object;
|
|
291
|
+
validate: () => boolean;
|
|
332
292
|
} | {
|
|
333
293
|
name: string;
|
|
334
294
|
sql_name: string;
|
|
@@ -402,155 +362,118 @@ export const types: ({
|
|
|
402
362
|
name: string;
|
|
403
363
|
sql_name: string;
|
|
404
364
|
contract: () => Function;
|
|
365
|
+
attributes: object[];
|
|
405
366
|
fieldviews: {
|
|
406
367
|
show: {
|
|
407
368
|
isEdit: boolean;
|
|
408
|
-
run: (
|
|
369
|
+
run: (d: any, req: any) => any;
|
|
370
|
+
};
|
|
371
|
+
showDay: {
|
|
372
|
+
isEdit: boolean;
|
|
373
|
+
run: (d: any, req: any) => any;
|
|
374
|
+
};
|
|
375
|
+
format: {
|
|
376
|
+
isEdit: boolean;
|
|
377
|
+
configFields: {
|
|
378
|
+
name: string;
|
|
379
|
+
label: string;
|
|
380
|
+
type: string;
|
|
381
|
+
sublabel: string;
|
|
382
|
+
}[];
|
|
383
|
+
run: (d: any, req: any, options: any) => string;
|
|
384
|
+
};
|
|
385
|
+
relative: {
|
|
386
|
+
isEdit: boolean;
|
|
387
|
+
run: (d: any, req: any) => string;
|
|
388
|
+
};
|
|
389
|
+
yearsAgo: {
|
|
390
|
+
isEdit: boolean;
|
|
391
|
+
run: (d: any, req: any) => string;
|
|
409
392
|
};
|
|
410
393
|
edit: {
|
|
411
394
|
isEdit: boolean;
|
|
412
395
|
blockDisplay: boolean;
|
|
413
396
|
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
414
397
|
};
|
|
398
|
+
editDay: {
|
|
399
|
+
isEdit: boolean;
|
|
400
|
+
blockDisplay: boolean;
|
|
401
|
+
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
402
|
+
};
|
|
403
|
+
};
|
|
404
|
+
presets: {
|
|
405
|
+
Now: () => Date;
|
|
406
|
+
};
|
|
407
|
+
read: (v: object, attrs: object) => object;
|
|
408
|
+
validate: ({}: object) => boolean;
|
|
409
|
+
} | {
|
|
410
|
+
name: string;
|
|
411
|
+
sql_name: string;
|
|
412
|
+
contract: () => Function;
|
|
413
|
+
fieldviews: {
|
|
414
|
+
show: {
|
|
415
|
+
isEdit: boolean;
|
|
416
|
+
run: (v: any) => any;
|
|
417
|
+
};
|
|
418
|
+
checkboxes: {
|
|
419
|
+
isEdit: boolean;
|
|
420
|
+
run: (v: any) => any;
|
|
421
|
+
};
|
|
422
|
+
TrueFalse: {
|
|
423
|
+
isEdit: boolean;
|
|
424
|
+
run: (v: any) => "" | "True" | "False";
|
|
425
|
+
};
|
|
426
|
+
edit: {
|
|
427
|
+
isEdit: boolean;
|
|
428
|
+
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
429
|
+
};
|
|
430
|
+
tristate: {
|
|
431
|
+
isEdit: boolean;
|
|
432
|
+
run: (nm: any, v: any, attrs: any, cls: any, required: any, field: any) => any;
|
|
433
|
+
};
|
|
415
434
|
};
|
|
416
435
|
attributes: object[];
|
|
417
|
-
|
|
436
|
+
readFromFormRecord: (rec: any, name: string) => boolean | null;
|
|
437
|
+
read: (v: object) => boolean | null;
|
|
438
|
+
readFromDB: (v: object) => object;
|
|
439
|
+
listAs: (v: object) => object;
|
|
418
440
|
validate: () => boolean;
|
|
419
441
|
})[];
|
|
420
442
|
export const viewtemplates: ({
|
|
421
443
|
name: string;
|
|
422
444
|
description: string;
|
|
423
445
|
get_state_fields: () => object[];
|
|
424
|
-
configuration_workflow: (
|
|
425
|
-
run: (table_id:
|
|
426
|
-
columns: object[];
|
|
427
|
-
layout: object;
|
|
428
|
-
page_title?: string | undefined;
|
|
429
|
-
page_title_formula: boolean;
|
|
430
|
-
}, state: object, extra: object, { showQuery }: {
|
|
431
|
-
showQuery: any;
|
|
432
|
-
}) => Promise<string>;
|
|
433
|
-
runMany: (table_id: number, viewname: string, { columns, layout }: {
|
|
434
|
-
columns: object[];
|
|
435
|
-
layout: object;
|
|
436
|
-
}, state: object, extra: object, { runManyQuery }: {
|
|
437
|
-
runManyQuery: any;
|
|
438
|
-
}) => Promise<object[]>;
|
|
439
|
-
renderRows: (table: object, viewname: string, { columns, layout }: {
|
|
446
|
+
configuration_workflow: () => import("../models/workflow");
|
|
447
|
+
run: (table_id: number, viewname: string, { columns, layout }: {
|
|
440
448
|
columns: object[];
|
|
441
449
|
layout: object;
|
|
442
|
-
},
|
|
443
|
-
|
|
450
|
+
}, state: object, extra: object, { distinctValuesQuery }: {
|
|
451
|
+
distinctValuesQuery: any;
|
|
452
|
+
}) => Promise<Layout>;
|
|
453
|
+
initial_config: () => Promise<object>;
|
|
444
454
|
display_state_form: boolean;
|
|
445
|
-
routes: {
|
|
446
|
-
run_action: (table_id: number, viewname: any, { columns, layout }: {
|
|
447
|
-
columns: object[];
|
|
448
|
-
layout: any;
|
|
449
|
-
}, body: any, { req, res }: {
|
|
450
|
-
req: object;
|
|
451
|
-
res: any;
|
|
452
|
-
}, { actionQuery }: {
|
|
453
|
-
actionQuery: any;
|
|
454
|
-
}) => Promise<object>;
|
|
455
|
-
};
|
|
456
455
|
getStringsForI18n({ layout }: {
|
|
457
|
-
layout:
|
|
456
|
+
layout: any;
|
|
458
457
|
}): string[];
|
|
459
|
-
|
|
460
|
-
query: any;
|
|
461
|
-
table_id: any;
|
|
462
|
-
}, { authorizeGetQuery }: {
|
|
463
|
-
authorizeGetQuery: any;
|
|
464
|
-
}) => Promise<any>;
|
|
465
|
-
queries: ({ table_id, viewname, configuration: { columns, layout }, req, }: {
|
|
458
|
+
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
466
459
|
table_id: any;
|
|
467
460
|
viewname: any;
|
|
468
461
|
configuration: {
|
|
469
462
|
columns: any;
|
|
470
|
-
|
|
463
|
+
default_state: any;
|
|
471
464
|
};
|
|
472
465
|
req: any;
|
|
473
466
|
}) => {
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
} | {
|
|
478
|
-
rows: import("@saltcorn/db-common/internal").Row[];
|
|
479
|
-
message: null;
|
|
480
|
-
}>;
|
|
481
|
-
runManyQuery(state: any, { where, limit, offset, orderBy, orderDesc }: {
|
|
482
|
-
where: any;
|
|
483
|
-
limit: any;
|
|
484
|
-
offset: any;
|
|
485
|
-
orderBy: any;
|
|
486
|
-
orderDesc: any;
|
|
487
|
-
}): Promise<import("@saltcorn/db-common/internal").Row[]>;
|
|
488
|
-
actionQuery(): Promise<{
|
|
489
|
-
json: any;
|
|
467
|
+
distinctValuesQuery(): Promise<{
|
|
468
|
+
distinct_values: {};
|
|
469
|
+
role: any;
|
|
490
470
|
}>;
|
|
491
|
-
authorizeGetQuery(query: any, table_id: any): Promise<boolean>;
|
|
492
471
|
};
|
|
493
|
-
configCheck: (view: any) => Promise<string[]>;
|
|
494
472
|
} | {
|
|
495
473
|
name: string;
|
|
496
474
|
description: string;
|
|
497
475
|
configuration_workflow: (req: object) => import("../models/workflow");
|
|
498
|
-
run: (table_id:
|
|
499
|
-
columns: object[];
|
|
500
|
-
view_to_create?: string | undefined;
|
|
501
|
-
create_view_display: string;
|
|
502
|
-
create_view_label?: string | undefined;
|
|
503
|
-
default_state?: object | undefined;
|
|
504
|
-
create_view_location?: string | undefined;
|
|
505
|
-
}, stateWithId?: object | undefined, extraOpts: object, { listQuery }: {
|
|
506
|
-
listQuery: any;
|
|
507
|
-
}) => Promise<any>;
|
|
508
|
-
view_quantity: string;
|
|
509
|
-
get_state_fields: (table_id: string, viewname: any, { columns }: {
|
|
510
|
-
columns: object[];
|
|
511
|
-
}) => Function;
|
|
512
|
-
initial_config: Function;
|
|
513
|
-
on_delete: (table_id: any, viewname: string, { default_state }: {
|
|
514
|
-
default_state: any;
|
|
515
|
-
}) => Promise<void>;
|
|
516
|
-
routes: {
|
|
517
|
-
run_action: (table_id: number, viewname: any, { columns, layout }: {
|
|
518
|
-
columns: object[];
|
|
519
|
-
layout: any;
|
|
520
|
-
}, body: object, { req, res }: {
|
|
521
|
-
req: object;
|
|
522
|
-
res: any;
|
|
523
|
-
}, { getRowQuery }: {
|
|
524
|
-
getRowQuery: any;
|
|
525
|
-
}) => Promise<object>;
|
|
526
|
-
};
|
|
527
|
-
display_state_form: (opts: object) => boolean;
|
|
528
|
-
default_state_form: ({ default_state }: object) => boolean;
|
|
529
|
-
getStringsForI18n({ columns, create_view_label }: {
|
|
530
|
-
columns: any;
|
|
531
|
-
create_view_label: any;
|
|
532
|
-
}): string[];
|
|
533
|
-
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
534
|
-
table_id: any;
|
|
535
|
-
viewname: any;
|
|
536
|
-
configuration: {
|
|
537
|
-
columns: any;
|
|
538
|
-
default_state: any;
|
|
539
|
-
};
|
|
540
|
-
req: any;
|
|
541
|
-
}) => {
|
|
542
|
-
listQuery(state: any): Promise<{
|
|
543
|
-
rows: import("@saltcorn/db-common/internal").Row[];
|
|
544
|
-
rowCount: number;
|
|
545
|
-
}>;
|
|
546
|
-
getRowQuery(id: any): Promise<import("@saltcorn/db-common/internal").Row | null>;
|
|
547
|
-
};
|
|
548
|
-
configCheck: (view: any) => Promise<string[]>;
|
|
549
|
-
} | {
|
|
550
|
-
name: string;
|
|
551
|
-
description: string;
|
|
552
|
-
configuration_workflow: (req: object) => import("../models/workflow");
|
|
553
|
-
run: (table_id: number, viewname: string, {}: {
|
|
476
|
+
run: (table_id: number, viewname: string, {}: {
|
|
554
477
|
columns: any;
|
|
555
478
|
layout: any;
|
|
556
479
|
}, state: string, { res, req }: {
|
|
@@ -654,105 +577,6 @@ export const viewtemplates: ({
|
|
|
654
577
|
}) => Promise<object>;
|
|
655
578
|
};
|
|
656
579
|
configCheck: (view: any) => Promise<string[]>;
|
|
657
|
-
} | {
|
|
658
|
-
name: string;
|
|
659
|
-
description: string;
|
|
660
|
-
configuration_workflow: (req: object) => import("../models/workflow");
|
|
661
|
-
run: (table_id: string, viewname: string, { list_view, show_view, list_width, subtables }: {
|
|
662
|
-
list_view: string;
|
|
663
|
-
show_view: string;
|
|
664
|
-
subtables: object;
|
|
665
|
-
}, state: any, extraArgs: any, { getRowQuery }: {
|
|
666
|
-
getRowQuery: any;
|
|
667
|
-
}) => Promise<div>;
|
|
668
|
-
get_state_fields: (table_id: any, viewname: any, { list_view, show_view }: {
|
|
669
|
-
list_view: string;
|
|
670
|
-
show_view: any;
|
|
671
|
-
}) => Promise<object[]>;
|
|
672
|
-
display_state_form: ({ list_view, _omit_state_form }: {
|
|
673
|
-
list_view: string;
|
|
674
|
-
_omit_state_form: boolean;
|
|
675
|
-
}) => boolean;
|
|
676
|
-
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
677
|
-
table_id: any;
|
|
678
|
-
viewname: any;
|
|
679
|
-
configuration: {
|
|
680
|
-
columns: any;
|
|
681
|
-
default_state: any;
|
|
682
|
-
};
|
|
683
|
-
req: any;
|
|
684
|
-
}) => {
|
|
685
|
-
getRowQuery(uniques: any): Promise<import("@saltcorn/db-common/internal").Row | null>;
|
|
686
|
-
};
|
|
687
|
-
} | {
|
|
688
|
-
name: string;
|
|
689
|
-
description: string;
|
|
690
|
-
configuration_workflow: (req: object) => import("../models/workflow");
|
|
691
|
-
run: (table_id: number, viewname: string, { show_view, order_field, descending, view_to_create, create_view_display, in_card, masonry_columns, rows_per_page, hide_pagination, create_view_label, create_view_location, always_create_view, include_fml, ...cols }: {
|
|
692
|
-
show_view: string;
|
|
693
|
-
order_field: name;
|
|
694
|
-
descending: boolean;
|
|
695
|
-
view_to_create?: string | undefined;
|
|
696
|
-
create_view_display: string;
|
|
697
|
-
in_card: boolean;
|
|
698
|
-
masonry_columns: string;
|
|
699
|
-
rows_per_page?: number | undefined;
|
|
700
|
-
hide_pagination: boolean;
|
|
701
|
-
create_view_label?: string | undefined;
|
|
702
|
-
create_view_location?: string | undefined;
|
|
703
|
-
always_create_view: boolean;
|
|
704
|
-
cols: any;
|
|
705
|
-
}, state: object, extraArgs: any, { countRowsQuery }: {
|
|
706
|
-
countRowsQuery: any;
|
|
707
|
-
}) => Promise<div>;
|
|
708
|
-
get_state_fields: (table_id: number, viewname: any, { show_view }: {
|
|
709
|
-
show_view: any;
|
|
710
|
-
}) => Promise<import("../models/field")>;
|
|
711
|
-
display_state_form: boolean;
|
|
712
|
-
getStringsForI18n({ create_view_label }: {
|
|
713
|
-
create_view_label: any;
|
|
714
|
-
}): string[] | Object[];
|
|
715
|
-
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
716
|
-
table_id: any;
|
|
717
|
-
viewname: any;
|
|
718
|
-
configuration: {
|
|
719
|
-
columns: any;
|
|
720
|
-
default_state: any;
|
|
721
|
-
};
|
|
722
|
-
req: any;
|
|
723
|
-
}) => {
|
|
724
|
-
countRowsQuery(state: any): Promise<number>;
|
|
725
|
-
};
|
|
726
|
-
} | {
|
|
727
|
-
name: string;
|
|
728
|
-
description: string;
|
|
729
|
-
get_state_fields: () => object[];
|
|
730
|
-
configuration_workflow: () => import("../models/workflow");
|
|
731
|
-
run: (table_id: number, viewname: string, { columns, layout }: {
|
|
732
|
-
columns: object[];
|
|
733
|
-
layout: object;
|
|
734
|
-
}, state: object, extra: object, { distinctValuesQuery }: {
|
|
735
|
-
distinctValuesQuery: any;
|
|
736
|
-
}) => Promise<Layout>;
|
|
737
|
-
initial_config: () => Promise<object>;
|
|
738
|
-
display_state_form: boolean;
|
|
739
|
-
getStringsForI18n({ layout }: {
|
|
740
|
-
layout: any;
|
|
741
|
-
}): string[];
|
|
742
|
-
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
743
|
-
table_id: any;
|
|
744
|
-
viewname: any;
|
|
745
|
-
configuration: {
|
|
746
|
-
columns: any;
|
|
747
|
-
default_state: any;
|
|
748
|
-
};
|
|
749
|
-
req: any;
|
|
750
|
-
}) => {
|
|
751
|
-
distinctValuesQuery(): Promise<{
|
|
752
|
-
distinct_values: {};
|
|
753
|
-
role: any;
|
|
754
|
-
}>;
|
|
755
|
-
};
|
|
756
580
|
} | {
|
|
757
581
|
name: string;
|
|
758
582
|
description: string;
|
|
@@ -852,6 +676,206 @@ export const viewtemplates: ({
|
|
|
852
676
|
fetchOlderMsgQuery(participant_field: any, body: any): Promise<import("@saltcorn/db-common/internal").Row | null>;
|
|
853
677
|
optionsQuery(reftable_name: any, type: any, attributes: any, where: any): Promise<any>;
|
|
854
678
|
};
|
|
679
|
+
} | {
|
|
680
|
+
name: string;
|
|
681
|
+
description: string;
|
|
682
|
+
configuration_workflow: (req: object) => import("../models/workflow");
|
|
683
|
+
run: (table_id: number, viewname: string, { show_view, order_field, descending, view_to_create, create_view_display, in_card, masonry_columns, rows_per_page, hide_pagination, create_view_label, create_view_location, always_create_view, include_fml, ...cols }: {
|
|
684
|
+
show_view: string;
|
|
685
|
+
order_field: name;
|
|
686
|
+
descending: boolean;
|
|
687
|
+
view_to_create?: string | undefined;
|
|
688
|
+
create_view_display: string;
|
|
689
|
+
in_card: boolean;
|
|
690
|
+
masonry_columns: string;
|
|
691
|
+
rows_per_page?: number | undefined;
|
|
692
|
+
hide_pagination: boolean;
|
|
693
|
+
create_view_label?: string | undefined;
|
|
694
|
+
create_view_location?: string | undefined;
|
|
695
|
+
always_create_view: boolean;
|
|
696
|
+
cols: any;
|
|
697
|
+
}, state: object, extraArgs: any, { countRowsQuery }: {
|
|
698
|
+
countRowsQuery: any;
|
|
699
|
+
}) => Promise<div>;
|
|
700
|
+
get_state_fields: (table_id: number, viewname: any, { show_view }: {
|
|
701
|
+
show_view: any;
|
|
702
|
+
}) => Promise<import("../models/field")>;
|
|
703
|
+
display_state_form: boolean;
|
|
704
|
+
getStringsForI18n({ create_view_label }: {
|
|
705
|
+
create_view_label: any;
|
|
706
|
+
}): string[] | Object[];
|
|
707
|
+
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
708
|
+
table_id: any;
|
|
709
|
+
viewname: any;
|
|
710
|
+
configuration: {
|
|
711
|
+
columns: any;
|
|
712
|
+
default_state: any;
|
|
713
|
+
};
|
|
714
|
+
req: any;
|
|
715
|
+
}) => {
|
|
716
|
+
countRowsQuery(state: any): Promise<number>;
|
|
717
|
+
};
|
|
718
|
+
} | {
|
|
719
|
+
name: string;
|
|
720
|
+
description: string;
|
|
721
|
+
get_state_fields: () => object[];
|
|
722
|
+
configuration_workflow: (req: object) => import("../models/workflow");
|
|
723
|
+
run: (table_id: string, viewname: string, { columns, layout, page_title, page_title_formula }: {
|
|
724
|
+
columns: object[];
|
|
725
|
+
layout: object;
|
|
726
|
+
page_title?: string | undefined;
|
|
727
|
+
page_title_formula: boolean;
|
|
728
|
+
}, state: object, extra: object, { showQuery }: {
|
|
729
|
+
showQuery: any;
|
|
730
|
+
}) => Promise<string>;
|
|
731
|
+
runMany: (table_id: number, viewname: string, { columns, layout }: {
|
|
732
|
+
columns: object[];
|
|
733
|
+
layout: object;
|
|
734
|
+
}, state: object, extra: object, { runManyQuery }: {
|
|
735
|
+
runManyQuery: any;
|
|
736
|
+
}) => Promise<object[]>;
|
|
737
|
+
renderRows: (table: object, viewname: string, { columns, layout }: {
|
|
738
|
+
columns: object[];
|
|
739
|
+
layout: object;
|
|
740
|
+
}, extra: object, rows: object[]) => Promise<string>;
|
|
741
|
+
initial_config: Function;
|
|
742
|
+
display_state_form: boolean;
|
|
743
|
+
routes: {
|
|
744
|
+
run_action: (table_id: number, viewname: any, { columns, layout }: {
|
|
745
|
+
columns: object[];
|
|
746
|
+
layout: any;
|
|
747
|
+
}, body: any, { req, res }: {
|
|
748
|
+
req: object;
|
|
749
|
+
res: any;
|
|
750
|
+
}, { actionQuery }: {
|
|
751
|
+
actionQuery: any;
|
|
752
|
+
}) => Promise<object>;
|
|
753
|
+
};
|
|
754
|
+
getStringsForI18n({ layout }: {
|
|
755
|
+
layout: object;
|
|
756
|
+
}): string[];
|
|
757
|
+
authorise_get: ({ query, table_id }: {
|
|
758
|
+
query: any;
|
|
759
|
+
table_id: any;
|
|
760
|
+
}, { authorizeGetQuery }: {
|
|
761
|
+
authorizeGetQuery: any;
|
|
762
|
+
}) => Promise<any>;
|
|
763
|
+
queries: ({ table_id, exttable_name, viewname, configuration: { columns, layout }, req, }: {
|
|
764
|
+
table_id: any;
|
|
765
|
+
exttable_name: any;
|
|
766
|
+
viewname: any;
|
|
767
|
+
configuration: {
|
|
768
|
+
columns: any;
|
|
769
|
+
layout: any;
|
|
770
|
+
};
|
|
771
|
+
req: any;
|
|
772
|
+
}) => {
|
|
773
|
+
showQuery(state: any, fields: any): Promise<{
|
|
774
|
+
rows: null;
|
|
775
|
+
message: string;
|
|
776
|
+
} | {
|
|
777
|
+
rows: import("@saltcorn/db-common/internal").Row[];
|
|
778
|
+
message: null;
|
|
779
|
+
}>;
|
|
780
|
+
runManyQuery(state: any, { where, limit, offset, orderBy, orderDesc }: {
|
|
781
|
+
where: any;
|
|
782
|
+
limit: any;
|
|
783
|
+
offset: any;
|
|
784
|
+
orderBy: any;
|
|
785
|
+
orderDesc: any;
|
|
786
|
+
}): Promise<import("@saltcorn/db-common/internal").Row[]>;
|
|
787
|
+
actionQuery(): Promise<{
|
|
788
|
+
json: any;
|
|
789
|
+
}>;
|
|
790
|
+
authorizeGetQuery(query: any, table_id: any): Promise<boolean>;
|
|
791
|
+
};
|
|
792
|
+
configCheck: (view: any) => Promise<string[]>;
|
|
793
|
+
} | {
|
|
794
|
+
name: string;
|
|
795
|
+
description: string;
|
|
796
|
+
configuration_workflow: (req: object) => import("../models/workflow");
|
|
797
|
+
run: (table_id: string | number, viewname: string, { columns, view_to_create, create_view_display, create_view_label, default_state, create_view_location, }: {
|
|
798
|
+
columns: object[];
|
|
799
|
+
view_to_create?: string | undefined;
|
|
800
|
+
create_view_display: string;
|
|
801
|
+
create_view_label?: string | undefined;
|
|
802
|
+
default_state?: object | undefined;
|
|
803
|
+
create_view_location?: string | undefined;
|
|
804
|
+
}, stateWithId?: object | undefined, extraOpts: object, { listQuery }: {
|
|
805
|
+
listQuery: any;
|
|
806
|
+
}) => Promise<any>;
|
|
807
|
+
view_quantity: string;
|
|
808
|
+
get_state_fields: (table_id: string, viewname: any, { columns }: {
|
|
809
|
+
columns: object[];
|
|
810
|
+
}) => Function;
|
|
811
|
+
initial_config: Function;
|
|
812
|
+
on_delete: (table_id: any, viewname: string, { default_state }: {
|
|
813
|
+
default_state: any;
|
|
814
|
+
}) => Promise<void>;
|
|
815
|
+
routes: {
|
|
816
|
+
run_action: (table_id: number, viewname: any, { columns, layout }: {
|
|
817
|
+
columns: object[];
|
|
818
|
+
layout: any;
|
|
819
|
+
}, body: object, { req, res }: {
|
|
820
|
+
req: object;
|
|
821
|
+
res: any;
|
|
822
|
+
}, { getRowQuery }: {
|
|
823
|
+
getRowQuery: any;
|
|
824
|
+
}) => Promise<object>;
|
|
825
|
+
};
|
|
826
|
+
display_state_form: (opts: object) => boolean;
|
|
827
|
+
default_state_form: ({ default_state }: object) => boolean;
|
|
828
|
+
getStringsForI18n({ columns, create_view_label }: {
|
|
829
|
+
columns: any;
|
|
830
|
+
create_view_label: any;
|
|
831
|
+
}): string[];
|
|
832
|
+
queries: ({ table_id, exttable_name, viewname, configuration: { columns, default_state }, req, }: {
|
|
833
|
+
table_id: any;
|
|
834
|
+
exttable_name: any;
|
|
835
|
+
viewname: any;
|
|
836
|
+
configuration: {
|
|
837
|
+
columns: any;
|
|
838
|
+
default_state: any;
|
|
839
|
+
};
|
|
840
|
+
req: any;
|
|
841
|
+
}) => {
|
|
842
|
+
listQuery(state: any): Promise<{
|
|
843
|
+
rows: import("@saltcorn/db-common/internal").Row[];
|
|
844
|
+
rowCount: number;
|
|
845
|
+
}>;
|
|
846
|
+
getRowQuery(id: any): Promise<import("@saltcorn/db-common/internal").Row | null>;
|
|
847
|
+
};
|
|
848
|
+
configCheck: (view: any) => Promise<string[]>;
|
|
849
|
+
} | {
|
|
850
|
+
name: string;
|
|
851
|
+
description: string;
|
|
852
|
+
configuration_workflow: (req: object) => import("../models/workflow");
|
|
853
|
+
run: (table_id: string, viewname: string, { list_view, show_view, list_width, subtables }: {
|
|
854
|
+
list_view: string;
|
|
855
|
+
show_view: string;
|
|
856
|
+
subtables: object;
|
|
857
|
+
}, state: any, extraArgs: any, { getRowQuery }: {
|
|
858
|
+
getRowQuery: any;
|
|
859
|
+
}) => Promise<div>;
|
|
860
|
+
get_state_fields: (table_id: any, viewname: any, { list_view, show_view }: {
|
|
861
|
+
list_view: string;
|
|
862
|
+
show_view: any;
|
|
863
|
+
}) => Promise<object[]>;
|
|
864
|
+
display_state_form: ({ list_view, _omit_state_form }: {
|
|
865
|
+
list_view: string;
|
|
866
|
+
_omit_state_form: boolean;
|
|
867
|
+
}) => boolean;
|
|
868
|
+
queries: ({ table_id, viewname, configuration: { columns, default_state }, req, }: {
|
|
869
|
+
table_id: any;
|
|
870
|
+
viewname: any;
|
|
871
|
+
configuration: {
|
|
872
|
+
columns: any;
|
|
873
|
+
default_state: any;
|
|
874
|
+
};
|
|
875
|
+
req: any;
|
|
876
|
+
}) => {
|
|
877
|
+
getRowQuery(uniques: any): Promise<import("@saltcorn/db-common/internal").Row | null>;
|
|
878
|
+
};
|
|
855
879
|
})[];
|
|
856
880
|
import fileviews = require("./fileviews");
|
|
857
881
|
import actions = require("./actions");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../base-plugin/index.js"],"names":[],"mappings":"AAuCA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../base-plugin/index.js"],"names":[],"mappings":"AAuCA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAAsD;AACtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAA2E;;;;4CAG9D,MAAM;yCAYN,MAAM"}
|