@acorex/modules 19.2.15 → 19.2.17-next.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. package/common/README.md +3 -0
  2. package/common/index.d.ts +6 -0
  3. package/common/lib/common.module.d.ts +6 -0
  4. package/common/lib/const.d.ts +25 -0
  5. package/common/lib/entities/dashboard/dashboard.entity.d.ts +3 -0
  6. package/common/lib/entities/dashboard/dashboard.service.d.ts +10 -0
  7. package/common/lib/entities/dashboard/dashboard.types.d.ts +8 -0
  8. package/common/lib/entities/dashboard/index.d.ts +3 -0
  9. package/common/lib/entities/dashboard-widget-data/dashboard-widget-data.entity.d.ts +3 -0
  10. package/common/lib/entities/dashboard-widget-data/dashboard-widget-data.service.d.ts +10 -0
  11. package/common/lib/entities/dashboard-widget-data/dashboard-widget-data.types.d.ts +9 -0
  12. package/common/lib/entities/dashboard-widget-data/index.d.ts +3 -0
  13. package/common/lib/entities/index.d.ts +2 -0
  14. package/common/lib/entity.provider.d.ts +10 -0
  15. package/common/lib/features/home/dashboard-home.d.ts +5 -0
  16. package/common/lib/features/home/index.d.ts +1 -0
  17. package/common/lib/menu.provider.d.ts +5 -0
  18. package/common/lib/permission.provider.d.ts +4 -0
  19. package/common/lib/search-command.provider.d.ts +4 -0
  20. package/common/lib/setting.provider.d.ts +4 -0
  21. package/document-management/lib/entities/document/document.service.d.ts +7 -0
  22. package/document-management/lib/entities/folder/folder.service.d.ts +7 -0
  23. package/document-management/lib/features/document-explorer/components/rename-node-dialog/rename-node-dialog.component.d.ts +14 -0
  24. package/document-management/lib/features/document-explorer/document-explorer.component.d.ts +12 -9
  25. package/document-management/lib/features/document-explorer/document-explorer.viewmodel.d.ts +2 -2
  26. package/document-management/lib/features/drive/drive.component.d.ts +3 -2
  27. package/document-management/lib/features/shared/document-manager.service.d.ts +80 -1
  28. package/document-management/lib/features/shared/document-manager.types.d.ts +1 -1
  29. package/document-management/lib/features/widgets/document-attachment/document-attachment-widget-column.component.d.ts +6 -0
  30. package/document-management/lib/features/widgets/document-attachment/document-attachment-widget-edit.component.d.ts +6 -0
  31. package/document-management/lib/features/widgets/document-attachment/document-attachment-widget-filter.component.d.ts +6 -0
  32. package/document-management/lib/features/widgets/document-attachment/document-attachment-widget-print.component.d.ts +6 -0
  33. package/document-management/lib/features/widgets/document-attachment/document-attachment-widget-view.component.d.ts +6 -0
  34. package/document-management/lib/features/widgets/document-attachment/document-attachment-widget.config.d.ts +7 -0
  35. package/document-management/lib/features/widgets/document-attachment/index.d.ts +6 -0
  36. package/document-management/lib/features/widgets/index.d.ts +1 -0
  37. package/fesm2022/{acorex-modules-auth-acorex-modules-auth-CZ_nTBkL.mjs → acorex-modules-auth-acorex-modules-auth-DTje3YIv.mjs} +8 -8
  38. package/fesm2022/{acorex-modules-auth-acorex-modules-auth-CZ_nTBkL.mjs.map → acorex-modules-auth-acorex-modules-auth-DTje3YIv.mjs.map} +1 -1
  39. package/fesm2022/{acorex-modules-auth-app-chooser.component-CGSygSjS.mjs → acorex-modules-auth-app-chooser.component-CZxX5-T_.mjs} +2 -2
  40. package/fesm2022/{acorex-modules-auth-app-chooser.component-CGSygSjS.mjs.map → acorex-modules-auth-app-chooser.component-CZxX5-T_.mjs.map} +1 -1
  41. package/fesm2022/{acorex-modules-auth-login.module-B1sF3B_O.mjs → acorex-modules-auth-login.module-B9P2XpfQ.mjs} +4 -4
  42. package/fesm2022/{acorex-modules-auth-login.module-B1sF3B_O.mjs.map → acorex-modules-auth-login.module-B9P2XpfQ.mjs.map} +1 -1
  43. package/fesm2022/{acorex-modules-auth-master.layout-CK4nyS8D.mjs → acorex-modules-auth-master.layout-BYC0FYq1.mjs} +2 -2
  44. package/fesm2022/{acorex-modules-auth-master.layout-CK4nyS8D.mjs.map → acorex-modules-auth-master.layout-BYC0FYq1.mjs.map} +1 -1
  45. package/fesm2022/{acorex-modules-auth-password.component-DC_zi8bV.mjs → acorex-modules-auth-password.component-C7Yp-ioT.mjs} +2 -2
  46. package/fesm2022/{acorex-modules-auth-password.component-DC_zi8bV.mjs.map → acorex-modules-auth-password.component-C7Yp-ioT.mjs.map} +1 -1
  47. package/fesm2022/{acorex-modules-auth-password.component-DqvmIMDR.mjs → acorex-modules-auth-password.component-DzrYH4yM.mjs} +3 -3
  48. package/fesm2022/acorex-modules-auth-password.component-DzrYH4yM.mjs.map +1 -0
  49. package/fesm2022/{acorex-modules-auth-routes-DwHgPrDP.mjs → acorex-modules-auth-routes-Bu-xB4O6.mjs} +2 -2
  50. package/fesm2022/{acorex-modules-auth-routes-DwHgPrDP.mjs.map → acorex-modules-auth-routes-Bu-xB4O6.mjs.map} +1 -1
  51. package/fesm2022/{acorex-modules-auth-two-factor.module-BatKQRdJ.mjs → acorex-modules-auth-two-factor.module-YRh6_YcG.mjs} +2 -2
  52. package/fesm2022/{acorex-modules-auth-two-factor.module-BatKQRdJ.mjs.map → acorex-modules-auth-two-factor.module-YRh6_YcG.mjs.map} +1 -1
  53. package/fesm2022/acorex-modules-auth.mjs +1 -1
  54. package/fesm2022/acorex-modules-common-index-zaFxpV8u.mjs +14 -0
  55. package/fesm2022/acorex-modules-common-index-zaFxpV8u.mjs.map +1 -0
  56. package/fesm2022/acorex-modules-common.mjs +1095 -0
  57. package/fesm2022/acorex-modules-common.mjs.map +1 -0
  58. package/fesm2022/acorex-modules-document-management-acorex-modules-document-management-C9ZCejjs.mjs +4092 -0
  59. package/fesm2022/acorex-modules-document-management-acorex-modules-document-management-C9ZCejjs.mjs.map +1 -0
  60. package/fesm2022/acorex-modules-document-management-create-folder-dialog.component-BnRaCq_Q.mjs +92 -0
  61. package/fesm2022/acorex-modules-document-management-create-folder-dialog.component-BnRaCq_Q.mjs.map +1 -0
  62. package/fesm2022/acorex-modules-document-management-drive.component-Sz198sA6.mjs +165 -0
  63. package/fesm2022/acorex-modules-document-management-drive.component-Sz198sA6.mjs.map +1 -0
  64. package/fesm2022/acorex-modules-document-management-index--I8MGeDs.mjs +2 -0
  65. package/fesm2022/acorex-modules-document-management-index--I8MGeDs.mjs.map +1 -0
  66. package/fesm2022/acorex-modules-document-management-rename-node-dialog.component-EBf1XqU8.mjs +101 -0
  67. package/fesm2022/acorex-modules-document-management-rename-node-dialog.component-EBf1XqU8.mjs.map +1 -0
  68. package/fesm2022/acorex-modules-document-management.mjs +1 -3093
  69. package/fesm2022/acorex-modules-document-management.mjs.map +1 -1
  70. package/package.json +5 -1
  71. package/document-management/lib/features/drive/index.d.ts +0 -3
  72. package/fesm2022/acorex-modules-auth-password.component-DqvmIMDR.mjs.map +0 -1
  73. package/fesm2022/acorex-modules-document-management-drive.component-bjnFFaLS.mjs +0 -951
  74. package/fesm2022/acorex-modules-document-management-drive.component-bjnFFaLS.mjs.map +0 -1
