@acorex/modules 18.1.2 → 18.1.4

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 (75) hide show
  1. package/application-management/lib/layouts/index.d.ts +0 -1
  2. package/application-management/lib/layouts/module-entity-detail-view/module-entity-detail-view.component.d.ts +1 -2
  3. package/application-management/lib/workflows/index.d.ts +0 -1
  4. package/backend/lib/data/api/comment.mock.service.d.ts +62 -0
  5. package/backend/lib/data/index.d.ts +1 -0
  6. package/esm2022/application-management/lib/application-management.module.mjs +2 -6
  7. package/esm2022/application-management/lib/entities/property.entity.mjs +10 -12
  8. package/esm2022/application-management/lib/layouts/index.mjs +1 -2
  9. package/esm2022/application-management/lib/layouts/module-entity-detail-view/module-entity-detail-view.component.mjs +3 -17
  10. package/esm2022/application-management/lib/workflows/index.mjs +1 -2
  11. package/esm2022/auth/lib/account/profile/profile-slot.component.mjs +3 -11
  12. package/esm2022/backend/lib/backend.module.mjs +2 -2
  13. package/esm2022/backend/lib/data/api/comment.mock.service.mjs +142 -0
  14. package/esm2022/backend/lib/data/index.mjs +2 -1
  15. package/esm2022/notification-management/acorex-modules-notification-management.mjs +5 -0
  16. package/esm2022/notification-management/index.mjs +4 -0
  17. package/esm2022/notification-management/lib/entities/notification-channel.entity.mjs +329 -0
  18. package/esm2022/notification-management/lib/entities/notification-template.entity.mjs +298 -0
  19. package/esm2022/notification-management/lib/notification-management-mock-data.mjs +20 -0
  20. package/esm2022/notification-management/lib/notification-management.module.mjs +44 -0
  21. package/esm2022/notification-management/lib/notification-management.service.mjs +30 -0
  22. package/esm2022/template-management/acorex-modules-template-management.mjs +5 -0
  23. package/esm2022/template-management/index.mjs +4 -0
  24. package/esm2022/template-management/lib/entities/global-template.entity.mjs +298 -0
  25. package/esm2022/template-management/lib/entities/template-variable.entity.mjs +304 -0
  26. package/esm2022/template-management/lib/template-management-mock-data.mjs +11 -0
  27. package/esm2022/template-management/lib/template-management.module.mjs +45 -0
  28. package/esm2022/template-management/lib/template-management.service.mjs +24 -0
  29. package/fesm2022/{acorex-modules-application-management-module-designer.component-CRPUuYUe.mjs → acorex-modules-application-management-module-designer.component-C-lY0Apl.mjs} +1 -4
  30. package/fesm2022/{acorex-modules-application-management-module-designer.component-CRPUuYUe.mjs.map → acorex-modules-application-management-module-designer.component-C-lY0Apl.mjs.map} +1 -1
  31. package/fesm2022/acorex-modules-application-management.mjs +14 -145
  32. package/fesm2022/acorex-modules-application-management.mjs.map +1 -1
  33. package/fesm2022/{acorex-modules-auth-acorex-modules-auth-CS3UFdX0.mjs → acorex-modules-auth-acorex-modules-auth-4OzzidjS.mjs} +10 -18
  34. package/fesm2022/acorex-modules-auth-acorex-modules-auth-4OzzidjS.mjs.map +1 -0
  35. package/fesm2022/{acorex-modules-auth-app-chooser.component-BlJbIMKi.mjs → acorex-modules-auth-app-chooser.component-CHTEeWgx.mjs} +2 -2
  36. package/fesm2022/{acorex-modules-auth-app-chooser.component-BlJbIMKi.mjs.map → acorex-modules-auth-app-chooser.component-CHTEeWgx.mjs.map} +1 -1
  37. package/fesm2022/{acorex-modules-auth-login.module-DGBKGxI3.mjs → acorex-modules-auth-login.module-DMit4yw0.mjs} +4 -4
  38. package/fesm2022/{acorex-modules-auth-login.module-DGBKGxI3.mjs.map → acorex-modules-auth-login.module-DMit4yw0.mjs.map} +1 -1
  39. package/fesm2022/{acorex-modules-auth-master.layout-B_8Sfw0M.mjs → acorex-modules-auth-master.layout-BCYIjTB0.mjs} +2 -2
  40. package/fesm2022/{acorex-modules-auth-master.layout-B_8Sfw0M.mjs.map → acorex-modules-auth-master.layout-BCYIjTB0.mjs.map} +1 -1
  41. package/fesm2022/{acorex-modules-auth-password.component-BfDjRRN_.mjs → acorex-modules-auth-password.component-D16ms36y.mjs} +2 -2
  42. package/fesm2022/{acorex-modules-auth-password.component-BfDjRRN_.mjs.map → acorex-modules-auth-password.component-D16ms36y.mjs.map} +1 -1
  43. package/fesm2022/{acorex-modules-auth-password.component-DZJ1qwfa.mjs → acorex-modules-auth-password.component-WA-CA0Ln.mjs} +2 -2
  44. package/fesm2022/{acorex-modules-auth-password.component-DZJ1qwfa.mjs.map → acorex-modules-auth-password.component-WA-CA0Ln.mjs.map} +1 -1
  45. package/fesm2022/{acorex-modules-auth-routes-Bw7nXDvx.mjs → acorex-modules-auth-routes-C3ye31RS.mjs} +2 -2
  46. package/fesm2022/{acorex-modules-auth-routes-Bw7nXDvx.mjs.map → acorex-modules-auth-routes-C3ye31RS.mjs.map} +1 -1
  47. package/fesm2022/{acorex-modules-auth-two-factor.module-DKStBo1V.mjs → acorex-modules-auth-two-factor.module-CkZCBo0B.mjs} +2 -2
  48. package/fesm2022/{acorex-modules-auth-two-factor.module-DKStBo1V.mjs.map → acorex-modules-auth-two-factor.module-CkZCBo0B.mjs.map} +1 -1
  49. package/fesm2022/acorex-modules-auth.mjs +1 -1
  50. package/fesm2022/acorex-modules-backend.mjs +142 -3
  51. package/fesm2022/acorex-modules-backend.mjs.map +1 -1
  52. package/fesm2022/acorex-modules-notification-management.mjs +728 -0
  53. package/fesm2022/acorex-modules-notification-management.mjs.map +1 -0
  54. package/fesm2022/acorex-modules-template-management.mjs +690 -0
  55. package/fesm2022/acorex-modules-template-management.mjs.map +1 -0
  56. package/notification-management/README.md +3 -0
  57. package/notification-management/index.d.ts +3 -0
  58. package/notification-management/lib/entities/notification-channel.entity.d.ts +3 -0
  59. package/notification-management/lib/entities/notification-template.entity.d.ts +3 -0
  60. package/notification-management/lib/notification-management-mock-data.d.ts +13 -0
  61. package/notification-management/lib/notification-management.module.d.ts +12 -0
  62. package/notification-management/lib/notification-management.service.d.ts +11 -0
  63. package/package.json +13 -1
  64. package/template-management/README.md +3 -0
  65. package/template-management/index.d.ts +3 -0
  66. package/template-management/lib/entities/global-template.entity.d.ts +3 -0
  67. package/template-management/lib/entities/template-variable.entity.d.ts +3 -0
  68. package/template-management/lib/template-management-mock-data.d.ts +7 -0
  69. package/template-management/lib/template-management.module.d.ts +12 -0
  70. package/template-management/lib/template-management.service.d.ts +9 -0
  71. package/application-management/lib/layouts/property-detail-view/modify-property-interface.component.d.ts +0 -5
  72. package/application-management/lib/workflows/modify-property-interface.workflow.d.ts +0 -26
  73. package/esm2022/application-management/lib/layouts/property-detail-view/modify-property-interface.component.mjs +0 -55
  74. package/esm2022/application-management/lib/workflows/modify-property-interface.workflow.mjs +0 -79
  75. package/fesm2022/acorex-modules-auth-acorex-modules-auth-CS3UFdX0.mjs.map +0 -1
