@acorex-platform/module-content-management-client 0.0.32 → 0.0.37
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/fesm2022/acorex-platform-module-content-management-client-contracts-entities-promotion.mjs +302 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entities-promotion.mjs.map +1 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entities-text-template.mjs +264 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entities-text-template.mjs.map +1 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entity-catalog-acorex-platform-module-content-management-client-contracts-entity-catalog-CTui3PB-.mjs +56 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entity-catalog-acorex-platform-module-content-management-client-contracts-entity-catalog-CTui3PB-.mjs.map +1 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entity-catalog-promotion.entity-DXk_WIh3.mjs +266 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entity-catalog-promotion.entity-DXk_WIh3.mjs.map +1 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entity-catalog-text-template.entity-C8SFkg-E.mjs +228 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entity-catalog-text-template.entity-C8SFkg-E.mjs.map +1 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entity-catalog.mjs +2 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts-entity-catalog.mjs.map +1 -0
- package/fesm2022/acorex-platform-module-content-management-client-contracts.mjs.map +1 -1
- package/fesm2022/acorex-platform-module-content-management-client-local-entities.mjs +30 -0
- package/fesm2022/acorex-platform-module-content-management-client-local-entities.mjs.map +1 -0
- package/fesm2022/acorex-platform-module-content-management-client-permission-definition.provider-DHowV1eO.mjs.map +1 -1
- package/fesm2022/{acorex-platform-module-content-management-client-template-content-editor-widget-edit.component-BkSjAXjQ.mjs → acorex-platform-module-content-management-client-template-content-editor-widget-edit.component-BZUn1TiT.mjs} +2 -2
- package/fesm2022/{acorex-platform-module-content-management-client-template-content-editor-widget-edit.component-BkSjAXjQ.mjs.map → acorex-platform-module-content-management-client-template-content-editor-widget-edit.component-BZUn1TiT.mjs.map} +1 -1
- package/fesm2022/acorex-platform-module-content-management-client-template-content-editor-widget-view.component-CfupUZTI.mjs.map +1 -1
- package/fesm2022/acorex-platform-module-content-management-client.mjs +1 -1
- package/fesm2022/acorex-platform-module-content-management-client.mjs.map +1 -1
- package/package.json +17 -1
- package/types/acorex-platform-module-content-management-client-contracts-entities-promotion.d.ts +8 -0
- package/types/acorex-platform-module-content-management-client-contracts-entities-text-template.d.ts +5 -0
- package/types/acorex-platform-module-content-management-client-contracts-entity-catalog.d.ts +10 -0
- package/types/acorex-platform-module-content-management-client-local-entities.d.ts +12 -0
package/fesm2022/acorex-platform-module-content-management-client-contracts-entities-promotion.mjs
ADDED
|
@@ -0,0 +1,302 @@
|
|
|
1
|
+
import { AXPWidgetsList } from '@acorex-platform/framework-shared/core';
|
|
2
|
+
import { createAllQueryView, createQueryView, entityMasterCrudActions, entityMasterViewAction, entityMasterDeleteAction, AXPEntityType } from '@acorex-platform/framework-shared/entity';
|
|
3
|
+
|
|
4
|
+
const config = {
|
|
5
|
+
i18n: 'content-management',
|
|
6
|
+
};
|
|
7
|
+
const RootConfig = {
|
|
8
|
+
config,
|
|
9
|
+
module: {
|
|
10
|
+
module: 'ContentManagement',
|
|
11
|
+
name: 'ContentManagement',
|
|
12
|
+
title: `@${config.i18n}:module.title`,
|
|
13
|
+
icon: 'fa-light fa-file-invoice',
|
|
14
|
+
},
|
|
15
|
+
entities: {
|
|
16
|
+
promotion: {
|
|
17
|
+
name: 'Promotion',
|
|
18
|
+
title: `@${config.i18n}:promotions.entities.promotion.title`,
|
|
19
|
+
titlePlural: `@${config.i18n}:promotions.entities.promotion.plural`,
|
|
20
|
+
icon: 'fa-light fa-megaphone',
|
|
21
|
+
},
|
|
22
|
+
glossary: {
|
|
23
|
+
name: 'Glossary',
|
|
24
|
+
title: `@${config.i18n}:glossaries.entities.glossary.title`,
|
|
25
|
+
titlePlural: `@${config.i18n}:glossaries.entities.glossary.plural`,
|
|
26
|
+
icon: 'fa-light fa-file',
|
|
27
|
+
},
|
|
28
|
+
textTemplate: {
|
|
29
|
+
name: 'TextTemplate',
|
|
30
|
+
title: `@${config.i18n}:templates.entities.text-template.title`,
|
|
31
|
+
titlePlural: `@${config.i18n}:templates.entities.text-template.plural`,
|
|
32
|
+
icon: 'fa-light fa-envelope',
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
//#endregion
|
|
38
|
+
//#region ---- Entity definition factory ----
|
|
39
|
+
/**
|
|
40
|
+
* Builds the Promotion entity definition (mock/runtime parity with former module JSON seed).
|
|
41
|
+
*/
|
|
42
|
+
async function promotionEntityFactory() {
|
|
43
|
+
const i18n = RootConfig.config.i18n;
|
|
44
|
+
const entityDef = {
|
|
45
|
+
version: 2,
|
|
46
|
+
plugins: [
|
|
47
|
+
{ name: 'history' },
|
|
48
|
+
{ name: 'lock' },
|
|
49
|
+
{ name: 'compare' },
|
|
50
|
+
{ name: 'comments', options: { display: 'page' } },
|
|
51
|
+
{ name: 'distribution' },
|
|
52
|
+
{
|
|
53
|
+
name: 'status',
|
|
54
|
+
options: {
|
|
55
|
+
field: 'status',
|
|
56
|
+
definition: 'common.status.task',
|
|
57
|
+
defaultStatus: 'todo',
|
|
58
|
+
showInCreate: false,
|
|
59
|
+
},
|
|
60
|
+
},
|
|
61
|
+
{ name: 'policy', options: { policy: 'test' } },
|
|
62
|
+
{ name: 'workflow-run' },
|
|
63
|
+
{ name: 'attachments', options: {} },
|
|
64
|
+
{ name: 'gallery', options: { display: 'page' } },
|
|
65
|
+
],
|
|
66
|
+
module: RootConfig.module.name,
|
|
67
|
+
aggregate: 'promotions',
|
|
68
|
+
name: RootConfig.entities.promotion.name,
|
|
69
|
+
type: AXPEntityType.AggregateRoot,
|
|
70
|
+
title: RootConfig.entities.promotion.title,
|
|
71
|
+
icon: RootConfig.entities.promotion.icon,
|
|
72
|
+
formats: {
|
|
73
|
+
individual: RootConfig.entities.promotion.title,
|
|
74
|
+
plural: RootConfig.entities.promotion.titlePlural,
|
|
75
|
+
searchResult: {
|
|
76
|
+
title: '{{ title }}',
|
|
77
|
+
description: RootConfig.module.title,
|
|
78
|
+
},
|
|
79
|
+
},
|
|
80
|
+
groups: [{ id: 'promotion', title: 'Promotion' }],
|
|
81
|
+
properties: [
|
|
82
|
+
{
|
|
83
|
+
name: 'id',
|
|
84
|
+
title: 'ID',
|
|
85
|
+
groupId: 'promotion',
|
|
86
|
+
schema: {
|
|
87
|
+
dataType: 'uuid',
|
|
88
|
+
visible: false,
|
|
89
|
+
nullable: false,
|
|
90
|
+
readonly: true,
|
|
91
|
+
unique: { enabled: true },
|
|
92
|
+
},
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
name: 'createdAt',
|
|
96
|
+
title: '@general:terms.datetime.created-at',
|
|
97
|
+
groupId: 'promotion',
|
|
98
|
+
schema: {
|
|
99
|
+
dataType: 'dateTime',
|
|
100
|
+
nullable: true,
|
|
101
|
+
readonly: true,
|
|
102
|
+
interface: {
|
|
103
|
+
type: AXPWidgetsList.Editors.DateTimeBox,
|
|
104
|
+
options: { readonly: true },
|
|
105
|
+
},
|
|
106
|
+
},
|
|
107
|
+
options: {
|
|
108
|
+
sort: { enabled: true },
|
|
109
|
+
},
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
name: 'title',
|
|
113
|
+
title: '@general:terms.common.title',
|
|
114
|
+
description: 'Promotion title',
|
|
115
|
+
groupId: 'promotion',
|
|
116
|
+
options: {
|
|
117
|
+
filter: { advance: { enabled: true }, inline: { enabled: true } },
|
|
118
|
+
sort: { enabled: true },
|
|
119
|
+
},
|
|
120
|
+
schema: {
|
|
121
|
+
dataType: 'string',
|
|
122
|
+
interface: {
|
|
123
|
+
type: AXPWidgetsList.Editors.TextBox,
|
|
124
|
+
options: { maxLength: 100 },
|
|
125
|
+
},
|
|
126
|
+
},
|
|
127
|
+
validations: [{ rule: 'required' }],
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
name: 'body',
|
|
131
|
+
title: `@${i18n}:promotions.entities.promotion.fields.body.title`,
|
|
132
|
+
description: 'Promotion body content',
|
|
133
|
+
groupId: 'promotion',
|
|
134
|
+
schema: {
|
|
135
|
+
dataType: 'string',
|
|
136
|
+
interface: {
|
|
137
|
+
type: AXPWidgetsList.Editors.RichText,
|
|
138
|
+
},
|
|
139
|
+
nullable: true,
|
|
140
|
+
},
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
name: 'contentType',
|
|
144
|
+
title: `@${i18n}:promotions.entities.promotion.fields.content-type.title`,
|
|
145
|
+
description: 'Type of content (Media or Text)',
|
|
146
|
+
groupId: 'promotion',
|
|
147
|
+
schema: {
|
|
148
|
+
dataType: 'object',
|
|
149
|
+
nullable: true,
|
|
150
|
+
interface: {
|
|
151
|
+
type: AXPWidgetsList.Editors.SelectBox,
|
|
152
|
+
options: {
|
|
153
|
+
valueField: 'name',
|
|
154
|
+
textField: 'title',
|
|
155
|
+
dataSource: [
|
|
156
|
+
{ title: 'Media', name: 'media' },
|
|
157
|
+
{ title: 'Text', name: 'text' },
|
|
158
|
+
],
|
|
159
|
+
direction: 'horizontal',
|
|
160
|
+
multiple: false,
|
|
161
|
+
},
|
|
162
|
+
},
|
|
163
|
+
},
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
name: 'shape',
|
|
167
|
+
title: `@${i18n}:promotions.entities.promotion.fields.shape.title`,
|
|
168
|
+
description: 'Display shape for media promotions',
|
|
169
|
+
groupId: 'promotion',
|
|
170
|
+
schema: {
|
|
171
|
+
dataType: 'object',
|
|
172
|
+
nullable: true,
|
|
173
|
+
interface: {
|
|
174
|
+
type: AXPWidgetsList.Editors.SelectBox,
|
|
175
|
+
options: {
|
|
176
|
+
valueField: 'name',
|
|
177
|
+
textField: 'title',
|
|
178
|
+
dataSource: [
|
|
179
|
+
{ title: 'Rectangle', name: 'rectangle' },
|
|
180
|
+
{ title: 'Circle', name: 'circle' },
|
|
181
|
+
],
|
|
182
|
+
direction: 'horizontal',
|
|
183
|
+
multiple: false,
|
|
184
|
+
},
|
|
185
|
+
},
|
|
186
|
+
},
|
|
187
|
+
},
|
|
188
|
+
{
|
|
189
|
+
name: 'placement',
|
|
190
|
+
title: `@${i18n}:promotions.entities.promotion.fields.placement.title`,
|
|
191
|
+
description: 'Where the promotion is displayed',
|
|
192
|
+
groupId: 'promotion',
|
|
193
|
+
options: {
|
|
194
|
+
filter: { advance: { enabled: true }, inline: { enabled: true } },
|
|
195
|
+
sort: { enabled: true },
|
|
196
|
+
},
|
|
197
|
+
schema: {
|
|
198
|
+
dataType: 'object',
|
|
199
|
+
nullable: true,
|
|
200
|
+
interface: {
|
|
201
|
+
type: AXPWidgetsList.Editors.SelectBox,
|
|
202
|
+
options: {
|
|
203
|
+
valueField: 'name',
|
|
204
|
+
textField: 'title',
|
|
205
|
+
dataSource: [
|
|
206
|
+
{ title: 'Side Menu Footer', name: 'side-menu-footer', options: [] },
|
|
207
|
+
{ title: 'Side Menu Header', name: 'side-menu-header', options: [] },
|
|
208
|
+
],
|
|
209
|
+
direction: 'horizontal',
|
|
210
|
+
multiple: false,
|
|
211
|
+
},
|
|
212
|
+
},
|
|
213
|
+
},
|
|
214
|
+
},
|
|
215
|
+
],
|
|
216
|
+
columns: [{ name: 'title' }, { name: 'placement' }, { name: 'createdAt' }],
|
|
217
|
+
interfaces: {
|
|
218
|
+
master: {
|
|
219
|
+
create: {
|
|
220
|
+
sections: [{ id: 'promotion' }],
|
|
221
|
+
properties: [
|
|
222
|
+
{ name: 'title', layout: { positions: { lg: { colSpan: 6, order: 1 } } } },
|
|
223
|
+
{ name: 'body', layout: { positions: { lg: { colSpan: 12, order: 5 } } } },
|
|
224
|
+
{ name: 'contentType', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },
|
|
225
|
+
{ name: 'shape', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },
|
|
226
|
+
{ name: 'placement', layout: { positions: { lg: { colSpan: 6, order: 4 } } } },
|
|
227
|
+
],
|
|
228
|
+
},
|
|
229
|
+
update: {
|
|
230
|
+
sections: [{ id: 'promotion' }],
|
|
231
|
+
properties: [
|
|
232
|
+
{ name: 'createdAt', layout: { positions: { lg: { colSpan: 6, order: 1 } } } },
|
|
233
|
+
{ name: 'title', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },
|
|
234
|
+
{ name: 'body', layout: { positions: { lg: { colSpan: 12, order: 6 } } } },
|
|
235
|
+
{ name: 'contentType', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },
|
|
236
|
+
{ name: 'shape', layout: { positions: { lg: { colSpan: 6, order: 4 } } } },
|
|
237
|
+
{ name: 'placement', layout: { positions: { lg: { colSpan: 6, order: 5 } } } },
|
|
238
|
+
],
|
|
239
|
+
},
|
|
240
|
+
single: {
|
|
241
|
+
title: '{{title}}',
|
|
242
|
+
sections: [{ id: 'promotion' }],
|
|
243
|
+
properties: [
|
|
244
|
+
{ name: 'createdAt', layout: { positions: { lg: { colSpan: 6, order: 1 } } } },
|
|
245
|
+
{ name: 'title', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },
|
|
246
|
+
{ name: 'body', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },
|
|
247
|
+
{ name: 'contentType', layout: { positions: { lg: { colSpan: 4, order: 4 } } } },
|
|
248
|
+
{ name: 'shape', layout: { positions: { lg: { colSpan: 4, order: 5 } } } },
|
|
249
|
+
{ name: 'placement', layout: { positions: { lg: { colSpan: 4, order: 6 } } } },
|
|
250
|
+
],
|
|
251
|
+
actions: [
|
|
252
|
+
{ ...entityMasterViewAction(), default: true },
|
|
253
|
+
entityMasterDeleteAction(),
|
|
254
|
+
],
|
|
255
|
+
},
|
|
256
|
+
list: {
|
|
257
|
+
title: RootConfig.entities.promotion.titlePlural,
|
|
258
|
+
actions: [...entityMasterCrudActions()],
|
|
259
|
+
views: [
|
|
260
|
+
createAllQueryView({
|
|
261
|
+
sorts: [
|
|
262
|
+
{ name: 'title', dir: 'asc' },
|
|
263
|
+
{ name: 'createdAt', dir: 'desc' },
|
|
264
|
+
],
|
|
265
|
+
}),
|
|
266
|
+
createQueryView('media', `@${i18n}:promotions.terms.media`, true, {
|
|
267
|
+
columns: [],
|
|
268
|
+
conditions: [
|
|
269
|
+
{
|
|
270
|
+
name: 'contentType.name',
|
|
271
|
+
operator: { type: 'equal' },
|
|
272
|
+
value: 'media',
|
|
273
|
+
},
|
|
274
|
+
],
|
|
275
|
+
sorts: [],
|
|
276
|
+
}),
|
|
277
|
+
createQueryView('text', `@${i18n}:promotions.terms.text`, true, {
|
|
278
|
+
columns: [],
|
|
279
|
+
conditions: [
|
|
280
|
+
{
|
|
281
|
+
name: 'contentType.name',
|
|
282
|
+
operator: { type: 'equal' },
|
|
283
|
+
value: 'text',
|
|
284
|
+
},
|
|
285
|
+
],
|
|
286
|
+
sorts: [],
|
|
287
|
+
}),
|
|
288
|
+
],
|
|
289
|
+
},
|
|
290
|
+
},
|
|
291
|
+
},
|
|
292
|
+
};
|
|
293
|
+
return entityDef;
|
|
294
|
+
}
|
|
295
|
+
//#endregion
|
|
296
|
+
|
|
297
|
+
/**
|
|
298
|
+
* Generated bundle index. Do not edit.
|
|
299
|
+
*/
|
|
300
|
+
|
|
301
|
+
export { promotionEntityFactory };
|
|
302
|
+
//# sourceMappingURL=acorex-platform-module-content-management-client-contracts-entities-promotion.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"acorex-platform-module-content-management-client-contracts-entities-promotion.mjs","sources":["../../../../libs/modules/content-management/contracts/src/root-config.ts","../../../../libs/modules/content-management/contracts/src/entities/promotion/promotion.entity.ts","../../../../libs/modules/content-management/contracts/src/acorex-platform-module-content-management-client-contracts-entities-promotion.ts"],"sourcesContent":["const config = {\n i18n: 'content-management',\n};\nexport const RootConfig = {\n config,\n module: {\n module: 'ContentManagement',\n name: 'ContentManagement',\n title: `@${config.i18n}:module.title`,\n icon: 'fa-light fa-file-invoice',\n },\n entities: {\n promotion: {\n name: 'Promotion',\n title: `@${config.i18n}:promotions.entities.promotion.title`,\n titlePlural: `@${config.i18n}:promotions.entities.promotion.plural`,\n icon: 'fa-light fa-megaphone',\n },\n glossary: {\n name: 'Glossary', \n title: `@${config.i18n}:glossaries.entities.glossary.title`,\n titlePlural: `@${config.i18n}:glossaries.entities.glossary.plural`,\n icon: 'fa-light fa-file',\n },\n textTemplate: {\n name: 'TextTemplate',\n title: `@${config.i18n}:templates.entities.text-template.title`,\n titlePlural: `@${config.i18n}:templates.entities.text-template.plural`,\n icon: 'fa-light fa-envelope',\n },\n },\n} as const;\n","import { AXPSystemActionType, AXPWidgetsList } from '@acorex-platform/framework-shared/core';\nimport { AXPEntity, AXPEntityCommandScope, AXPEntityType, type AXPEntityV2, createAllQueryView, createQueryView, entityMasterCrudActions, entityMasterDeleteAction, entityMasterViewAction } from '@acorex-platform/framework-shared/entity';\n//#region ---- Imports ----\nimport { RootConfig } from '../../root-config';\n\n//#endregion\n\n//#region ---- Entity definition factory ----\n\n/**\n * Builds the Promotion entity definition (mock/runtime parity with former module JSON seed).\n */\nexport async function promotionEntityFactory(): Promise<AXPEntity | null> {\n const i18n = RootConfig.config.i18n;\n\n const entityDef: AXPEntityV2 = {\n version: 2,\n plugins: [\n { name: 'history' },\n { name: 'lock' },\n { name: 'compare' },\n { name: 'comments', options: { display: 'page' } },\n { name: 'distribution' },\n {\n name: 'status',\n options: {\n field: 'status',\n definition: 'common.status.task',\n defaultStatus: 'todo',\n showInCreate: false,\n },\n },\n { name: 'policy', options: { policy: 'test' } },\n { name: 'workflow-run' },\n { name: 'attachments', options: { } },\n { name: 'gallery', options: { display: 'page' } },\n ],\n module: RootConfig.module.name,\n aggregate: 'promotions',\n name: RootConfig.entities.promotion.name,\n type: AXPEntityType.AggregateRoot,\n title: RootConfig.entities.promotion.title,\n icon: RootConfig.entities.promotion.icon,\n formats: {\n individual: RootConfig.entities.promotion.title,\n plural: RootConfig.entities.promotion.titlePlural,\n searchResult: {\n title: '{{ title }}',\n description: RootConfig.module.title,\n },\n },\n groups: [{ id: 'promotion', title: 'Promotion' }],\n properties: [\n {\n name: 'id',\n title: 'ID',\n groupId: 'promotion',\n schema: {\n dataType: 'uuid',\n visible: false,\n nullable: false,\n readonly: true,\n unique: { enabled: true },\n },\n },\n {\n name: 'createdAt',\n title: '@general:terms.datetime.created-at',\n groupId: 'promotion',\n schema: {\n dataType: 'dateTime',\n nullable: true,\n readonly: true,\n interface: {\n type: AXPWidgetsList.Editors.DateTimeBox,\n options: { readonly: true },\n },\n },\n options: {\n sort: { enabled: true },\n },\n },\n {\n name: 'title',\n title: '@general:terms.common.title',\n description: 'Promotion title',\n groupId: 'promotion',\n options: {\n filter: { advance: { enabled: true }, inline: { enabled: true } },\n sort: { enabled: true },\n },\n schema: {\n dataType: 'string',\n interface: {\n type: AXPWidgetsList.Editors.TextBox,\n options: { maxLength: 100 },\n },\n },\n validations: [{ rule: 'required' }],\n },\n {\n name: 'body',\n title: `@${i18n}:promotions.entities.promotion.fields.body.title`,\n description: 'Promotion body content',\n groupId: 'promotion',\n schema: {\n dataType: 'string',\n interface: {\n type: AXPWidgetsList.Editors.RichText,\n },\n nullable: true,\n },\n },\n {\n name: 'contentType',\n title: `@${i18n}:promotions.entities.promotion.fields.content-type.title`,\n description: 'Type of content (Media or Text)',\n groupId: 'promotion',\n schema: {\n dataType: 'object',\n nullable: true,\n interface: {\n type: AXPWidgetsList.Editors.SelectBox,\n options: {\n valueField: 'name',\n textField: 'title',\n dataSource: [\n { title: 'Media', name: 'media' },\n { title: 'Text', name: 'text' },\n ],\n direction: 'horizontal',\n multiple: false,\n },\n },\n },\n },\n {\n name: 'shape',\n title: `@${i18n}:promotions.entities.promotion.fields.shape.title`,\n description: 'Display shape for media promotions',\n groupId: 'promotion',\n schema: {\n dataType: 'object',\n nullable: true,\n interface: {\n type: AXPWidgetsList.Editors.SelectBox,\n options: {\n valueField: 'name',\n textField: 'title',\n dataSource: [\n { title: 'Rectangle', name: 'rectangle' },\n { title: 'Circle', name: 'circle' },\n ],\n direction: 'horizontal',\n multiple: false,\n },\n },\n },\n },\n {\n name: 'placement',\n title: `@${i18n}:promotions.entities.promotion.fields.placement.title`,\n description: 'Where the promotion is displayed',\n groupId: 'promotion',\n options: {\n filter: { advance: { enabled: true }, inline: { enabled: true } },\n sort: { enabled: true },\n },\n schema: {\n dataType: 'object',\n nullable: true,\n interface: {\n type: AXPWidgetsList.Editors.SelectBox,\n options: {\n valueField: 'name',\n textField: 'title',\n dataSource: [\n { title: 'Side Menu Footer', name: 'side-menu-footer', options: [] },\n { title: 'Side Menu Header', name: 'side-menu-header', options: [] },\n ],\n direction: 'horizontal',\n multiple: false,\n },\n },\n },\n },\n ],\n columns: [{ name: 'title' }, { name: 'placement' }, { name: 'createdAt' }],\n interfaces: {\n master: {\n create: {\n sections: [{ id: 'promotion' }],\n properties: [\n { name: 'title', layout: { positions: { lg: { colSpan: 6, order: 1 } } } },\n { name: 'body', layout: { positions: { lg: { colSpan: 12, order: 5 } } } },\n { name: 'contentType', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },\n { name: 'shape', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },\n { name: 'placement', layout: { positions: { lg: { colSpan: 6, order: 4 } } } },\n ],\n },\n update: {\n sections: [{ id: 'promotion' }],\n properties: [\n { name: 'createdAt', layout: { positions: { lg: { colSpan: 6, order: 1 } } } },\n { name: 'title', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },\n { name: 'body', layout: { positions: { lg: { colSpan: 12, order: 6 } } } },\n { name: 'contentType', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },\n { name: 'shape', layout: { positions: { lg: { colSpan: 6, order: 4 } } } },\n { name: 'placement', layout: { positions: { lg: { colSpan: 6, order: 5 } } } },\n ],\n },\n single: {\n title: '{{title}}',\n sections: [{ id: 'promotion' }],\n properties: [\n { name: 'createdAt', layout: { positions: { lg: { colSpan: 6, order: 1 } } } },\n { name: 'title', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },\n { name: 'body', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },\n { name: 'contentType', layout: { positions: { lg: { colSpan: 4, order: 4 } } } },\n { name: 'shape', layout: { positions: { lg: { colSpan: 4, order: 5 } } } },\n { name: 'placement', layout: { positions: { lg: { colSpan: 4, order: 6 } } } },\n ],\n actions: [\n { ...entityMasterViewAction(), default: true },\n entityMasterDeleteAction(),\n ],\n },\n list: {\n title: RootConfig.entities.promotion.titlePlural,\n actions: [...entityMasterCrudActions()],\n views: [\n createAllQueryView({\n sorts: [\n { name: 'title', dir: 'asc' },\n { name: 'createdAt', dir: 'desc' },\n ],\n }),\n createQueryView('media', `@${i18n}:promotions.terms.media`, true, {\n columns: [],\n conditions: [\n {\n name: 'contentType.name',\n operator: { type: 'equal' },\n value: 'media',\n },\n ],\n sorts: [],\n }),\n createQueryView('text', `@${i18n}:promotions.terms.text`, true, {\n columns: [],\n conditions: [\n {\n name: 'contentType.name',\n operator: { type: 'equal' },\n value: 'text',\n },\n ],\n sorts: [],\n }),\n ],\n },\n },\n },\n } as AXPEntityV2;\n\n return entityDef;\n}\n\n//#endregion\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './entity-entry.promotion';\n"],"names":[],"mappings":";;;AAAA,MAAM,MAAM,GAAG;AACb,IAAA,IAAI,EAAE,oBAAoB;CAC3B;AACM,MAAM,UAAU,GAAG;IACxB,MAAM;AACN,IAAA,MAAM,EAAE;AACN,QAAA,MAAM,EAAE,mBAAmB;AAC3B,QAAA,IAAI,EAAE,mBAAmB;AACzB,QAAA,KAAK,EAAE,CAAA,CAAA,EAAI,MAAM,CAAC,IAAI,CAAA,aAAA,CAAe;AACrC,QAAA,IAAI,EAAE,0BAA0B;AACjC,KAAA;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V,gCAAA;AACE,oCAAA,IAAI,EAAE,kBAAkB;AACxB,oCAAA,QAAQ,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE;AAC3B,oCAAA,KAAK,EAAE,MAAM;AACd,iCAAA;AACF,6BAAA;AACD,4BAAA,KAAK,EAAE,EAAE;yBACV,CAAC;AACH,qBAAA;AACF,iBAAA;AACF,aAAA;AACF,SAAA;KACa;AAEhB,IAAA,OAAO,SAAS;AAClB;AAEA;;AC5QA;;AAEG;;"}
|
|
@@ -0,0 +1,264 @@
|
|
|
1
|
+
import { AXPWidgetsList } from '@acorex-platform/framework-shared/core';
|
|
2
|
+
import { createAllQueryView, entityMasterCrudActions, entityMasterRecordActions } from '@acorex-platform/framework-shared/entity';
|
|
3
|
+
|
|
4
|
+
const config = {
|
|
5
|
+
i18n: 'content-management',
|
|
6
|
+
};
|
|
7
|
+
const RootConfig = {
|
|
8
|
+
config,
|
|
9
|
+
module: {
|
|
10
|
+
module: 'ContentManagement',
|
|
11
|
+
name: 'ContentManagement',
|
|
12
|
+
title: `@${config.i18n}:module.title`,
|
|
13
|
+
icon: 'fa-light fa-file-invoice',
|
|
14
|
+
},
|
|
15
|
+
entities: {
|
|
16
|
+
promotion: {
|
|
17
|
+
name: 'Promotion',
|
|
18
|
+
title: `@${config.i18n}:promotions.entities.promotion.title`,
|
|
19
|
+
titlePlural: `@${config.i18n}:promotions.entities.promotion.plural`,
|
|
20
|
+
icon: 'fa-light fa-megaphone',
|
|
21
|
+
},
|
|
22
|
+
glossary: {
|
|
23
|
+
name: 'Glossary',
|
|
24
|
+
title: `@${config.i18n}:glossaries.entities.glossary.title`,
|
|
25
|
+
titlePlural: `@${config.i18n}:glossaries.entities.glossary.plural`,
|
|
26
|
+
icon: 'fa-light fa-file',
|
|
27
|
+
},
|
|
28
|
+
textTemplate: {
|
|
29
|
+
name: 'TextTemplate',
|
|
30
|
+
title: `@${config.i18n}:templates.entities.text-template.title`,
|
|
31
|
+
titlePlural: `@${config.i18n}:templates.entities.text-template.plural`,
|
|
32
|
+
icon: 'fa-light fa-envelope',
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
/** Template kind: content (leaf message) or master (layout shell with `[content]`). */
|
|
38
|
+
const AXM_TEXT_TEMPLATE_KIND = {
|
|
39
|
+
Content: 'content',
|
|
40
|
+
Master: 'master',
|
|
41
|
+
};
|
|
42
|
+
/** Print / PDF channel key on `channels` (rich body, no subject). */
|
|
43
|
+
const AXM_TEXT_TEMPLATE_PRINT_CHANNEL = 'print';
|
|
44
|
+
/** Reserved body slot for child template body injection (not a `{{token}}` variable). */
|
|
45
|
+
const AXM_TEXT_TEMPLATE_CONTENT_SLOT = '[content]';
|
|
46
|
+
/** Max `parentId` chain length (leaf → … → root), including the leaf. */
|
|
47
|
+
const AXM_TEXT_TEMPLATE_MAX_PARENT_DEPTH = 5;
|
|
48
|
+
//#endregion
|
|
49
|
+
|
|
50
|
+
//#endregion
|
|
51
|
+
async function textTemplateEntityFactory() {
|
|
52
|
+
const i18n = RootConfig.config.i18n;
|
|
53
|
+
const entityName = `${RootConfig.module.name}.${RootConfig.entities.textTemplate.name}`;
|
|
54
|
+
const entityDef = {
|
|
55
|
+
plugins: [
|
|
56
|
+
{ name: 'history' },
|
|
57
|
+
{ name: 'lock' },
|
|
58
|
+
{ name: 'compare' },
|
|
59
|
+
{ name: 'category' },
|
|
60
|
+
{ name: 'archive' },
|
|
61
|
+
],
|
|
62
|
+
module: RootConfig.module.name,
|
|
63
|
+
name: RootConfig.entities.textTemplate.name,
|
|
64
|
+
title: RootConfig.entities.textTemplate.title,
|
|
65
|
+
icon: RootConfig.entities.textTemplate.icon,
|
|
66
|
+
formats: {
|
|
67
|
+
individual: RootConfig.entities.textTemplate.title,
|
|
68
|
+
plural: RootConfig.entities.textTemplate.titlePlural,
|
|
69
|
+
searchResult: {
|
|
70
|
+
title: '{{ title }}',
|
|
71
|
+
description: RootConfig.module.title,
|
|
72
|
+
},
|
|
73
|
+
},
|
|
74
|
+
relatedEntities: [],
|
|
75
|
+
groups: [
|
|
76
|
+
{ id: 'basic-info', title: '@general:terms.interface.basic-info' },
|
|
77
|
+
{
|
|
78
|
+
id: 'template-content',
|
|
79
|
+
title: `@${i18n}:templates.entities.text-template.groups.template-content`,
|
|
80
|
+
},
|
|
81
|
+
],
|
|
82
|
+
properties: [
|
|
83
|
+
{
|
|
84
|
+
name: 'id',
|
|
85
|
+
title: 'ID',
|
|
86
|
+
schema: {
|
|
87
|
+
dataType: 'uuid',
|
|
88
|
+
visible: false,
|
|
89
|
+
nullable: false,
|
|
90
|
+
readonly: true,
|
|
91
|
+
unique: { enabled: true },
|
|
92
|
+
},
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
name: 'title',
|
|
96
|
+
title: '@general:terms.common.title',
|
|
97
|
+
groupId: 'basic-info',
|
|
98
|
+
options: {
|
|
99
|
+
filter: { advance: { enabled: true }, inline: { enabled: true } },
|
|
100
|
+
sort: { enabled: true },
|
|
101
|
+
},
|
|
102
|
+
schema: {
|
|
103
|
+
dataType: 'string',
|
|
104
|
+
interface: {
|
|
105
|
+
type: AXPWidgetsList.Editors.TextBox,
|
|
106
|
+
options: {
|
|
107
|
+
placeholder: '@content-management:templates.entities.text-template.fields.title.placeholder',
|
|
108
|
+
multiLanguage: true,
|
|
109
|
+
},
|
|
110
|
+
},
|
|
111
|
+
},
|
|
112
|
+
validations: [
|
|
113
|
+
{ rule: 'required' },
|
|
114
|
+
{ rule: 'minLength', options: { value: 3 } },
|
|
115
|
+
{ rule: 'maxLength', options: { value: 100 } },
|
|
116
|
+
],
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
name: 'kind',
|
|
120
|
+
title: `@${i18n}:templates.entities.text-template.fields.kind.title`,
|
|
121
|
+
groupId: 'basic-info',
|
|
122
|
+
options: {
|
|
123
|
+
filter: { advance: { enabled: true }, inline: { enabled: true } },
|
|
124
|
+
sort: { enabled: true },
|
|
125
|
+
},
|
|
126
|
+
schema: {
|
|
127
|
+
dataType: 'string',
|
|
128
|
+
defaultValue: AXM_TEXT_TEMPLATE_KIND.Content,
|
|
129
|
+
interface: {
|
|
130
|
+
type: AXPWidgetsList.Editors.SelectBox,
|
|
131
|
+
options: {
|
|
132
|
+
dataSource: [
|
|
133
|
+
{
|
|
134
|
+
value: AXM_TEXT_TEMPLATE_KIND.Content,
|
|
135
|
+
title: `@${i18n}:templates.entities.text-template.fields.kind.options.content`,
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
value: AXM_TEXT_TEMPLATE_KIND.Master,
|
|
139
|
+
title: `@${i18n}:templates.entities.text-template.fields.kind.options.master`,
|
|
140
|
+
},
|
|
141
|
+
],
|
|
142
|
+
valueField: 'value',
|
|
143
|
+
textField: 'title',
|
|
144
|
+
},
|
|
145
|
+
},
|
|
146
|
+
},
|
|
147
|
+
validations: [{ rule: 'required' }],
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
name: 'parentId',
|
|
151
|
+
title: `@${i18n}:templates.entities.text-template.fields.parent-id.title`,
|
|
152
|
+
groupId: 'basic-info',
|
|
153
|
+
options: {
|
|
154
|
+
filter: { advance: { enabled: true }, inline: { enabled: true } },
|
|
155
|
+
sort: { enabled: true },
|
|
156
|
+
},
|
|
157
|
+
schema: {
|
|
158
|
+
dataType: 'string',
|
|
159
|
+
nullable: true,
|
|
160
|
+
interface: {
|
|
161
|
+
type: AXPWidgetsList.Editors.LookupBox,
|
|
162
|
+
options: {
|
|
163
|
+
entity: entityName,
|
|
164
|
+
textField: 'title',
|
|
165
|
+
valueField: 'id',
|
|
166
|
+
look: 'select',
|
|
167
|
+
expose: [
|
|
168
|
+
{ source: 'id', target: 'parent.id' },
|
|
169
|
+
{ source: 'title', target: 'parent.title' },
|
|
170
|
+
],
|
|
171
|
+
filter: {
|
|
172
|
+
logic: 'and',
|
|
173
|
+
filters: [
|
|
174
|
+
{
|
|
175
|
+
field: 'kind',
|
|
176
|
+
operator: { type: 'equal' },
|
|
177
|
+
value: AXM_TEXT_TEMPLATE_KIND.Master,
|
|
178
|
+
},
|
|
179
|
+
],
|
|
180
|
+
},
|
|
181
|
+
},
|
|
182
|
+
},
|
|
183
|
+
},
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
name: 'parent',
|
|
187
|
+
title: `@${i18n}:templates.entities.text-template.fields.parent.title`,
|
|
188
|
+
schema: { dataType: 'object', visible: false, readonly: true },
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
name: 'channels',
|
|
192
|
+
title: '@content-management:templates.entities.text-template.fields.channels.title',
|
|
193
|
+
groupId: 'template-content',
|
|
194
|
+
schema: {
|
|
195
|
+
dataType: 'object',
|
|
196
|
+
interface: {
|
|
197
|
+
type: AXPWidgetsList.Editors.TemplateContentEditor,
|
|
198
|
+
},
|
|
199
|
+
},
|
|
200
|
+
validations: [{ rule: 'required' }],
|
|
201
|
+
},
|
|
202
|
+
],
|
|
203
|
+
columns: [{ name: 'title' }, { name: 'kind' }],
|
|
204
|
+
interfaces: {
|
|
205
|
+
master: {
|
|
206
|
+
create: {
|
|
207
|
+
sections: [
|
|
208
|
+
{ id: 'basic-info' },
|
|
209
|
+
{ id: 'template-content' },
|
|
210
|
+
],
|
|
211
|
+
properties: [
|
|
212
|
+
{ name: 'title', layout: { positions: { lg: { colSpan: 12, order: 1 } } } },
|
|
213
|
+
{ name: 'kind', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },
|
|
214
|
+
{ name: 'parentId', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },
|
|
215
|
+
{ name: 'channels', layout: { label: { visible: false }, positions: { lg: { colSpan: 12, order: 4 } } } },
|
|
216
|
+
],
|
|
217
|
+
},
|
|
218
|
+
update: {
|
|
219
|
+
sections: [
|
|
220
|
+
{ id: 'basic-info' },
|
|
221
|
+
{ id: 'template-content' },
|
|
222
|
+
],
|
|
223
|
+
properties: [
|
|
224
|
+
{ name: 'title', layout: { positions: { lg: { colSpan: 12, order: 1 } } } },
|
|
225
|
+
{ name: 'kind', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },
|
|
226
|
+
{ name: 'parentId', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },
|
|
227
|
+
{ name: 'channels', layout: { label: { visible: false }, positions: { lg: { colSpan: 12, order: 4 } } } },
|
|
228
|
+
],
|
|
229
|
+
},
|
|
230
|
+
single: {
|
|
231
|
+
title: '{{ title }}',
|
|
232
|
+
sections: [
|
|
233
|
+
{ id: 'basic-info' },
|
|
234
|
+
{ id: 'template-content' },
|
|
235
|
+
],
|
|
236
|
+
properties: [
|
|
237
|
+
{ name: 'title', layout: { positions: { lg: { colSpan: 12, order: 1 } } } },
|
|
238
|
+
{ name: 'kind', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },
|
|
239
|
+
{ name: 'parentId', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },
|
|
240
|
+
{ name: 'channels', layout: { label: { visible: false }, positions: { lg: { colSpan: 12, order: 4 } } } },
|
|
241
|
+
],
|
|
242
|
+
actions: [...entityMasterRecordActions()],
|
|
243
|
+
},
|
|
244
|
+
list: {
|
|
245
|
+
title: RootConfig.entities.textTemplate.titlePlural,
|
|
246
|
+
actions: [...entityMasterCrudActions()],
|
|
247
|
+
views: [
|
|
248
|
+
createAllQueryView({
|
|
249
|
+
sorts: [{ name: 'title', dir: 'asc' }],
|
|
250
|
+
}),
|
|
251
|
+
],
|
|
252
|
+
},
|
|
253
|
+
},
|
|
254
|
+
},
|
|
255
|
+
};
|
|
256
|
+
return entityDef;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
/**
|
|
260
|
+
* Generated bundle index. Do not edit.
|
|
261
|
+
*/
|
|
262
|
+
|
|
263
|
+
export { textTemplateEntityFactory };
|
|
264
|
+
//# sourceMappingURL=acorex-platform-module-content-management-client-contracts-entities-text-template.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"acorex-platform-module-content-management-client-contracts-entities-text-template.mjs","sources":["../../../../libs/modules/content-management/contracts/src/root-config.ts","../../../../libs/modules/content-management/contracts/src/entities/text-template/text-template.types.ts","../../../../libs/modules/content-management/contracts/src/entities/text-template/text-template.entity.ts","../../../../libs/modules/content-management/contracts/src/acorex-platform-module-content-management-client-contracts-entities-text-template.ts"],"sourcesContent":["const config = {\n i18n: 'content-management',\n};\nexport const RootConfig = {\n config,\n module: {\n module: 'ContentManagement',\n name: 'ContentManagement',\n title: `@${config.i18n}:module.title`,\n icon: 'fa-light fa-file-invoice',\n },\n entities: {\n promotion: {\n name: 'Promotion',\n title: `@${config.i18n}:promotions.entities.promotion.title`,\n titlePlural: `@${config.i18n}:promotions.entities.promotion.plural`,\n icon: 'fa-light fa-megaphone',\n },\n glossary: {\n name: 'Glossary', \n title: `@${config.i18n}:glossaries.entities.glossary.title`,\n titlePlural: `@${config.i18n}:glossaries.entities.glossary.plural`,\n icon: 'fa-light fa-file',\n },\n textTemplate: {\n name: 'TextTemplate',\n title: `@${config.i18n}:templates.entities.text-template.title`,\n titlePlural: `@${config.i18n}:templates.entities.text-template.plural`,\n icon: 'fa-light fa-envelope',\n },\n },\n} as const;\n","import { AXPCategoryListItem, AXPMultiLanguageString, type AXPPlatformScopeKey } from '@acorex-platform/framework-shared/core';\nimport { AXPEntityModel } from '@acorex-platform/framework-shared/entity';\n\n//#region ----- Types -----\n\n/** Stored value: { email: { subject?, body }, sms: { body }, ... } */\nexport interface AXMTextTemplateChannelsValue {\n [channelName: string]: {\n subject?: AXPMultiLanguageString;\n body: AXPMultiLanguageString;\n };\n}\n\nexport type AXMTextTemplateChannelEditorType = 'plain' | 'rich';\n\nexport interface AXMTextTemplateChannelConfigureSettings {\n /** Settings definition section name (e.g. `smtp-settings`). */\n section: string;\n /** Optional parent group when section names are not unique. */\n group?: string;\n scope: AXPPlatformScopeKey;\n}\n\nexport interface AXMTextTemplateChannelDefinition {\n name: string;\n title: string;\n type: AXMTextTemplateChannelEditorType;\n hasSubject?: boolean;\n communicationChannelKey?: string;\n requiredSettingKeys?: string[];\n configureSettings?: AXMTextTemplateChannelConfigureSettings;\n notConfiguredMessageKey?: string;\n}\n\nexport interface AXMTextTemplateChannelDefinitionProvider {\n getChannels(): AXMTextTemplateChannelDefinition[];\n}\n\n/** Template kind: content (leaf message) or master (layout shell with `[content]`). */\nexport const AXM_TEXT_TEMPLATE_KIND = {\n Content: 'content',\n Master: 'master',\n} as const;\n\nexport type AXMTextTemplateKind = (typeof AXM_TEXT_TEMPLATE_KIND)[keyof typeof AXM_TEXT_TEMPLATE_KIND];\n\n/** Print / PDF channel key on `channels` (rich body, no subject). */\nexport const AXM_TEXT_TEMPLATE_PRINT_CHANNEL = 'print' as const;\n\n/** Reserved body slot for child template body injection (not a `{{token}}` variable). */\nexport const AXM_TEXT_TEMPLATE_CONTENT_SLOT = '[content]' as const;\n\n/** Max `parentId` chain length (leaf → … → root), including the leaf. */\nexport const AXM_TEXT_TEMPLATE_MAX_PARENT_DEPTH = 5;\n\nexport interface AXMTextTemplateEntityModel extends AXPEntityModel<string> {\n title?: AXPMultiLanguageString;\n /** `content` (default) or `master` layout template. */\n kind?: AXMTextTemplateKind;\n /** Optional parent master template id (multi-level nesting supported). */\n parentId?: string | null;\n /** Join snapshot for `parentId` lookup. */\n parent?: { id?: string; title?: AXPMultiLanguageString | string } | null;\n channels?: AXMTextTemplateChannelsValue;\n categoryIds?: string[];\n categories?: AXPCategoryListItem[];\n}\n\n//#endregion\n","import { AXPWidgetsList } from '@acorex-platform/framework-shared/core';\nimport { AXPEntity, createAllQueryView, entityMasterCrudActions, entityMasterRecordActions } from '@acorex-platform/framework-shared/entity';\n//#region ----- Imports -----\nimport { RootConfig } from '../../root-config';\nimport { AXM_TEXT_TEMPLATE_KIND } from './text-template.types';\n\n\n//#endregion\n\nexport async function textTemplateEntityFactory(): Promise<AXPEntity | null> {\n const i18n = RootConfig.config.i18n;\n const entityName = `${RootConfig.module.name}.${RootConfig.entities.textTemplate.name}`;\n\n const entityDef: AXPEntity = {\n plugins: [\n { name: 'history' },\n { name: 'lock' },\n { name: 'compare' },\n { name: 'category' },\n { name: 'archive' },\n ],\n module: RootConfig.module.name,\n name: RootConfig.entities.textTemplate.name,\n title: RootConfig.entities.textTemplate.title,\n icon: RootConfig.entities.textTemplate.icon,\n formats: {\n individual: RootConfig.entities.textTemplate.title,\n plural: RootConfig.entities.textTemplate.titlePlural,\n searchResult: {\n title: '{{ title }}',\n description: RootConfig.module.title,\n },\n },\n relatedEntities: [],\n groups: [\n { id: 'basic-info', title: '@general:terms.interface.basic-info' },\n {\n id: 'template-content',\n title: `@${i18n}:templates.entities.text-template.groups.template-content`,\n },\n ],\n properties: [\n {\n name: 'id',\n title: 'ID',\n schema: {\n dataType: 'uuid',\n visible: false,\n nullable: false,\n readonly: true,\n unique: { enabled: true },\n },\n },\n {\n name: 'title',\n title: '@general:terms.common.title',\n groupId: 'basic-info',\n options: {\n filter: { advance: { enabled: true }, inline: { enabled: true } },\n sort: { enabled: true },\n },\n schema: {\n dataType: 'string',\n interface: {\n type: AXPWidgetsList.Editors.TextBox,\n options: {\n placeholder: '@content-management:templates.entities.text-template.fields.title.placeholder',\n multiLanguage: true,\n },\n },\n },\n validations: [\n { rule: 'required' },\n { rule: 'minLength', options: { value: 3 } },\n { rule: 'maxLength', options: { value: 100 } },\n ],\n },\n {\n name: 'kind',\n title: `@${i18n}:templates.entities.text-template.fields.kind.title`,\n groupId: 'basic-info',\n options: {\n filter: { advance: { enabled: true }, inline: { enabled: true } },\n sort: { enabled: true },\n },\n schema: {\n dataType: 'string',\n defaultValue: AXM_TEXT_TEMPLATE_KIND.Content,\n interface: {\n type: AXPWidgetsList.Editors.SelectBox,\n options: {\n dataSource: [\n {\n value: AXM_TEXT_TEMPLATE_KIND.Content,\n title: `@${i18n}:templates.entities.text-template.fields.kind.options.content`,\n },\n {\n value: AXM_TEXT_TEMPLATE_KIND.Master,\n title: `@${i18n}:templates.entities.text-template.fields.kind.options.master`,\n },\n ],\n valueField: 'value',\n textField: 'title',\n },\n },\n },\n validations: [{ rule: 'required' }],\n },\n {\n name: 'parentId',\n title: `@${i18n}:templates.entities.text-template.fields.parent-id.title`,\n groupId: 'basic-info',\n options: {\n filter: { advance: { enabled: true }, inline: { enabled: true } },\n sort: { enabled: true },\n },\n schema: {\n dataType: 'string',\n nullable: true,\n interface: {\n type: AXPWidgetsList.Editors.LookupBox,\n options: {\n entity: entityName,\n textField: 'title',\n valueField: 'id',\n look: 'select',\n expose: [\n { source: 'id', target: 'parent.id' },\n { source: 'title', target: 'parent.title' },\n ],\n filter: {\n logic: 'and',\n filters: [\n {\n field: 'kind',\n operator: { type: 'equal' },\n value: AXM_TEXT_TEMPLATE_KIND.Master,\n },\n ],\n },\n },\n },\n },\n },\n {\n name: 'parent',\n title: `@${i18n}:templates.entities.text-template.fields.parent.title`,\n schema: { dataType: 'object', visible: false, readonly: true },\n },\n {\n name: 'channels',\n title: '@content-management:templates.entities.text-template.fields.channels.title',\n groupId: 'template-content',\n schema: {\n dataType: 'object',\n interface: {\n type: AXPWidgetsList.Editors.TemplateContentEditor,\n },\n },\n validations: [{ rule: 'required' }],\n },\n ],\n columns: [{ name: 'title' }, { name: 'kind' }],\n interfaces: {\n master: {\n create: {\n sections: [\n { id: 'basic-info' },\n { id: 'template-content' },\n ],\n properties: [\n { name: 'title', layout: { positions: { lg: { colSpan: 12, order: 1 } } } },\n { name: 'kind', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },\n { name: 'parentId', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },\n { name: 'channels', layout: { label: { visible: false }, positions: { lg: { colSpan: 12, order: 4 } } } },\n ],\n },\n update: {\n sections: [\n { id: 'basic-info' },\n { id: 'template-content' },\n ],\n properties: [\n { name: 'title', layout: { positions: { lg: { colSpan: 12, order: 1 } } } },\n { name: 'kind', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },\n { name: 'parentId', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },\n { name: 'channels', layout: { label: { visible: false }, positions: { lg: { colSpan: 12, order: 4 } } } },\n ],\n },\n single: {\n title: '{{ title }}',\n sections: [\n { id: 'basic-info' },\n { id: 'template-content' },\n ],\n properties: [\n { name: 'title', layout: { positions: { lg: { colSpan: 12, order: 1 } } } },\n { name: 'kind', layout: { positions: { lg: { colSpan: 6, order: 2 } } } },\n { name: 'parentId', layout: { positions: { lg: { colSpan: 6, order: 3 } } } },\n { name: 'channels', layout: { label: { visible: false }, positions: { lg: { colSpan: 12, order: 4 } } } },\n ],\n actions: [...entityMasterRecordActions()],\n },\n list: {\n title: RootConfig.entities.textTemplate.titlePlural,\n actions: [...entityMasterCrudActions()],\n views: [\n createAllQueryView({\n sorts: [{ name: 'title', dir: 'asc' }],\n }),\n ],\n },\n },\n },\n };\n\n return entityDef;\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './entity-entry.text-template';\n"],"names":[],"mappings":";;;AAAA,MAAM,MAAM,GAAG;AACb,IAAA,IAAI,EAAE,oBAAoB;CAC3B;AACM,MAAM,UAAU,GAAG;IACxB,MAAM;AACN,IAAA,MAAM,EAAE;AACN,QAAA,MAAM,EAAE,mBAAmB;AAC3B,QAAA,IAAI,EAAE,mBAAmB;AACzB,QAAA,KAAK,EAAE,CAAA,CAAA,EAAI,MAAM,CAAC,IAAI,CAAA,aAAA,CAAe;AACrC,QAAA,IAAI,EAAE,0BAA0B;AACjC,KAAA;AACD,IAAA,QAAQ,EAAE;AACR,QAAA,SAAS,EAAE;AACT,YAAA,IAAI,EAAE,WAAW;AACjB,YAAA,KAAK,EAAE,CAAA,CAAA,EAAI,MAAM,CAAC,IAAI,CAAA,oCAAA,CAAsC;AAC5D,YAAA,WAAW,EAAE,CAAA,CAAA,EAAI,MAAM,CAAC,IAAI,CAAA,qCAAA,CAAuC;AACnE,YAAA,IAAI,EAAE,uBAAuB;AAC9B,SAAA;AACD,QAAA,QAAQ,EAAE;AACR,YAAA,IAAI,EAAE,UAAU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