@@ -0,0 +1,1095 @@
1
+ import { AXP_PERMISSION_PROVIDER } from '@acorex/platform/auth';
2
+ import { AXPSearchCommandProvider, AXPEntityQueryType, AXPEntityCommandScope, createAllQueryView, AXP_MENU_PROVIDER, AXP_SETTING_DEFINITION_PROVIDER, AXP_SEARCH_PROVIDER } from '@acorex/platform/common';
3
+ import { AXPEntityService, AXMEntityCrudServiceImpl, AXP_ENTITY_CONFIG_TOKEN, AXP_ENTITY_DEFINITION_LOADER } from '@acorex/platform/layout/entity';
4
+ import * as i0 from '@angular/core';
5
+ import { inject, Injector, Injectable, NgModule } from '@angular/core';
6
+ import { ROUTES } from '@angular/router';
7
+ import { AXPWidgetsCatalog } from '@acorex/platform/layout/builder';
8
+
9
+ const config = {
10
+ i18n: 'common',
11
+ };
12
+ const RootConfig = {
13
+ config,
14
+ module: {
15
+ module: 'common',
16
+ name: 'Common',
17
+ title: `t('module-name', {scope:"${config.i18n}"})`,
18
+ icon: 'fa-light fa-file-invoice',
19
+ },
20
+ entities: {
21
+ dashboardWidgetData: {
22
+ name: 'DashboardWidgetData',
23
+ title: `t("dashboardWidgetData", { scope: "${config.i18n}" })`,
24
+ titlePlural: `t("dashboardWidgetDataPlural", { scope: "${config.i18n}" })`,
25
+ icon: 'fa-light fa-default',
26
+ },
27
+ dashboard: {
28
+ name: 'Dashboard',
29
+ title: `t("dashboard", { scope: "${config.i18n}" })`,
30
+ titlePlural: `t("dashboardPlural", { scope: "${config.i18n}" })`,
31
+ icon: 'fa-regular fa-tachometer-alt',
32
+ },
33
+ // category: {
34
+ // name: 'Category',
35
+ // title: 't("category", { scope: "common" })',
36
+ // icon: 'fa-light fa-list'
37
+ // },
38
+ },
39
+ };
40
+
41
+ class AXMEntityProvider {
42
+ constructor() {
43
+ this.injector = inject(Injector);
44
+ }
45
+ preload() {
46
+ const module = RootConfig.module.name;
47
+ return Array.from(Object.values(RootConfig.entities)).map((entity) => ({
48
+ module: module,
49
+ entity: entity.name,
50
+ }));
51
+ }
52
+ async get(moduleName, entityName) {
53
+ if (moduleName == RootConfig.module.name) {
54
+ switch (entityName) {
55
+ case RootConfig.entities.dashboard.name:
56
+ return (await Promise.resolve().then(function () { return dashboard_entity; })).dashboardFactory(this.injector);
57
+ }
58
+ }
59
+ return null;
60
+ }
61
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMEntityProvider, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
62
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMEntityProvider }); }
63
+ }
64
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMEntityProvider, decorators: [{
65
+ type: Injectable
66
+ }] });
67
+
68
+ class AXMMenuProvider {
69
+ constructor() {
70
+ this.entityService = inject(AXPEntityService);
71
+ }
72
+ async provide(context) {
73
+ const scope = RootConfig.config.i18n;
74
+ const module = RootConfig.module;
75
+ // context.addItems([
76
+ // {
77
+ // priority: 9001,
78
+ // text: `t('module-name', {scope:"${scope}"})`,
79
+ // icon: module.icon,
80
+ // children: [
81
+ // {
82
+ // text: `t("entity-name", { scope: "common" })`,
83
+ // path: this.entityService.createPath(module.name, RootConfig.entities.category.name),
84
+ // icon: RootConfig.entities.category.icon,
85
+ // priority: 1,
86
+ // }
87
+ // ],
88
+ // },
89
+ // ]);
90
+ }
91
+ }
92
+
93
+ class AXMPermissionProvider {
94
+ async provide(context) {
95
+ // context.addPermissions([
96
+ // {
97
+ // name: 'view_templates',
98
+ // title: 'Permission to view templates',
99
+ // isArchived: false,
100
+ // },
101
+ // ]);
102
+ }
103
+ }
104
+
105
+ class AXMSearchCommandProvider extends AXPSearchCommandProvider {
106
+ constructor() {
107
+ super(...arguments);
108
+ this.commands = [
109
+ // {
110
+ // group: 'command',
111
+ // title: 'New Form Template',
112
+ // icon: RootConfig.entities.template.icon,
113
+ // description: 'Create a new form template for designing reusable forms.', // Added description
114
+ // commands: {
115
+ // 'create-entity': {
116
+ // entity: `${RootConfig.module.name}.${RootConfig.entities.template.name}`,
117
+ // },
118
+ // },
119
+ // }
120
+ ];
121
+ }
122
+ }
123
+
124
+ class AXMSettingProvider {
125
+ async provide(context) {
126
+ // context
127
+ // // Add Form Template Group
128
+ // .addGroup('form-template', 'Form Template', 'Settings related to form templates.', RootConfig.module.icon)
129
+ // // Start Interface Section
130
+ // .addSection('interface', 'UI Interface', 'Customize the user interface for forms.')
131
+ // .addSetting({
132
+ // key: 'history-panel',
133
+ // title: 'Show History Panel',
134
+ // scope: 'U',
135
+ // isInherited: true,
136
+ // defaultValue: false,
137
+ // widget: {
138
+ // type: AXPWidgetsCatalog.toggle,
139
+ // },
140
+ // description: 'Enable or disable the history panel for forms.',
141
+ // validationRules: [
142
+ // {
143
+ // rule: 'required',
144
+ // },
145
+ // ],
146
+ // })
147
+ // .endSection()
148
+ // .endGroup();
149
+ }
150
+ }
151
+
152
+ class AXMDashboardService extends AXMEntityCrudServiceImpl {
153
+ }
154
+ class AXMDashboardServiceImpl extends AXMDashboardService {
155
+ constructor() {
156
+ super(`${RootConfig.module.name}.${RootConfig.entities.dashboard.name}`);
157
+ }
158
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMDashboardServiceImpl, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
159
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMDashboardServiceImpl }); }
160
+ }
161
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMDashboardServiceImpl, decorators: [{
162
+ type: Injectable
163
+ }], ctorParameters: () => [] });
164
+
165
+ async function dashboardFactory(injector) {
166
+ const dataService = injector.get(AXMDashboardService);
167
+ const i18n = RootConfig.config.i18n;
168
+ const entityDef = {
169
+ module: RootConfig.module.name,
170
+ name: RootConfig.entities.dashboard.name,
171
+ source: '',
172
+ title: RootConfig.entities.dashboard.title,
173
+ formats: {
174
+ individual: RootConfig.entities.dashboard.title,
175
+ plural: RootConfig.entities.dashboard.titlePlural,
176
+ searchResult: {
177
+ title: '{{ title }}',
178
+ description: RootConfig.module.title,
179
+ },
180
+ },
181
+ relatedEntities: [],
182
+ groups: [
183
+ {
184
+ id: 'section',
185
+ title: RootConfig.entities.dashboard.title,
186
+ },
187
+ ],
188
+ properties: [
189
+ {
190
+ name: 'name',
191
+ title: `t("name", { scope: "common" })`,
192
+ groupId: 'section',
193
+ options: {
194
+ sort: {
195
+ enabled: false,
196
+ },
197
+ filter: {
198
+ advance: {
199
+ enabled: false,
200
+ },
201
+ inline: {
202
+ enabled: false,
203
+ },
204
+ },
205
+ },
206
+ schema: {
207
+ dataType: 'string',
208
+ interface: {
209
+ type: AXPWidgetsCatalog.text,
210
+ },
211
+ },
212
+ },
213
+ {
214
+ name: 'title',
215
+ title: `t("title", { scope: "common" })`,
216
+ groupId: 'section',
217
+ options: {
218
+ sort: {
219
+ enabled: true,
220
+ },
221
+ filter: {
222
+ advance: {
223
+ enabled: true,
224
+ },
225
+ inline: {
226
+ enabled: true,
227
+ },
228
+ },
229
+ },
230
+ schema: {
231
+ dataType: 'string',
232
+ interface: {
233
+ type: AXPWidgetsCatalog.text,
234
+ },
235
+ },
236
+ validations: [
237
+ {
238
+ rule: 'required',
239
+ },
240
+ ],
241
+ },
242
+ {
243
+ name: 'description',
244
+ title: `t("description", { scope: "${i18n}" })`,
245
+ groupId: 'section',
246
+ options: {
247
+ sort: {
248
+ enabled: false,
249
+ },
250
+ filter: {
251
+ advance: {
252
+ enabled: false,
253
+ },
254
+ inline: {
255
+ enabled: false,
256
+ },
257
+ },
258
+ },
259
+ schema: {
260
+ dataType: 'string',
261
+ interface: {
262
+ type: AXPWidgetsCatalog.text,
263
+ },
264
+ },
265
+ },
266
+ ],
267
+ columns: [{ name: 'name' }, { name: 'title' }, { name: 'description' }],
268
+ commands: {
269
+ create: {
270
+ execute: async (data) => {
271
+ const res = await dataService.insertOne(data);
272
+ return { id: res };
273
+ },
274
+ },
275
+ delete: {
276
+ execute: async (id) => {
277
+ return await dataService.deleteOne(id);
278
+ },
279
+ },
280
+ update: {
281
+ execute: async (data) => {
282
+ return await dataService.updateOne(data.id, data);
283
+ },
284
+ },
285
+ },
286
+ queries: {
287
+ byKey: {
288
+ execute: async (id) => {
289
+ return await dataService.getOne(id);
290
+ },
291
+ type: AXPEntityQueryType.Single,
292
+ },
293
+ list: {
294
+ execute: async (e) => {
295
+ return await dataService.query({ skip: e.skip, take: e.take, filter: e.filter });
296
+ },
297
+ type: AXPEntityQueryType.List,
298
+ },
299
+ },
300
+ interfaces: {
301
+ master: {
302
+ create: {
303
+ sections: [
304
+ {
305
+ id: 'section',
306
+ },
307
+ ],
308
+ properties: [
309
+ {
310
+ name: 'name',
311
+ layout: {
312
+ positions: {
313
+ lg: {
314
+ colSpan: 6,
315
+ order: 1,
316
+ },
317
+ },
318
+ },
319
+ },
320
+ {
321
+ name: 'title',
322
+ layout: {
323
+ positions: {
324
+ lg: {
325
+ colSpan: 6,
326
+ order: 2,
327
+ },
328
+ },
329
+ },
330
+ },
331
+ {
332
+ name: 'description',
333
+ layout: {
334
+ positions: {
335
+ lg: {
336
+ colSpan: 12,
337
+ order: 3,
338
+ },
339
+ },
340
+ },
341
+ },
342
+ ],
343
+ },
344
+ update: {
345
+ sections: [
346
+ {
347
+ id: 'section',
348
+ },
349
+ ],
350
+ properties: [
351
+ {
352
+ name: 'name',
353
+ layout: {
354
+ positions: {
355
+ lg: {
356
+ colSpan: 6,
357
+ order: 1,
358
+ },
359
+ },
360
+ },
361
+ },
362
+ {
363
+ name: 'title',
364
+ layout: {
365
+ positions: {
366
+ lg: {
367
+ colSpan: 6,
368
+ order: 2,
369
+ },
370
+ },
371
+ },
372
+ },
373
+ {
374
+ name: 'description',
375
+ layout: {
376
+ positions: {
377
+ lg: {
378
+ colSpan: 12,
379
+ order: 3,
380
+ },
381
+ },
382
+ },
383
+ },
384
+ ],
385
+ },
386
+ single: {
387
+ title: '{{title}}',
388
+ sections: [
389
+ {
390
+ id: 'section',
391
+ layout: {
392
+ positions: {
393
+ lg: {
394
+ colSpan: 12,
395
+ },
396
+ },
397
+ },
398
+ },
399
+ ],
400
+ properties: [
401
+ {
402
+ name: 'name',
403
+ layout: {
404
+ positions: {
405
+ lg: {
406
+ colSpan: 6,
407
+ order: 1,
408
+ },
409
+ },
410
+ },
411
+ },
412
+ {
413
+ name: 'title',
414
+ layout: {
415
+ positions: {
416
+ lg: {
417
+ colSpan: 6,
418
+ order: 2,
419
+ },
420
+ },
421
+ },
422
+ },
423
+ {
424
+ name: 'description',
425
+ layout: {
426
+ positions: {
427
+ lg: {
428
+ colSpan: 12,
429
+ order: 3,
430
+ },
431
+ },
432
+ },
433
+ },
434
+ ],
435
+ actions: [],
436
+ },
437
+ list: {
438
+ actions: [
439
+ {
440
+ title: `t("create", { scope: "common" })`,
441
+ command: 'create-entity',
442
+ priority: 'primary',
443
+ type: 'create',
444
+ scope: AXPEntityCommandScope.TypeLevel,
445
+ },
446
+ {
447
+ title: 't("deleteItems", { scope: "common" })',
448
+ command: 'delete-entity',
449
+ priority: 'primary',
450
+ type: 'delete',
451
+ scope: AXPEntityCommandScope.Selected,
452
+ },
453
+ {
454
+ title: 't("detail", { scope: "common" })',
455
+ command: 'open-entity',
456
+ priority: 'secondary',
457
+ type: 'view',
458
+ scope: AXPEntityCommandScope.Individual,
459
+ },
460
+ {
461
+ title: 't("delete", { scope: "common" })',
462
+ command: 'delete-entity',
463
+ priority: 'secondary',
464
+ type: 'delete',
465
+ scope: AXPEntityCommandScope.Individual,
466
+ },
467
+ ],
468
+ views: [
469
+ createAllQueryView({
470
+ sorts: [{ name: 'name', dir: 'asc' }]
471
+ }),
472
+ ],
473
+ },
474
+ },
475
+ },
476
+ };
477
+ return entityDef;
478
+ }
479
+
480
+ var dashboard_entity = /*#__PURE__*/Object.freeze({
481
+ __proto__: null,
482
+ dashboardFactory: dashboardFactory
483
+ });
484
+
485
+ class AXMDashboardWidgetDataService extends AXMEntityCrudServiceImpl {
486
+ }
487
+ class AXMDashboardWidgetDataServiceImpl extends AXMDashboardWidgetDataService {
488
+ constructor() {
489
+ super(`${RootConfig.module.name}.${RootConfig.entities.dashboardWidgetData.name}`);
490
+ }
491
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMDashboardWidgetDataServiceImpl, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
492
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMDashboardWidgetDataServiceImpl }); }
493
+ }
494
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMDashboardWidgetDataServiceImpl, decorators: [{
495
+ type: Injectable
496
+ }], ctorParameters: () => [] });
497
+
498
+ async function dashboardWidgetDataFactory(injector) {
499
+ const dataService = injector.get(AXMDashboardWidgetDataService);
500
+ const i18n = RootConfig.config.i18n;
501
+ const entityDef = {
502
+ module: RootConfig.module.name,
503
+ name: RootConfig.entities.dashboardWidgetData.name,
504
+ source: '',
505
+ title: RootConfig.entities.dashboardWidgetData.title,
506
+ formats: {
507
+ individual: RootConfig.entities.dashboardWidgetData.title,
508
+ plural: RootConfig.entities.dashboardWidgetData.titlePlural,
509
+ searchResult: {
510
+ title: '{{ title }}',
511
+ description: RootConfig.module.title,
512
+ },
513
+ },
514
+ relatedEntities: [],
515
+ groups: [
516
+ {
517
+ id: 'section',
518
+ title: RootConfig.entities.dashboardWidgetData.title,
519
+ },
520
+ ],
521
+ properties: [
522
+ {
523
+ name: 'x',
524
+ title: `t("x", { scope: "${i18n}" })`,
525
+ groupId: 'section',
526
+ options: {
527
+ sort: {
528
+ enabled: true,
529
+ },
530
+ filter: {
531
+ advance: {
532
+ enabled: true,
533
+ },
534
+ inline: {
535
+ enabled: false,
536
+ },
537
+ },
538
+ },
539
+ schema: {
540
+ dataType: 'string',
541
+ interface: {
542
+ type: AXPWidgetsCatalog.number,
543
+ },
544
+ },
545
+ },
546
+ {
547
+ name: 'y',
548
+ title: `t("y", { scope: "${i18n}" })`,
549
+ groupId: 'section',
550
+ options: {
551
+ sort: {
552
+ enabled: true,
553
+ },
554
+ filter: {
555
+ advance: {
556
+ enabled: true,
557
+ },
558
+ inline: {
559
+ enabled: false,
560
+ },
561
+ },
562
+ },
563
+ schema: {
564
+ dataType: 'string',
565
+ interface: {
566
+ type: AXPWidgetsCatalog.number,
567
+ },
568
+ },
569
+ },
570
+ {
571
+ name: 'w',
572
+ title: `t("w", { scope: "${i18n}" })`,
573
+ groupId: 'section',
574
+ options: {
575
+ sort: {
576
+ enabled: true,
577
+ },
578
+ filter: {
579
+ advance: {
580
+ enabled: true,
581
+ },
582
+ inline: {
583
+ enabled: false,
584
+ },
585
+ },
586
+ },
587
+ schema: {
588
+ dataType: 'string',
589
+ interface: {
590
+ type: AXPWidgetsCatalog.number,
591
+ },
592
+ },
593
+ },
594
+ {
595
+ name: 'h',
596
+ title: `t("h", { scope: "${i18n}" })`,
597
+ groupId: 'section',
598
+ options: {
599
+ sort: {
600
+ enabled: true,
601
+ },
602
+ filter: {
603
+ advance: {
604
+ enabled: true,
605
+ },
606
+ inline: {
607
+ enabled: false,
608
+ },
609
+ },
610
+ },
611
+ schema: {
612
+ dataType: 'string',
613
+ interface: {
614
+ type: AXPWidgetsCatalog.number,
615
+ },
616
+ },
617
+ },
618
+ {
619
+ name: 'disableResize',
620
+ title: `t("disableResize", { scope: "${i18n}" })`,
621
+ groupId: 'section',
622
+ options: {
623
+ sort: {
624
+ enabled: true,
625
+ },
626
+ filter: {
627
+ advance: {
628
+ enabled: true,
629
+ },
630
+ inline: {
631
+ enabled: false,
632
+ },
633
+ },
634
+ },
635
+ schema: {
636
+ dataType: 'string',
637
+ interface: {
638
+ type: AXPWidgetsCatalog.text,
639
+ },
640
+ },
641
+ },
642
+ {
643
+ name: 'disableDrag',
644
+ title: `t("disableDrag", { scope: "${i18n}" })`,
645
+ groupId: 'section',
646
+ options: {
647
+ sort: {
648
+ enabled: true,
649
+ },
650
+ filter: {
651
+ advance: {
652
+ enabled: true,
653
+ },
654
+ inline: {
655
+ enabled: false,
656
+ },
657
+ },
658
+ },
659
+ schema: {
660
+ dataType: 'string',
661
+ interface: {
662
+ type: AXPWidgetsCatalog.text,
663
+ },
664
+ },
665
+ },
666
+ ],
667
+ columns: [{ name: 'x' }, { name: 'y' }, { name: 'w' }, { name: 'h' }],
668
+ commands: {
669
+ create: {
670
+ execute: async (data) => {
671
+ const res = await dataService.insertOne(data);
672
+ return { id: res };
673
+ },
674
+ },
675
+ delete: {
676
+ execute: async (id) => {
677
+ return await dataService.deleteOne(id);
678
+ },
679
+ },
680
+ update: {
681
+ execute: async (data) => {
682
+ return await dataService.updateOne(data.id, data);
683
+ },
684
+ },
685
+ },
686
+ queries: {
687
+ byKey: {
688
+ execute: async (id) => {
689
+ return await dataService.getOne(id);
690
+ },
691
+ type: AXPEntityQueryType.Single,
692
+ },
693
+ list: {
694
+ execute: async (e) => {
695
+ return await dataService.query({ skip: e.skip, take: e.take, filter: e.filter });
696
+ },
697
+ type: AXPEntityQueryType.List,
698
+ },
699
+ },
700
+ interfaces: {
701
+ master: {
702
+ create: {
703
+ sections: [
704
+ {
705
+ id: 'section',
706
+ },
707
+ ],
708
+ properties: [
709
+ {
710
+ name: 'x',
711
+ layout: {
712
+ positions: {
713
+ lg: {
714
+ colSpan: 6,
715
+ order: 1,
716
+ },
717
+ },
718
+ },
719
+ },
720
+ {
721
+ name: 'y',
722
+ layout: {
723
+ positions: {
724
+ lg: {
725
+ colSpan: 6,
726
+ order: 2,
727
+ },
728
+ },
729
+ },
730
+ },
731
+ {
732
+ name: 'w',
733
+ layout: {
734
+ positions: {
735
+ lg: {
736
+ colSpan: 6,
737
+ order: 3,
738
+ },
739
+ },
740
+ },
741
+ },
742
+ {
743
+ name: 'h',
744
+ layout: {
745
+ positions: {
746
+ lg: {
747
+ colSpan: 6,
748
+ order: 4,
749
+ },
750
+ },
751
+ },
752
+ },
753
+ {
754
+ name: 'disableResize',
755
+ layout: {
756
+ positions: {
757
+ lg: {
758
+ colSpan: 12,
759
+ order: 5,
760
+ },
761
+ },
762
+ },
763
+ },
764
+ {
765
+ name: 'disableDrag',
766
+ layout: {
767
+ positions: {
768
+ lg: {
769
+ colSpan: 12,
770
+ order: 6,
771
+ },
772
+ },
773
+ },
774
+ },
775
+ ],
776
+ },
777
+ update: {
778
+ sections: [
779
+ {
780
+ id: 'section',
781
+ },
782
+ ],
783
+ properties: [
784
+ {
785
+ name: 'x',
786
+ layout: {
787
+ positions: {
788
+ lg: {
789
+ colSpan: 6,
790
+ order: 1,
791
+ },
792
+ },
793
+ },
794
+ },
795
+ {
796
+ name: 'y',
797
+ layout: {
798
+ positions: {
799
+ lg: {
800
+ colSpan: 6,
801
+ order: 2,
802
+ },
803
+ },
804
+ },
805
+ },
806
+ {
807
+ name: 'w',
808
+ layout: {
809
+ positions: {
810
+ lg: {
811
+ colSpan: 6,
812
+ order: 3,
813
+ },
814
+ },
815
+ },
816
+ },
817
+ {
818
+ name: 'h',
819
+ layout: {
820
+ positions: {
821
+ lg: {
822
+ colSpan: 6,
823
+ order: 4,
824
+ },
825
+ },
826
+ },
827
+ },
828
+ {
829
+ name: 'disableResize',
830
+ layout: {
831
+ positions: {
832
+ lg: {
833
+ colSpan: 12,
834
+ order: 5,
835
+ },
836
+ },
837
+ },
838
+ },
839
+ {
840
+ name: 'disableDrag',
841
+ layout: {
842
+ positions: {
843
+ lg: {
844
+ colSpan: 12,
845
+ order: 6,
846
+ },
847
+ },
848
+ },
849
+ },
850
+ ],
851
+ },
852
+ single: {
853
+ title: '{{title}}',
854
+ sections: [
855
+ {
856
+ id: 'section',
857
+ layout: {
858
+ positions: {
859
+ lg: {
860
+ colSpan: 12,
861
+ },
862
+ },
863
+ },
864
+ },
865
+ ],
866
+ properties: [
867
+ {
868
+ name: 'x',
869
+ layout: {
870
+ positions: {
871
+ lg: {
872
+ colSpan: 6,
873
+ order: 1,
874
+ },
875
+ },
876
+ },
877
+ },
878
+ {
879
+ name: 'y',
880
+ layout: {
881
+ positions: {
882
+ lg: {
883
+ colSpan: 6,
884
+ order: 2,
885
+ },
886
+ },
887
+ },
888
+ },
889
+ {
890
+ name: 'w',
891
+ layout: {
892
+ positions: {
893
+ lg: {
894
+ colSpan: 6,
895
+ order: 3,
896
+ },
897
+ },
898
+ },
899
+ },
900
+ {
901
+ name: 'h',
902
+ layout: {
903
+ positions: {
904
+ lg: {
905
+ colSpan: 6,
906
+ order: 4,
907
+ },
908
+ },
909
+ },
910
+ },
911
+ {
912
+ name: 'disableResize',
913
+ layout: {
914
+ positions: {
915
+ lg: {
916
+ colSpan: 12,
917
+ order: 5,
918
+ },
919
+ },
920
+ },
921
+ },
922
+ {
923
+ name: 'disableDrag',
924
+ layout: {
925
+ positions: {
926
+ lg: {
927
+ colSpan: 12,
928
+ order: 6,
929
+ },
930
+ },
931
+ },
932
+ },
933
+ ],
934
+ actions: [],
935
+ },
936
+ list: {
937
+ actions: [
938
+ {
939
+ title: `t("create", { scope: "common" })`,
940
+ command: 'create-entity',
941
+ priority: 'primary',
942
+ type: 'create',
943
+ scope: AXPEntityCommandScope.TypeLevel,
944
+ },
945
+ {
946
+ title: 't("deleteItems", { scope: "common" })',
947
+ command: 'delete-entity',
948
+ priority: 'primary',
949
+ type: 'delete',
950
+ scope: AXPEntityCommandScope.Selected,
951
+ },
952
+ {
953
+ title: 't("detail", { scope: "common" })',
954
+ command: 'open-entity',
955
+ priority: 'secondary',
956
+ type: 'view',
957
+ scope: AXPEntityCommandScope.Individual,
958
+ },
959
+ {
960
+ title: 't("delete", { scope: "common" })',
961
+ command: 'delete-entity',
962
+ priority: 'secondary',
963
+ type: 'delete',
964
+ scope: AXPEntityCommandScope.Individual,
965
+ },
966
+ ],
967
+ views: [
968
+ createAllQueryView({
969
+ sorts: [{ name: 'x', dir: 'asc' }],
970
+ }),
971
+ ],
972
+ },
973
+ },
974
+ },
975
+ };
976
+ return entityDef;
977
+ }
978
+
979
+ function routesFactory() {
980
+ const config = inject(AXP_ENTITY_CONFIG_TOKEN);
981
+ const routes = [
982
+ {
983
+ path: ':app',
984
+ component: config.viewers.root(),
985
+ children: [
986
+ {
987
+ path: 'home',
988
+ loadComponent: () => import('./acorex-modules-common-index-zaFxpV8u.mjs').then((c) => c.AXPDashboardHomeComponent),
989
+ },
990
+ ],
991
+ },
992
+ ];
993
+ return routes;
994
+ }
995
+ class AXMCommonModule {
996
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMCommonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
997
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.0.3", ngImport: i0, type: AXMCommonModule }); }
998
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMCommonModule, providers: [
999
+ {
1000
+ provide: AXMDashboardWidgetDataService,
1001
+ useClass: AXMDashboardWidgetDataServiceImpl,
1002
+ },
1003
+ {
1004
+ provide: AXP_MENU_PROVIDER,
1005
+ useClass: AXMMenuProvider,
1006
+ multi: true,
1007
+ },
1008
+ {
1009
+ provide: AXP_ENTITY_DEFINITION_LOADER,
1010
+ useClass: AXMEntityProvider,
1011
+ multi: true,
1012
+ },
1013
+ {
1014
+ provide: AXMDashboardService,
1015
+ useClass: AXMDashboardServiceImpl,
1016
+ },
1017
+ {
1018
+ provide: AXP_SETTING_DEFINITION_PROVIDER,
1019
+ useClass: AXMSettingProvider,
1020
+ multi: true,
1021
+ },
1022
+ {
1023
+ provide: AXP_SEARCH_PROVIDER,
1024
+ useClass: AXMSearchCommandProvider,
1025
+ multi: true,
1026
+ },
1027
+ {
1028
+ provide: AXP_PERMISSION_PROVIDER,
1029
+ useClass: AXMPermissionProvider,
1030
+ multi: true,
1031
+ },
1032
+ {
1033
+ provide: ROUTES,
1034
+ multi: true,
1035
+ useFactory: routesFactory,
1036
+ },
1037
+ ] }); }
1038
+ }
1039
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: AXMCommonModule, decorators: [{
1040
+ type: NgModule,
1041
+ args: [{
1042
+ imports: [],
1043
+ exports: [],
1044
+ declarations: [],
1045
+ providers: [
1046
+ {
1047
+ provide: AXMDashboardWidgetDataService,
1048
+ useClass: AXMDashboardWidgetDataServiceImpl,
1049
+ },
1050
+ {
1051
+ provide: AXP_MENU_PROVIDER,
1052
+ useClass: AXMMenuProvider,
1053
+ multi: true,
1054
+ },
1055
+ {
1056
+ provide: AXP_ENTITY_DEFINITION_LOADER,
1057
+ useClass: AXMEntityProvider,
1058
+ multi: true,
1059
+ },
1060
+ {
1061
+ provide: AXMDashboardService,
1062
+ useClass: AXMDashboardServiceImpl,
1063
+ },
1064
+ {
1065
+ provide: AXP_SETTING_DEFINITION_PROVIDER,
1066
+ useClass: AXMSettingProvider,
1067
+ multi: true,
1068
+ },
1069
+ {
1070
+ provide: AXP_SEARCH_PROVIDER,
1071
+ useClass: AXMSearchCommandProvider,
1072
+ multi: true,
1073
+ },
1074
+ {
1075
+ provide: AXP_PERMISSION_PROVIDER,
1076
+ useClass: AXMPermissionProvider,
1077
+ multi: true,
1078
+ },
1079
+ {
1080
+ provide: ROUTES,
1081
+ multi: true,
1082
+ useFactory: routesFactory,
1083
+ },
1084
+ ],
1085
+ }]
1086
+ }] });
1087
+
1088
+ //export * from './lib/pages';
1089
+
1090
+ /**
1091
+ * Generated bundle index. Do not edit.
1092
+ */
1093
+
1094
+ export { AXMCommonModule, AXMEntityProvider, AXMMenuProvider, AXMSearchCommandProvider, AXMSettingProvider, RootConfig };
1095
+ //# sourceMappingURL=acorex-modules-common.mjs.map