@@ -0,0 +1,728 @@
1
+ import { AXPEntityDefinitionRegistryService } from '@acorex/platform/layout/entity';
2
+ import * as i0 from '@angular/core';
3
+ import { Injector, NgModule, Optional, Inject, Injectable } from '@angular/core';
4
+ import { AXPDataGenerator, AXPStorageService, AXPEntityDataProviderImpl, AXPEntityQueryType, AXPEntityCommandScope } from '@acorex/platform/common';
5
+ import { applySortArray, applyFilterArray } from '@acorex/platform/core';
6
+ import { AXPWidgetsCatalog } from '@acorex/platform/layout/builder';
7
+
8
+ class NotificationManagementModule {
9
+ static forRoot() {
10
+ return {
11
+ ngModule: NotificationManagementModule,
12
+ providers: [
13
+ {
14
+ provide: 'AXP_REGISTER_TEMPLATE_NoTIFICATION',
15
+ useFactory: async (entityRegistry, injector) => {
16
+ const notificationTemplateEntity = await (await Promise.resolve().then(function () { return notificationTemplate_entity; })).notificationTemplateEntityFactory(injector);
17
+ entityRegistry.register(notificationTemplateEntity);
18
+ //
19
+ const notificationChannelEntity = await (await Promise.resolve().then(function () { return notificationChannel_entity; })).notificationChannelEntityFactory(injector);
20
+ entityRegistry.register(notificationChannelEntity);
21
+ },
22
+ deps: [AXPEntityDefinitionRegistryService, Injector], // Add any dependencies if needed
23
+ },
24
+ ],
25
+ };
26
+ }
27
+ /**
28
+ * @ignore
29
+ */
30
+ constructor(instances) { }
31
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: NotificationManagementModule, deps: [{ token: 'AXP_REGISTER_TEMPLATE_NoTIFICATION', optional: true }], target: i0.ɵɵFactoryTarget.NgModule }); }
32
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: NotificationManagementModule }); }
33
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: NotificationManagementModule }); }
34
+ }
35
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: NotificationManagementModule, decorators: [{
36
+ type: NgModule,
37
+ args: [{
38
+ imports: [],
39
+ exports: [],
40
+ declarations: [],
41
+ }]
42
+ }], ctorParameters: () => [{ type: undefined, decorators: [{
43
+ type: Optional
44
+ }, {
45
+ type: Inject,
46
+ args: ['AXP_REGISTER_TEMPLATE_NoTIFICATION']
47
+ }] }] });
48
+
49
+ const CHANNELS = ['InApp', 'Email', 'SMS'];
50
+ const NOTIFICATIONS = Array.from({ length: 5 }).map((_, i) => {
51
+ const name = AXPDataGenerator.string;
52
+ return {
53
+ id: AXPDataGenerator.uuid(),
54
+ name: name,
55
+ title: name,
56
+ description: AXPDataGenerator.string(200),
57
+ };
58
+ });
59
+ const NOTIFICATION_CHANNELS = Array.from({ length: 3 }).map((_, i) => {
60
+ return {
61
+ id: AXPDataGenerator.uuid(),
62
+ body: AXPDataGenerator.string(400),
63
+ title: AXPDataGenerator.string(30),
64
+ Channel: CHANNELS[i],
65
+ };
66
+ });
67
+
68
+ class NotificationManagementService {
69
+ constructor(injector) {
70
+ const storageService = injector.get(AXPStorageService);
71
+ //
72
+ this._notificationTemplateDataProvider = new AXPEntityDataProviderImpl(storageService, 'notificationTemplates');
73
+ this._notificationTemplateDataProvider.initial(NOTIFICATIONS);
74
+ //
75
+ this._notificationChannelDataProvider = new AXPEntityDataProviderImpl(storageService, 'notificationChannel');
76
+ this._notificationTemplateDataProvider.initial(NOTIFICATION_CHANNELS);
77
+ }
78
+ get notificationTemplateDataProvider() {
79
+ return this._notificationTemplateDataProvider;
80
+ }
81
+ get notificationChannelDataProvider() {
82
+ return this._notificationChannelDataProvider;
83
+ }
84
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: NotificationManagementService, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable }); }
85
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: NotificationManagementService, providedIn: 'root' }); }
86
+ }
87
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: NotificationManagementService, decorators: [{
88
+ type: Injectable,
89
+ args: [{
90
+ providedIn: 'root',
91
+ }]
92
+ }], ctorParameters: () => [{ type: i0.Injector }] });
93
+
94
+ async function notificationChannelEntityFactory(injector) {
95
+ const dataService = injector.get(NotificationManagementService);
96
+ const entityDef = {
97
+ module: 'notification-management',
98
+ name: 'notificationChannel',
99
+ source: 'notification-management.notificationChannel',
100
+ title: 'Notification Channel',
101
+ formats: {
102
+ individual: 'Channel',
103
+ plural: 'Channels',
104
+ },
105
+ relatedEntities: [],
106
+ groups: [
107
+ {
108
+ id: 'notificationChannel',
109
+ title: 'Notification Channel',
110
+ },
111
+ ],
112
+ properties: [
113
+ {
114
+ name: 'title',
115
+ title: 'Title',
116
+ groupId: 'notificationChannel',
117
+ schema: {
118
+ dataType: 'string',
119
+ interface: {
120
+ type: AXPWidgetsCatalog.text,
121
+ },
122
+ },
123
+ validations: [
124
+ {
125
+ rule: 'required',
126
+ },
127
+ ],
128
+ },
129
+ {
130
+ name: 'template',
131
+ title: 'Template',
132
+ groupId: 'notificationChannel',
133
+ schema: {
134
+ dataType: 'string',
135
+ interface: {
136
+ type: AXPWidgetsCatalog.lookup,
137
+ options: {
138
+ entity: 'template-management.globalTemplate',
139
+ expose: { source: 'content', target: 'body' },
140
+ },
141
+ },
142
+ },
143
+ },
144
+ {
145
+ name: 'body',
146
+ title: 'Body',
147
+ groupId: 'notificationChannel',
148
+ schema: {
149
+ dataType: 'string',
150
+ interface: {
151
+ type: AXPWidgetsCatalog.largeText,
152
+ },
153
+ },
154
+ validations: [
155
+ {
156
+ rule: 'required',
157
+ },
158
+ ],
159
+ },
160
+ {
161
+ name: 'channel',
162
+ title: 'Channel',
163
+ groupId: 'notificationChannel',
164
+ schema: {
165
+ dataType: 'string',
166
+ interface: {
167
+ type: AXPWidgetsCatalog.select,
168
+ options: {
169
+ valueField: 'name',
170
+ textField: 'title',
171
+ dataSource: [
172
+ { title: 'SMS', name: 'sms' },
173
+ { title: 'Email', name: 'email' },
174
+ { title: 'In App', name: 'inApp' },
175
+ ],
176
+ direction: 'horizontal',
177
+ multiple: false,
178
+ },
179
+ },
180
+ },
181
+ validations: [
182
+ {
183
+ rule: 'required',
184
+ },
185
+ ],
186
+ },
187
+ ],
188
+ columns: [{ name: 'title' }, { name: 'body' }, { name: 'channel' }],
189
+ commands: {
190
+ create: {
191
+ execute: async (data) => {
192
+ const entity = Object.assign(data, { id: AXPDataGenerator.uuid() });
193
+ dataService.notificationChannelDataProvider.insertOne(entity);
194
+ return Promise.resolve(entity);
195
+ },
196
+ },
197
+ delete: {
198
+ execute: async (id) => {
199
+ await await dataService.notificationChannelDataProvider.deleteOne(id);
200
+ return Promise.resolve();
201
+ },
202
+ },
203
+ update: {
204
+ execute: async (data) => {
205
+ debugger;
206
+ return new Promise((resolve) => {
207
+ setTimeout(async () => {
208
+ await dataService.notificationChannelDataProvider.updateOne(data.id, data);
209
+ resolve(data);
210
+ }, 1000);
211
+ });
212
+ },
213
+ },
214
+ },
215
+ queries: {
216
+ byKey: {
217
+ execute: async (id) => {
218
+ return new Promise((resolve) => {
219
+ setTimeout(async () => {
220
+ const entity = await dataService.notificationChannelDataProvider.getOne(id);
221
+ resolve(entity);
222
+ }, 500);
223
+ });
224
+ },
225
+ type: AXPEntityQueryType.Single,
226
+ },
227
+ list: {
228
+ execute: async (e) => {
229
+ const list = await dataService.notificationChannelDataProvider.getAll();
230
+ const sortedItems = applySortArray(list, e.sort);
231
+ const filteredItems = applyFilterArray(sortedItems, e.filter ? [e.filter] : []);
232
+ return Promise.resolve({
233
+ total: filteredItems.length,
234
+ items: filteredItems.slice(e.skip, (e.skip ?? 0) + (e.take ?? 0)),
235
+ });
236
+ },
237
+ type: AXPEntityQueryType.List,
238
+ },
239
+ },
240
+ interfaces: {
241
+ master: {
242
+ create: {
243
+ sections: [
244
+ {
245
+ id: 'notificationChannel',
246
+ },
247
+ ],
248
+ properties: [
249
+ {
250
+ name: 'title',
251
+ layout: {
252
+ positions: {
253
+ lg: {
254
+ colSpan: 12,
255
+ },
256
+ },
257
+ },
258
+ },
259
+ {
260
+ name: 'body',
261
+ layout: {
262
+ positions: {
263
+ lg: {
264
+ colSpan: 12,
265
+ },
266
+ },
267
+ },
268
+ },
269
+ {
270
+ name: 'template',
271
+ layout: {
272
+ positions: {
273
+ lg: {
274
+ colSpan: 12,
275
+ },
276
+ },
277
+ },
278
+ },
279
+ {
280
+ name: 'channel',
281
+ layout: {
282
+ positions: {
283
+ lg: {
284
+ colSpan: 12,
285
+ },
286
+ },
287
+ },
288
+ },
289
+ ],
290
+ },
291
+ update: {
292
+ sections: [
293
+ {
294
+ id: 'notificationChannel',
295
+ },
296
+ ],
297
+ properties: [
298
+ {
299
+ name: 'title',
300
+ layout: {
301
+ positions: {
302
+ lg: {
303
+ colSpan: 12,
304
+ },
305
+ },
306
+ },
307
+ },
308
+ {
309
+ name: 'body',
310
+ layout: {
311
+ positions: {
312
+ lg: {
313
+ colSpan: 12,
314
+ },
315
+ },
316
+ },
317
+ },
318
+ {
319
+ name: 'channel',
320
+ layout: {
321
+ positions: {
322
+ lg: {
323
+ colSpan: 12,
324
+ },
325
+ },
326
+ },
327
+ },
328
+ ],
329
+ },
330
+ single: {
331
+ title: '{{title}}',
332
+ sections: [
333
+ {
334
+ id: 'notificationChannel',
335
+ },
336
+ ],
337
+ properties: [
338
+ {
339
+ name: 'title',
340
+ layout: {
341
+ positions: {
342
+ lg: {
343
+ colSpan: 6,
344
+ },
345
+ },
346
+ },
347
+ },
348
+ {
349
+ name: 'body',
350
+ layout: {
351
+ positions: {
352
+ lg: {
353
+ colSpan: 6,
354
+ },
355
+ },
356
+ },
357
+ },
358
+ {
359
+ name: 'channel',
360
+ layout: {
361
+ positions: {
362
+ lg: {
363
+ colSpan: 12,
364
+ },
365
+ },
366
+ },
367
+ },
368
+ ],
369
+ actions: [],
370
+ },
371
+ list: {
372
+ actions: [
373
+ {
374
+ title: 'Create New',
375
+ command: 'create-entity',
376
+ priority: 'primary',
377
+ type: 'create',
378
+ scope: AXPEntityCommandScope.TypeLevel,
379
+ },
380
+ {
381
+ title: 'Delete Items',
382
+ command: 'delete-entity',
383
+ priority: 'primary',
384
+ type: 'delete',
385
+ scope: AXPEntityCommandScope.Selected,
386
+ },
387
+ {
388
+ title: 'Details',
389
+ command: 'open-entity',
390
+ priority: 'primary',
391
+ type: 'view',
392
+ scope: AXPEntityCommandScope.Individual,
393
+ },
394
+ {
395
+ title: 'Delete',
396
+ command: 'delete-entity',
397
+ priority: 'primary',
398
+ type: 'delete',
399
+ scope: AXPEntityCommandScope.Individual,
400
+ },
401
+ ],
402
+ views: [
403
+ {
404
+ name: 'all',
405
+ title: 'All Items',
406
+ fixed: true,
407
+ columns: [],
408
+ conditions: [],
409
+ sorts: [],
410
+ },
411
+ ],
412
+ },
413
+ },
414
+ },
415
+ };
416
+ return entityDef;
417
+ }
418
+
419
+ var notificationChannel_entity = /*#__PURE__*/Object.freeze({
420
+ __proto__: null,
421
+ notificationChannelEntityFactory: notificationChannelEntityFactory
422
+ });
423
+
424
+ async function notificationTemplateEntityFactory(injector) {
425
+ const dataService = injector.get(NotificationManagementService);
426
+ const entityDef = {
427
+ module: 'notification-management',
428
+ name: 'notificationTemplate',
429
+ source: 'notification-management.notificationTemplate',
430
+ title: 'Templates',
431
+ formats: {
432
+ individual: 'NotificationTemplate',
433
+ plural: 'NotificationTemplates',
434
+ },
435
+ relatedEntities: [
436
+ {
437
+ entity: 'notification-management.notificationChannel',
438
+ columns: ['title', 'body', 'channel'],
439
+ conditions: [
440
+ {
441
+ name: 'notificationId',
442
+ operator: {
443
+ type: 'equal',
444
+ },
445
+ value: 'id',
446
+ },
447
+ ],
448
+ },
449
+ ],
450
+ groups: [
451
+ {
452
+ id: 'notification',
453
+ title: 'Notification',
454
+ },
455
+ ],
456
+ properties: [
457
+ {
458
+ name: 'name',
459
+ title: 'Name',
460
+ groupId: 'notification',
461
+ schema: {
462
+ dataType: 'string',
463
+ interface: {
464
+ type: AXPWidgetsCatalog.text,
465
+ },
466
+ },
467
+ },
468
+ {
469
+ name: 'title',
470
+ title: 'Title',
471
+ groupId: 'notification',
472
+ schema: {
473
+ dataType: 'string',
474
+ interface: {
475
+ type: AXPWidgetsCatalog.text,
476
+ },
477
+ },
478
+ },
479
+ {
480
+ name: 'description',
481
+ title: 'Description',
482
+ groupId: 'notification',
483
+ schema: {
484
+ dataType: 'string',
485
+ interface: {
486
+ type: AXPWidgetsCatalog.text,
487
+ },
488
+ },
489
+ },
490
+ ],
491
+ columns: [{ name: 'name' }, { name: 'title' }],
492
+ commands: {
493
+ create: {
494
+ execute: async (data) => {
495
+ const entity = Object.assign(data, { id: AXPDataGenerator.uuid() });
496
+ dataService.notificationTemplateDataProvider.insertOne(entity);
497
+ return Promise.resolve(entity);
498
+ },
499
+ },
500
+ delete: {
501
+ execute: async (id) => {
502
+ await await dataService.notificationTemplateDataProvider.deleteOne(id);
503
+ return Promise.resolve();
504
+ },
505
+ },
506
+ update: {
507
+ execute: async (data) => {
508
+ return new Promise((resolve) => {
509
+ setTimeout(async () => {
510
+ await dataService.notificationTemplateDataProvider.updateOne(data.id, data);
511
+ resolve(data);
512
+ }, 1000);
513
+ });
514
+ },
515
+ },
516
+ },
517
+ queries: {
518
+ byKey: {
519
+ execute: async (id) => {
520
+ return new Promise((resolve) => {
521
+ setTimeout(async () => {
522
+ const entity = await dataService.notificationTemplateDataProvider.getOne(id);
523
+ resolve(entity);
524
+ }, 500);
525
+ });
526
+ },
527
+ type: AXPEntityQueryType.Single,
528
+ },
529
+ list: {
530
+ execute: async (e) => {
531
+ const list = await dataService.notificationTemplateDataProvider.getAll();
532
+ const sortedItems = applySortArray(list, e.sort);
533
+ const filteredItems = applyFilterArray(sortedItems, e.filter ? [e.filter] : []);
534
+ return Promise.resolve({
535
+ total: filteredItems.length,
536
+ items: filteredItems.slice(e.skip, (e.skip ?? 0) + (e.take ?? 0)),
537
+ });
538
+ },
539
+ type: AXPEntityQueryType.List,
540
+ },
541
+ },
542
+ interfaces: {
543
+ master: {
544
+ create: {
545
+ sections: [
546
+ {
547
+ id: 'notification',
548
+ },
549
+ ],
550
+ properties: [
551
+ {
552
+ name: 'name',
553
+ layout: {
554
+ positions: {
555
+ lg: {
556
+ colSpan: 6,
557
+ },
558
+ },
559
+ },
560
+ },
561
+ {
562
+ name: 'title',
563
+ layout: {
564
+ positions: {
565
+ lg: {
566
+ colSpan: 6,
567
+ },
568
+ },
569
+ },
570
+ },
571
+ {
572
+ name: 'description',
573
+ layout: {
574
+ positions: {
575
+ lg: {
576
+ colSpan: 12,
577
+ },
578
+ },
579
+ },
580
+ },
581
+ ],
582
+ },
583
+ update: {
584
+ sections: [
585
+ {
586
+ id: 'notification',
587
+ },
588
+ ],
589
+ properties: [
590
+ {
591
+ name: 'name',
592
+ layout: {
593
+ positions: {
594
+ lg: {
595
+ colSpan: 6,
596
+ },
597
+ },
598
+ },
599
+ },
600
+ {
601
+ name: 'title',
602
+ layout: {
603
+ positions: {
604
+ lg: {
605
+ colSpan: 6,
606
+ },
607
+ },
608
+ },
609
+ },
610
+ {
611
+ name: 'description',
612
+ layout: {
613
+ positions: {
614
+ lg: {
615
+ colSpan: 12,
616
+ },
617
+ },
618
+ },
619
+ },
620
+ ],
621
+ },
622
+ single: {
623
+ title: '{{title}}',
624
+ sections: [
625
+ {
626
+ id: 'notification',
627
+ layout: {
628
+ positions: {
629
+ lg: {
630
+ colSpan: 12,
631
+ },
632
+ },
633
+ },
634
+ },
635
+ ],
636
+ properties: [
637
+ {
638
+ name: 'name',
639
+ layout: {
640
+ positions: {
641
+ lg: {
642
+ colSpan: 6,
643
+ },
644
+ },
645
+ },
646
+ },
647
+ {
648
+ name: 'title',
649
+ layout: {
650
+ positions: {
651
+ lg: {
652
+ colSpan: 6,
653
+ },
654
+ },
655
+ },
656
+ },
657
+ {
658
+ name: 'description',
659
+ layout: {
660
+ positions: {
661
+ lg: {
662
+ colSpan: 12,
663
+ },
664
+ },
665
+ },
666
+ },
667
+ ],
668
+ actions: [],
669
+ },
670
+ list: {
671
+ actions: [
672
+ {
673
+ title: 'Create New',
674
+ command: 'create-entity',
675
+ priority: 'primary',
676
+ type: 'create',
677
+ scope: AXPEntityCommandScope.TypeLevel,
678
+ },
679
+ {
680
+ title: 'Delete Items',
681
+ command: 'delete-entity',
682
+ priority: 'primary',
683
+ type: 'delete',
684
+ scope: AXPEntityCommandScope.Selected,
685
+ },
686
+ {
687
+ title: 'Details',
688
+ command: 'open-entity',
689
+ priority: 'primary',
690
+ type: 'view',
691
+ scope: AXPEntityCommandScope.Individual,
692
+ },
693
+ {
694
+ title: 'Delete',
695
+ command: 'delete-entity',
696
+ priority: 'primary',
697
+ type: 'delete',
698
+ scope: AXPEntityCommandScope.Individual,
699
+ },
700
+ ],
701
+ views: [
702
+ {
703
+ name: 'all',
704
+ title: 'All Items',
705
+ fixed: true,
706
+ columns: [],
707
+ conditions: [],
708
+ sorts: [],
709
+ },
710
+ ],
711
+ },
712
+ },
713
+ },
714
+ };
715
+ return entityDef;
716
+ }
717
+
718
+ var notificationTemplate_entity = /*#__PURE__*/Object.freeze({
719
+ __proto__: null,
720
+ notificationTemplateEntityFactory: notificationTemplateEntityFactory
721
+ });
722
+
723
+ /**
724
+ * Generated bundle index. Do not edit.
725
+ */
726
+
727
+ export { NotificationManagementModule, notificationChannelEntityFactory, notificationTemplateEntityFactory };
728
+ //# sourceMappingURL=acorex-modules-notification-management.mjs.map