@sap/ux-specification 1.142.8 → 1.142.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +46 -4
- package/dist/documentation/runDocu-min.mjs +28 -0
- package/dist/documentation/{runDocu-min.js.map → runDocu-min.mjs.map} +2 -2
- package/dist/documentation/v2/v2-AnalyticalListPage.html +4 -4
- package/dist/documentation/v2/v2-ApplicationV2.html +4 -4
- package/dist/documentation/v2/v2-ListReport.html +4 -4
- package/dist/documentation/v2/v2-ListReportNew.html +4 -4
- package/dist/documentation/v2/v2-ObjectPage.html +4 -4
- package/dist/documentation/v2/v2-OverviewPage.html +4 -4
- package/dist/documentation/v4/v4-ApplicationV4.html +4 -4
- package/dist/documentation/v4/v4-BuildingBlocks.html +4 -4
- package/dist/documentation/v4/v4-FreestylePage.html +4 -4
- package/dist/documentation/v4/v4-ListReport.html +4 -4
- package/dist/documentation/v4/v4-ObjectPage.html +4 -4
- package/dist/index-min.mjs +1364 -0
- package/dist/index-min.mjs.map +7 -0
- package/dist/schemas/v4/ApplicationV4.json +37 -0
- package/dist/schemas/v4/BuildingBlocksConfig.json +0 -1
- package/dist/schemas/v4/ListReportConfig.json +40 -30
- package/dist/schemas/v4/ObjectPageConfig.json +83 -1
- package/dist/specification/package.json +22 -15
- package/dist/specification/scripts/macros/corrections.d.ts.map +1 -1
- package/dist/specification/scripts/macros/corrections.js +0 -6
- package/dist/specification/scripts/macros/corrections.js.map +1 -1
- package/dist/specification/src/api.d.ts.map +1 -1
- package/dist/specification/src/api.js +6 -6
- package/dist/specification/src/api.js.map +1 -1
- package/dist/specification/src/ftfs/ftfs.d.ts.map +1 -1
- package/dist/specification/src/ftfs/ftfs.js +25 -1
- package/dist/specification/src/ftfs/ftfs.js.map +1 -1
- package/dist/specification/src/i18n/i18n.js +35 -2
- package/dist/specification/src/i18n/i18n.js.map +1 -1
- package/dist/specification/src/index.d.ts +1 -0
- package/dist/specification/src/index.d.ts.map +1 -1
- package/dist/specification/src/index.js +4 -0
- package/dist/specification/src/index.js.map +1 -1
- package/dist/specification/src/sync/common/DataFieldStrategy.d.ts +11 -3
- package/dist/specification/src/sync/common/DataFieldStrategy.d.ts.map +1 -1
- package/dist/specification/src/sync/common/DataFieldStrategy.js +35 -7
- package/dist/specification/src/sync/common/DataFieldStrategy.js.map +1 -1
- package/dist/specification/src/sync/common/decoration/decorator-paths.d.ts +37 -3
- package/dist/specification/src/sync/common/decoration/decorator-paths.d.ts.map +1 -1
- package/dist/specification/src/sync/common/decoration/decorator-paths.js +18 -1
- package/dist/specification/src/sync/common/decoration/decorator-paths.js.map +1 -1
- package/dist/specification/src/sync/common/decoration/decorators.d.ts +8 -5
- package/dist/specification/src/sync/common/decoration/decorators.d.ts.map +1 -1
- package/dist/specification/src/sync/common/decoration/decorators.js +4 -1
- package/dist/specification/src/sync/common/decoration/decorators.js.map +1 -1
- package/dist/specification/src/sync/common/decoration/steps/Enums.d.ts.map +1 -1
- package/dist/specification/src/sync/common/decoration/steps/Enums.js +47 -8
- package/dist/specification/src/sync/common/decoration/steps/Enums.js.map +1 -1
- package/dist/specification/src/sync/common/i18n.json +3 -1
- package/dist/specification/src/sync/v4/application.d.ts +2 -0
- package/dist/specification/src/sync/v4/application.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/application.js +21 -0
- package/dist/specification/src/sync/v4/application.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ObjectPageCustomSection.d.ts +13 -0
- package/dist/specification/src/sync/v4/export/controls/ObjectPageCustomSection.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ObjectPageCustomSection.js +92 -1
- package/dist/specification/src/sync/v4/export/controls/ObjectPageCustomSection.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ObjectPageTable.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ObjectPageTable.js +25 -11
- package/dist/specification/src/sync/v4/export/controls/ObjectPageTable.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/Table.d.ts +2 -2
- package/dist/specification/src/sync/v4/export/controls/Table.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/Table.js +21 -9
- package/dist/specification/src/sync/v4/export/controls/Table.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ToolBar.d.ts +8 -1
- package/dist/specification/src/sync/v4/export/controls/ToolBar.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ToolBar.js +7 -1
- package/dist/specification/src/sync/v4/export/controls/ToolBar.js.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ToolBarAction.d.ts +4 -0
- package/dist/specification/src/sync/v4/export/controls/ToolBarAction.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/controls/ToolBarAction.js +24 -1
- package/dist/specification/src/sync/v4/export/controls/ToolBarAction.js.map +1 -1
- package/dist/specification/src/sync/v4/export/export.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/export.js +21 -6
- package/dist/specification/src/sync/v4/export/export.js.map +1 -1
- package/dist/specification/src/sync/v4/export/factory.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/factory.js +1 -0
- package/dist/specification/src/sync/v4/export/factory.js.map +1 -1
- package/dist/specification/src/sync/v4/export/pages/ListReport.d.ts +2 -2
- package/dist/specification/src/sync/v4/export/pages/ListReport.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/export/pages/ListReport.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/actions.d.ts +2 -2
- package/dist/specification/src/sync/v4/generate/actions.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/actions.js +4 -2
- package/dist/specification/src/sync/v4/generate/actions.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/annotations.js +4 -4
- package/dist/specification/src/sync/v4/generate/fpm-custom-page/annotations.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/generate.d.ts +4 -2
- package/dist/specification/src/sync/v4/generate/generate.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/generate.js +8 -4
- package/dist/specification/src/sync/v4/generate/generate.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/list-report/ListReportUtils.d.ts +3 -3
- package/dist/specification/src/sync/v4/generate/list-report/ListReportUtils.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/list-report/ListReportUtils.js +12 -13
- package/dist/specification/src/sync/v4/generate/list-report/ListReportUtils.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/list-report/listReport.d.ts +27 -13
- package/dist/specification/src/sync/v4/generate/list-report/listReport.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/list-report/listReport.js +196 -93
- package/dist/specification/src/sync/v4/generate/list-report/listReport.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/objectPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/objectPage.js +106 -6
- package/dist/specification/src/sync/v4/generate/objectPage.js.map +1 -1
- package/dist/specification/src/sync/v4/generate/utils/inlineEdit.d.ts +3 -3
- package/dist/specification/src/sync/v4/generate/utils/inlineEdit.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/generate/utils/inlineEdit.js +3 -3
- package/dist/specification/src/sync/v4/generate/utils/inlineEdit.js.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/listReport.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/listReport.js +66 -3
- package/dist/specification/src/sync/v4/import/pages/listReport.js.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/objectPage.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/import/pages/objectPage.js +14 -0
- package/dist/specification/src/sync/v4/import/pages/objectPage.js.map +1 -1
- package/dist/specification/src/sync/v4/sync-rules/Page.d.ts +6 -0
- package/dist/specification/src/sync/v4/sync-rules/Page.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/sync-rules/Page.js +8 -0
- package/dist/specification/src/sync/v4/sync-rules/Page.js.map +1 -1
- package/dist/specification/src/sync/v4/utils/utils.d.ts +186 -51
- package/dist/specification/src/sync/v4/utils/utils.d.ts.map +1 -1
- package/dist/specification/src/sync/v4/utils/utils.js +363 -90
- package/dist/specification/src/sync/v4/utils/utils.js.map +1 -1
- package/dist/templates/action/manifest.action-menu.json +10 -0
- package/dist/templates/action/manifest.action.json +13 -0
- package/dist/templates/app/Component.js +13 -0
- package/dist/templates/app/Component.ts +11 -0
- package/dist/templates/building-block/action/View.xml +30 -0
- package/dist/templates/building-block/chart/View.xml +9 -0
- package/dist/templates/building-block/common/manifest.json +7 -0
- package/dist/templates/building-block/custom-column/View.xml +5 -0
- package/dist/templates/building-block/custom-filter-field/View.xml +12 -0
- package/dist/templates/building-block/custom-form-field/View.xml +12 -0
- package/dist/templates/building-block/field/View.xml +8 -0
- package/dist/templates/building-block/filter-bar/View.xml +10 -0
- package/dist/templates/building-block/form/View.xml +4 -0
- package/dist/templates/building-block/page/View.xml +5 -0
- package/dist/templates/building-block/rich-text-editor/View.xml +3 -0
- package/dist/templates/building-block/rich-text-editor-button-groups/View.xml +18 -0
- package/dist/templates/building-block/table/View.xml +19 -0
- package/dist/templates/column/1.84/manifest.json +28 -0
- package/dist/templates/column/1.85/manifest.json +31 -0
- package/dist/templates/column/1.86/manifest.json +43 -0
- package/dist/templates/common/EventHandler.js +25 -0
- package/dist/templates/common/EventHandler.ts +28 -0
- package/dist/templates/common/Fragment.xml +3 -0
- package/dist/templates/common/FragmentWithForm.xml +7 -0
- package/dist/templates/common/FragmentWithVBox.xml +5 -0
- package/dist/templates/common/sap.fe.d.ts +43 -0
- package/dist/templates/controller-extension/Controller.js +18 -0
- package/dist/templates/controller-extension/Controller.ts +20 -0
- package/dist/templates/controller-extension/ControllerExtension.d.ts +11 -0
- package/dist/templates/controller-extension/manifest.json +14 -0
- package/dist/templates/field/manifest.json +32 -0
- package/dist/templates/filter/Controller.js +21 -0
- package/dist/templates/filter/Controller.ts +24 -0
- package/dist/templates/filter/fragment.xml +15 -0
- package/dist/templates/filter/manifest.json +12 -0
- package/dist/templates/header-section/1.85/manifest.json +43 -0
- package/dist/templates/header-section/1.86/manifest.json +45 -0
- package/dist/templates/page/custom/1.84/ext/Controller.js +45 -0
- package/dist/templates/page/custom/1.84/ext/Controller.ts +42 -0
- package/dist/templates/page/custom/1.84/ext/View.xml +6 -0
- package/dist/templates/page/custom/1.84/i18n/i18n.properties +2 -0
- package/dist/templates/page/custom/1.84/manifest.json +32 -0
- package/dist/templates/page/custom/1.94/ext/Controller.js +45 -0
- package/dist/templates/page/custom/1.94/ext/Controller.ts +42 -0
- package/dist/templates/page/custom/1.94/ext/View.xml +6 -0
- package/dist/templates/page/custom/1.94/i18n/i18n.properties +2 -0
- package/dist/templates/page/custom/1.94/manifest.json +33 -0
- package/dist/templates/page/custom/i18n/i18n.properties +2 -0
- package/dist/templates/page/list/manifest.json +20 -0
- package/dist/templates/page/object/manifest.json +33 -0
- package/dist/templates/section/1.85/manifest.json +33 -0
- package/dist/templates/section/1.86/manifest.json +32 -0
- package/dist/templates/subsection/1.85/manifest.json +37 -0
- package/dist/templates/subsection/1.86/manifest.json +36 -0
- package/dist/templates/view/ext/CustomViewWithTable.xml +3 -0
- package/dist/templates/view/manifest.json +41 -0
- package/dist/types/src/apiTypes.d.ts +3 -0
- package/dist/types/src/apiTypes.d.ts.map +1 -1
- package/dist/types/src/apiTypes.js.map +1 -1
- package/dist/types/src/common/types.d.ts +5 -1
- package/dist/types/src/common/types.d.ts.map +1 -1
- package/dist/types/src/common/types.js +4 -0
- package/dist/types/src/common/types.js.map +1 -1
- package/dist/types/src/v4/application.d.ts +13 -1
- package/dist/types/src/v4/application.d.ts.map +1 -1
- package/dist/types/src/v4/application.js.map +1 -1
- package/dist/types/src/v4/controls/ObjectPageSection.d.ts +52 -1
- package/dist/types/src/v4/controls/ObjectPageSection.d.ts.map +1 -1
- package/dist/types/src/v4/controls/ToolBar.d.ts +1 -24
- package/dist/types/src/v4/controls/ToolBar.d.ts.map +1 -1
- package/dist/types/src/v4/webapp/manifest/sapUi5.d.ts +9 -0
- package/dist/types/src/v4/webapp/manifest/sapUi5.d.ts.map +1 -1
- package/dist/types/src/v4/webapp/manifest/sapUi5.js.map +1 -1
- package/dist/types/src/v4/webapp/manifest/sapUiPageV4.d.ts +23 -3
- package/dist/types/src/v4/webapp/manifest/sapUiPageV4.d.ts.map +1 -1
- package/dist/types/src/v4/webapp/manifest/sapUiPageV4.js.map +1 -1
- package/package.json +22 -15
- package/dist/documentation/runDocu-min.js +0 -28
- package/dist/index-min.js +0 -647
- package/dist/index-min.js.map +0 -7
|
@@ -198,44 +198,125 @@ function applyCustomFilterFields(appSchema, selectionFieldsDefinition, v4Page) {
|
|
|
198
198
|
}
|
|
199
199
|
}
|
|
200
200
|
/**
|
|
201
|
+
* Defines annotation-based actions for a chart toolbar by reading the UI.Chart Actions collection
|
|
202
|
+
* and adding definition for each action (DataFieldForAction, DataFieldForActionGroup, DataFieldForIntentBasedNavigation).
|
|
201
203
|
*
|
|
202
204
|
* @param appSchema - The app JSON schema to be updated
|
|
203
205
|
* @param schemaIdForActions - The schema ID for the actions to be defined
|
|
204
206
|
* @param annotations - The UI annotations for the given entity type
|
|
205
|
-
* @param targetAnnotation - The target annotation for
|
|
207
|
+
* @param targetAnnotation - The target annotation for a chart
|
|
206
208
|
* @param entityType - The entity type as part of the AVT ConvertedMetadata
|
|
209
|
+
* @param oDataServiceAVT - Combined service metadata, as returned by annotation vocabularies tools.
|
|
207
210
|
*/
|
|
208
|
-
function
|
|
209
|
-
|
|
210
|
-
const actions = appSchema.definitions[schemaIdForActions];
|
|
211
|
+
function defineChartAnnotationActions(appSchema, schemaIdForActions, annotations, targetAnnotation, entityType, oDataServiceAVT) {
|
|
212
|
+
const actions = appSchema?.definitions?.[schemaIdForActions];
|
|
211
213
|
actions.properties = {};
|
|
212
214
|
actions.additionalProperties = false;
|
|
213
215
|
const chartAnnotation = annotations[targetAnnotation?.split(`${ux_specification_types_1.UIVOCABULARY}.`)[1]];
|
|
214
216
|
if (chartAnnotation && chartAnnotation.Actions) {
|
|
215
217
|
let i = 0;
|
|
216
218
|
chartAnnotation.Actions.forEach((actionRecord) => {
|
|
217
|
-
const
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
219
|
+
const strategy = common_1.dataFieldStrategyContext.getStrategy(actionRecord.$Type);
|
|
220
|
+
if (!strategy?.isBound(actionRecord)) {
|
|
221
|
+
const actionsAnnotationPath = (0, common_1.createAnnotationPath)(entityType.fullyQualifiedName, chartAnnotation.term, chartAnnotation.qualifier);
|
|
222
|
+
if (strategy?.addLineItemDefinition) {
|
|
223
|
+
strategy.addLineItemDefinition({
|
|
224
|
+
schemaContext: {
|
|
225
|
+
appSchema,
|
|
226
|
+
isObjectPage: false,
|
|
227
|
+
annotation: chartAnnotation,
|
|
228
|
+
annotationId: schemaIdForActions,
|
|
229
|
+
entityType,
|
|
230
|
+
oDataServiceAVT
|
|
231
|
+
},
|
|
232
|
+
actions,
|
|
233
|
+
annotationPath: `${actionsAnnotationPath}/Actions`,
|
|
234
|
+
annotationRecord: actionRecord,
|
|
235
|
+
index: i
|
|
236
|
+
});
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
/* incrementing i unconditionally ensures correct annotation paths reflect each action's true position in the annotations */
|
|
235
240
|
i++;
|
|
236
241
|
});
|
|
237
242
|
}
|
|
238
243
|
}
|
|
244
|
+
/**
|
|
245
|
+
* Creates custom action (including menus) and custom action position definitions for a chart toolbar.
|
|
246
|
+
* Returns `undefined` when targetAnnotation is not set.
|
|
247
|
+
*
|
|
248
|
+
* @param appSchema - The app schema definition
|
|
249
|
+
* @param context - Decorator context containing app and page information
|
|
250
|
+
* @param schemaIdForActions - Schema definition key for the chart actions container
|
|
251
|
+
* @param viewKey - The key to distinguish between different view types
|
|
252
|
+
* @param targetAnnotation - The target annotation for a chart
|
|
253
|
+
* @param logger - Extension logger
|
|
254
|
+
* @param v4Page - The page configuration from manifest
|
|
255
|
+
* @param entitySet - Optional entity set for manifest path prefixing
|
|
256
|
+
*/
|
|
257
|
+
function defineChartCustomActions(appSchema, context, schemaIdForActions, viewKey, targetAnnotation, logger, v4Page, entitySet) {
|
|
258
|
+
if (!targetAnnotation) {
|
|
259
|
+
return;
|
|
260
|
+
}
|
|
261
|
+
let prefix = '';
|
|
262
|
+
// Add prefix with entitySet for ListReport multiview scenario
|
|
263
|
+
if (viewKey !== `${ux_specification_types_1.DefinitionName.ALPChart}`) {
|
|
264
|
+
const entitySetName = typeof entitySet === 'string' ? entitySet : entitySet?.name;
|
|
265
|
+
prefix = entitySetName ? `/${entitySetName}/` : '';
|
|
266
|
+
}
|
|
267
|
+
const customActionDefinitionName = `${ux_specification_types_1.DefinitionName.CustomTableAction}<${viewKey}>`;
|
|
268
|
+
const customActionPositionDefinitionName = `${ux_specification_types_1.DefinitionName.CustomActionPosition}<${viewKey}>`;
|
|
269
|
+
const customActionDefinition = (0, common_1.parseSchemaDefinition)(ux_specification_types_1.DefinitionName.CustomTableAction, viewKey, appSchema);
|
|
270
|
+
(0, common_1.parseSchemaDefinition)(ux_specification_types_1.DefinitionName.CustomActionPosition, viewKey, appSchema);
|
|
271
|
+
if (customActionDefinition.properties) {
|
|
272
|
+
customActionDefinition.properties['position']['$ref'] =
|
|
273
|
+
`${common_1.DEFINITION_LINK_PREFIX}${customActionPositionDefinitionName}`;
|
|
274
|
+
}
|
|
275
|
+
const chartSchemaAdjustmentParameters = {
|
|
276
|
+
context,
|
|
277
|
+
logger,
|
|
278
|
+
v4Page,
|
|
279
|
+
facetDefinitionKey: viewKey,
|
|
280
|
+
customActionPosition: customActionPositionDefinitionName,
|
|
281
|
+
customActionDefinitionName: customActionDefinitionName,
|
|
282
|
+
scopedCustomActionDefinitionKey: customActionDefinitionName,
|
|
283
|
+
sectionActionsDefinitionKey: schemaIdForActions,
|
|
284
|
+
sectionIdInManifest: `${prefix}${targetAnnotation.substring(targetAnnotation.lastIndexOf('@'))}`
|
|
285
|
+
};
|
|
286
|
+
applyLRSchemaAdjustments({ chart: chartSchemaAdjustmentParameters });
|
|
287
|
+
}
|
|
288
|
+
/**
|
|
289
|
+
* Sets up all chart toolbar actions:
|
|
290
|
+
* - assigns the actions $ref to the chart toolbar definition,
|
|
291
|
+
* - defines annotation-based actions and custom actions and menus.
|
|
292
|
+
*
|
|
293
|
+
* @param context - Decorator context containing app and page information
|
|
294
|
+
* @param idForToolbar - Schema definition key for the chart toolbar
|
|
295
|
+
* @param viewKey - The key to distinguish between different view types
|
|
296
|
+
* @param annotations - The UI annotations for the given entity type
|
|
297
|
+
* @param targetAnnotation - The target annotation for the chart
|
|
298
|
+
* @param entityType - The entity type as part of the AVT ConvertedMetadata
|
|
299
|
+
* @param entitySet - Optional entity set for manifest path prefixing
|
|
300
|
+
*/
|
|
301
|
+
function defineChartActions(context, idForToolbar, viewKey, annotations, targetAnnotation, entityType, entitySet) {
|
|
302
|
+
const appSchema = context.schema.get();
|
|
303
|
+
const schemaIdForActions = `${ux_specification_types_1.DefinitionName.Actions}<${viewKey}>`;
|
|
304
|
+
if (appSchema.definitions?.[idForToolbar]) {
|
|
305
|
+
// Create new actions definition based on generic schema Actions definition
|
|
306
|
+
appSchema.definitions[schemaIdForActions] = JSON.parse(JSON.stringify(appSchema.definitions[ux_specification_types_1.DefinitionName.Actions]));
|
|
307
|
+
appSchema.definitions[idForToolbar]['properties'][ux_specification_types_1.PropertyName.actions]['$ref'] =
|
|
308
|
+
common_1.DEFINITION_LINK_PREFIX + schemaIdForActions;
|
|
309
|
+
defineChartAnnotationActions(appSchema, schemaIdForActions, annotations, targetAnnotation, entityType, context.app?.getAVT());
|
|
310
|
+
defineChartCustomActions(appSchema, context, schemaIdForActions, viewKey, targetAnnotation, context.logger, context.page?.target, entitySet);
|
|
311
|
+
let viewEntitySet;
|
|
312
|
+
if (viewKey !== `${ux_specification_types_1.DefinitionName.ALPChart}`) {
|
|
313
|
+
viewEntitySet = typeof entitySet === 'string' ? entitySet : entitySet?.name;
|
|
314
|
+
}
|
|
315
|
+
(0, ListReportUtils_1.addManifestPathsToDefinitionPropertiesLR)(appSchema, context.page?.target?.id, schemaIdForActions, context.app?.getManifest(), targetAnnotation, {
|
|
316
|
+
entitySet: viewEntitySet
|
|
317
|
+
});
|
|
318
|
+
}
|
|
319
|
+
}
|
|
239
320
|
/**
|
|
240
321
|
* Finds the right visualization for a given view.
|
|
241
322
|
*
|
|
@@ -429,18 +510,16 @@ function addALPChartView(appSchema, chartAnnotationPath, targetAnnotation, annot
|
|
|
429
510
|
*/
|
|
430
511
|
function addALPViews(context, viewsPaths, generateParameters, templateAnnotation, v4Page, tableDefinitionName) {
|
|
431
512
|
const appSchema = context.schema.get();
|
|
432
|
-
const
|
|
513
|
+
const { entitySet, entityType, manifest, serviceAVT, logger } = generateParameters;
|
|
514
|
+
const annotations = entityType?.annotations.UI;
|
|
433
515
|
//1. Chart View
|
|
434
516
|
const chartAnnotationPath = viewsPaths?.[0]?.['primary']?.[0]?.[ux_specification_types_1.SchemaTag.annotationPath];
|
|
435
|
-
const { targetAnnotation } = analyzeViewAnnotation(chartAnnotationPath, annotations,
|
|
517
|
+
const { targetAnnotation } = analyzeViewAnnotation(chartAnnotationPath, annotations, serviceAVT, 'primary', undefined, logger);
|
|
436
518
|
addALPChartView(appSchema, chartAnnotationPath, targetAnnotation, annotations);
|
|
437
|
-
// Copy toolbar
|
|
438
|
-
|
|
439
|
-
appSchema.definitions[ux_specification_types_1.DefinitionName.ViewChartToolBar].properties.actions['$ref'] =
|
|
440
|
-
common_1.DEFINITION_LINK_PREFIX + schemaIdForActions;
|
|
441
|
-
defineActions(appSchema, schemaIdForActions, annotations, targetAnnotation, generateParameters.entityType);
|
|
519
|
+
// Copy toolbar and define chart actions
|
|
520
|
+
defineChartActions(context, ux_specification_types_1.DefinitionName.ViewChartToolBar, ux_specification_types_1.DefinitionName.ALPChart, annotations, targetAnnotation, entityType, entitySet);
|
|
442
521
|
//2. Table View
|
|
443
|
-
const { visualization: tableVisualization, targetAnnotation: target } = analyzeViewAnnotation(viewsPaths?.[0]?.['secondary']?.[0]?.[ux_specification_types_1.SchemaTag.annotationPath], annotations,
|
|
522
|
+
const { visualization: tableVisualization, targetAnnotation: target } = analyzeViewAnnotation(viewsPaths?.[0]?.['secondary']?.[0]?.[ux_specification_types_1.SchemaTag.annotationPath], annotations, serviceAVT, 'secondary', undefined, logger);
|
|
444
523
|
const tableDefinition = appSchema.definitions[tableDefinitionName];
|
|
445
524
|
if (tableVisualization || templateAnnotation) {
|
|
446
525
|
tableDefinition.properties.toolBar['$ref'] = `${common_1.DEFINITION_LINK_PREFIX}${ux_specification_types_1.DefinitionName.ToolBarLR}`;
|
|
@@ -479,38 +558,42 @@ function addALPViews(context, viewsPaths, generateParameters, templateAnnotation
|
|
|
479
558
|
const dataForLineItem = {
|
|
480
559
|
isObjectPage: false,
|
|
481
560
|
appSchema,
|
|
482
|
-
|
|
483
|
-
entityType
|
|
484
|
-
oDataServiceAVT:
|
|
485
|
-
|
|
561
|
+
annotation: annotations[annotationTerm],
|
|
562
|
+
entityType,
|
|
563
|
+
oDataServiceAVT: serviceAVT,
|
|
564
|
+
annotationId: ux_specification_types_1.DefinitionName.LineItems
|
|
486
565
|
};
|
|
487
566
|
(0, utils_2.addLineItemsTypeToSchema)(dataForLineItem, ux_specification_types_1.DefinitionName.ViewTableColumn);
|
|
488
567
|
if (target) {
|
|
489
568
|
appSchema.definitions[ux_specification_types_1.DefinitionName.ALPTable][ux_specification_types_1.SchemaTag.annotationPath] = target;
|
|
490
569
|
}
|
|
491
|
-
const
|
|
570
|
+
const tableSchemaAdjustmentParameters = {
|
|
492
571
|
context,
|
|
493
|
-
logger
|
|
572
|
+
logger,
|
|
494
573
|
v4Page,
|
|
495
574
|
tableDefinitionKey: ux_specification_types_1.DefinitionName.ALPTable,
|
|
496
575
|
facetDefinitionKey: ux_specification_types_1.DefinitionName.LineItems,
|
|
497
576
|
dataForLineItem,
|
|
498
|
-
entityType
|
|
499
|
-
entitySet
|
|
577
|
+
entityType,
|
|
578
|
+
entitySet,
|
|
500
579
|
customActionDefinitionName: ux_specification_types_1.DefinitionName.CustomTableAction,
|
|
501
|
-
sectionActionsDefinitionKey: `${ux_specification_types_1.DefinitionName.Actions}<${(0, common_1.prepareRef)(ux_specification_types_1.DefinitionName.LineItems)}
|
|
580
|
+
sectionActionsDefinitionKey: `${ux_specification_types_1.DefinitionName.Actions}<${(0, common_1.prepareRef)(ux_specification_types_1.DefinitionName.LineItems)}>`,
|
|
581
|
+
isCapService: generateParameters.isCapService
|
|
502
582
|
};
|
|
503
|
-
applyLRSchemaAdjustments(
|
|
583
|
+
applyLRSchemaAdjustments({ table: tableSchemaAdjustmentParameters });
|
|
504
584
|
const pathParts = annotations[viewAnnotation].fullyQualifiedName.split('@');
|
|
505
585
|
tableView[ux_specification_types_1.SchemaTag.annotationPath] = `/${pathParts[0]}/@${pathParts[1]}`;
|
|
506
586
|
tableView[ux_specification_types_1.SchemaTag.key] = 'secondary';
|
|
507
587
|
tableView[ux_specification_types_1.SchemaTag.keys] = [{ name: ux_specification_types_1.SchemaKeyName.key, value: 'secondary' }];
|
|
588
|
+
// Add "manifestPath" for ALP table columns and actions
|
|
589
|
+
(0, ListReportUtils_1.addManifestPathsToDefinitionPropertiesLR)(appSchema, v4Page.id, ux_specification_types_1.DefinitionName.LineItems, manifest);
|
|
590
|
+
(0, ListReportUtils_1.addManifestPathsToDefinitionPropertiesLR)(appSchema, v4Page.id, `${ux_specification_types_1.DefinitionName.Actions}<${(0, common_1.prepareRef)(ux_specification_types_1.DefinitionName.LineItems)}>`, manifest);
|
|
508
591
|
}
|
|
509
|
-
(0, utils_2.addCustomColumnDefinition)(appSchema, v4Page,
|
|
592
|
+
(0, utils_2.addCustomColumnDefinition)(appSchema, v4Page, logger);
|
|
510
593
|
// Add "manifestPath" for table properties
|
|
511
594
|
addManifestPathsToPropertiesLR(appSchema, ux_specification_types_1.DefinitionName.ALPTable, tableDefinition, {
|
|
512
595
|
pageName: v4Page.id,
|
|
513
|
-
manifest
|
|
596
|
+
manifest,
|
|
514
597
|
targetAnnotation: target
|
|
515
598
|
});
|
|
516
599
|
}
|
|
@@ -518,27 +601,26 @@ function addALPViews(context, viewsPaths, generateParameters, templateAnnotation
|
|
|
518
601
|
* Modifies the app schema, adds the right line chart settings.
|
|
519
602
|
*
|
|
520
603
|
* @param inputParameters - list of input parameters as collected by the calling instance
|
|
604
|
+
* @param context - decorator context containing app and page information
|
|
521
605
|
* @param annotations - UI annotations of the given entityType
|
|
522
606
|
* @returns the ID for the chart view in schema
|
|
523
607
|
*/
|
|
524
|
-
function addViewChartDefinitions(inputParameters, annotations) {
|
|
525
|
-
const
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
608
|
+
function addViewChartDefinitions(inputParameters, context, annotations) {
|
|
609
|
+
const appSchema = context.schema.get();
|
|
610
|
+
const { entitySet, navPropName, targetAnnotation, targetEntityType, viewKey } = inputParameters;
|
|
611
|
+
const idForChart = `${ux_specification_types_1.DefinitionName.LRChartView}<${viewKey}>`;
|
|
612
|
+
appSchema.definitions[idForChart] = JSON.parse(JSON.stringify(appSchema.definitions[ux_specification_types_1.DefinitionName.LRChartView]));
|
|
613
|
+
delete appSchema.definitions[idForChart][ux_specification_types_1.SchemaTag.isViewNode];
|
|
614
|
+
appSchema.definitions[idForChart][ux_specification_types_1.SchemaTag.annotationPath] = targetAnnotation;
|
|
615
|
+
if (navPropName) {
|
|
616
|
+
appSchema.definitions[idForChart]['navigationProperty'] = navPropName;
|
|
531
617
|
}
|
|
532
618
|
//Copy toolbar
|
|
533
|
-
const idForToolbar = `${ux_specification_types_1.DefinitionName.ViewChartToolBar}<${
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
const schemaIdForActions = `${ux_specification_types_1.DefinitionName.Actions}<${inputParameters.viewKey}>`;
|
|
539
|
-
defineActions(inputParameters.appSchema, schemaIdForActions, annotations, inputParameters.targetAnnotation, inputParameters.targetEntityType);
|
|
540
|
-
inputParameters.appSchema.definitions[idForToolbar]['properties'][ux_specification_types_1.PropertyName.actions]['$ref'] =
|
|
541
|
-
`${common_1.DEFINITION_LINK_PREFIX}${schemaIdForActions}`;
|
|
619
|
+
const idForToolbar = `${ux_specification_types_1.DefinitionName.ViewChartToolBar}<${viewKey}>`;
|
|
620
|
+
appSchema.definitions[idForToolbar] = JSON.parse(JSON.stringify(appSchema.definitions[ux_specification_types_1.DefinitionName.ViewChartToolBar]));
|
|
621
|
+
appSchema.definitions[idForChart]['properties'].toolBar.$ref = `${common_1.DEFINITION_LINK_PREFIX}${idForToolbar}`;
|
|
622
|
+
//Copy actions from annotations
|
|
623
|
+
defineChartActions(context, idForToolbar, viewKey, annotations, targetAnnotation, targetEntityType, entitySet);
|
|
542
624
|
return idForChart;
|
|
543
625
|
}
|
|
544
626
|
/**
|
|
@@ -546,15 +628,16 @@ function addViewChartDefinitions(inputParameters, annotations) {
|
|
|
546
628
|
*
|
|
547
629
|
* @param inputParameters - list of input parameters as collected by the calling instance
|
|
548
630
|
* @param UIAnnotations - AVT UI annotations of the given entity type
|
|
549
|
-
* @param
|
|
631
|
+
* @param context - decorator context containing app and page information
|
|
550
632
|
* @param viewsDefinition - the views definition in app schema (MultiTableModeV4)
|
|
551
633
|
* @param viewKey - view key
|
|
552
634
|
* @param title - view title
|
|
553
635
|
* @param page - Represents the page in the application's structure where the view line items are to be added.
|
|
554
636
|
* @param app - Represents the overall application structure, providing access to the manifest.
|
|
555
637
|
*/
|
|
556
|
-
function addViewChart(inputParameters, UIAnnotations,
|
|
557
|
-
const
|
|
638
|
+
function addViewChart(inputParameters, UIAnnotations, context, viewsDefinition, viewKey, title, page, app) {
|
|
639
|
+
const appSchema = context.schema.get();
|
|
640
|
+
const idForChart = addViewChartDefinitions(inputParameters, context, UIAnnotations);
|
|
558
641
|
const chartViewDefinition = appSchema.definitions[idForChart];
|
|
559
642
|
chartViewDefinition.properties.annotationPath[ux_specification_types_1.SchemaTag.hidden] = true;
|
|
560
643
|
chartViewDefinition.properties.index[ux_specification_types_1.SchemaTag.hidden] = true;
|
|
@@ -565,8 +648,8 @@ function addViewChart(inputParameters, UIAnnotations, appSchema, viewsDefinition
|
|
|
565
648
|
description: title ? title : titleOnHover,
|
|
566
649
|
title: titleOnHover
|
|
567
650
|
};
|
|
568
|
-
// Add "manifestPath" for
|
|
569
|
-
addManifestPathsToPropertiesLR(
|
|
651
|
+
// Add "manifestPath" for chart properties
|
|
652
|
+
addManifestPathsToPropertiesLR(appSchema, ux_specification_types_1.DefinitionName.LRChartView, chartViewDefinition, {
|
|
570
653
|
pageName: page.target.id,
|
|
571
654
|
manifest: app.manifest,
|
|
572
655
|
targetAnnotation: inputParameters.targetAnnotation,
|
|
@@ -601,22 +684,29 @@ function getLineItemRef(v4Page, entityType, viewKey, lineItemTerm, lineItemQuali
|
|
|
601
684
|
/**
|
|
602
685
|
* Adjusts the schema for a table by making necessary changes such as populating creation fields,
|
|
603
686
|
* adjusting creation field definitions, and adding enum mappings for mass edit functionalities.
|
|
687
|
+
* Adjusts the schema for the chart by adjusting custom action and custom action menu definitions.
|
|
604
688
|
*
|
|
605
|
-
* @param {SchemaAdjustmentParameters} schemaAdjustmentParameters - Object containing the parameters required for schema adjustments
|
|
689
|
+
* @param {SchemaAdjustmentParameters} schemaAdjustmentParameters - Object containing the parameters required for schema adjustments of the table and chart.
|
|
606
690
|
*/
|
|
607
|
-
function applyLRSchemaAdjustments(
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
691
|
+
function applyLRSchemaAdjustments({ table, chart }) {
|
|
692
|
+
// in the future, all postgeneration adjustments for the LR Page table should be done here
|
|
693
|
+
if (table) {
|
|
694
|
+
const { entityType, tableDefinitionKey, facetDefinitionKey, context } = table;
|
|
695
|
+
const appSchema = context.schema.get();
|
|
696
|
+
// populate the creation fields for the table with the data from the columns
|
|
697
|
+
(0, utils_1.initializeCreationModeSchema)(appSchema, facetDefinitionKey, entityType, ux_specification_types_1.DefinitionName.TableCreationModeLR);
|
|
698
|
+
// Apply decorator-based visibility rules for table properties
|
|
699
|
+
applyTableDecorators(table);
|
|
700
|
+
// add columns to a enum, in this case enableMassEdit -> visibleFields and ignoredFields
|
|
701
|
+
(0, utils_2.addEnumForEnableMassEdit)(appSchema, tableDefinitionKey, facetDefinitionKey, entityType);
|
|
702
|
+
(0, inlineEdit_1.adjustInlineEdit)(table, facetDefinitionKey);
|
|
703
|
+
// add the custom action and custom action menu definition
|
|
704
|
+
(0, actions_1.configureCustomActionDefinition)(table);
|
|
705
|
+
}
|
|
706
|
+
// in the future, all postgeneration adjustments for the LR Page chart should be done here
|
|
707
|
+
if (chart) {
|
|
708
|
+
(0, actions_1.configureCustomActionDefinition)(chart);
|
|
709
|
+
}
|
|
620
710
|
}
|
|
621
711
|
/**
|
|
622
712
|
* Retrieves the table settings from the manifest for a given line item reference.
|
|
@@ -635,13 +725,13 @@ function getTableSettingsFromManifest(v4Page, lineItemRef) {
|
|
|
635
725
|
* This function uses the @hide and @message decorators defined on the Table and TableCreationModeLR classes
|
|
636
726
|
* to conditionally hide properties and show warning messages based on table type and settings.
|
|
637
727
|
*
|
|
638
|
-
* @param
|
|
728
|
+
* @param tableSchemaAdjustmentParameters - Parameters containing schema, page, and table definition information
|
|
639
729
|
*/
|
|
640
|
-
function applyTableDecorators(
|
|
641
|
-
const { tableDefinitionKey, facetDefinitionKey, v4Page, viewKey, entityType, dataForLineItem, context } =
|
|
730
|
+
function applyTableDecorators(tableSchemaAdjustmentParameters) {
|
|
731
|
+
const { tableDefinitionKey, facetDefinitionKey, v4Page, viewKey, entityType, dataForLineItem, context } = tableSchemaAdjustmentParameters;
|
|
642
732
|
const appSchema = context.schema.get();
|
|
643
733
|
// Get the line item reference for looking up table settings in manifest
|
|
644
|
-
const lineItemRef = getLineItemRef(v4Page, entityType, viewKey, entityType?.annotations?.UI?.LineItem?.term, dataForLineItem?.
|
|
734
|
+
const lineItemRef = getLineItemRef(v4Page, entityType, viewKey, entityType?.annotations?.UI?.LineItem?.term, dataForLineItem?.annotation?.qualifier);
|
|
645
735
|
let schemaDefinitionName;
|
|
646
736
|
if (viewKey) {
|
|
647
737
|
// For multi-view scenario, initialize a view-specific personalization schema to isolate decorator messages per view
|
|
@@ -650,12 +740,19 @@ function applyTableDecorators(schemaAdjustmentParameters) {
|
|
|
650
740
|
// Get table settings from manifest and build custom context for decorator evaluation
|
|
651
741
|
const tableSettings = getTableSettingsFromManifest(v4Page, lineItemRef);
|
|
652
742
|
// Check InsertRestrictions to determine if entity/navigation allows insertion
|
|
653
|
-
const { entitySet, navigationPath } =
|
|
743
|
+
const { entitySet, navigationPath } = tableSchemaAdjustmentParameters;
|
|
654
744
|
const isInsertable = (0, utils_1.getInsertableForEntitySet)(entitySet, navigationPath);
|
|
745
|
+
// Calculate available table types based on entity set capabilities
|
|
746
|
+
// For contained navigation (ContainsTarget=true), ensure we use the correct EntityType
|
|
747
|
+
const entitySetForCapabilities = (0, utils_1.ensureEntitySetWithCorrectType)(entitySet, dataForLineItem?.entityType);
|
|
748
|
+
// Use isCapService from parameters, default to false if not provided
|
|
749
|
+
// Pass minUI5Version to enable version-gated features (1.142.0+ for capability-based restrictions)
|
|
750
|
+
const tableTypeOptions = (0, utils_1.getTableTypeOptions)(entitySetForCapabilities, tableSchemaAdjustmentParameters.isCapService ?? false, context.app?.config.minUI5Version);
|
|
655
751
|
const customContext = {
|
|
656
752
|
...tableSettings,
|
|
657
|
-
type: tableSettings?.type
|
|
658
|
-
isInsertable
|
|
753
|
+
type: tableSettings?.type,
|
|
754
|
+
isInsertable,
|
|
755
|
+
availableTableTypes: tableTypeOptions.options
|
|
659
756
|
};
|
|
660
757
|
// Get the table definition to apply decorators to
|
|
661
758
|
const tableDefinition = appSchema.definitions[tableDefinitionKey];
|
|
@@ -725,10 +822,11 @@ function applyTableDecorators(schemaAdjustmentParameters) {
|
|
|
725
822
|
* @param generateParameters.serviceAVT - OData service AVT information
|
|
726
823
|
* @param generateParameters.entityType - entity type of the current page
|
|
727
824
|
* @param generateParameters.entitySet - The specified entity set for the view.
|
|
825
|
+
* @param generateParameters.isCapService - indicates whether the service is a CAP service
|
|
728
826
|
* @param {DecoratorContext} context - The context object providing access to the application schema, page, and app information necessary for schema modifications.
|
|
729
827
|
* @param {ExtensionLogger} logger - Logger for recording informational or error messages during the schema adjustment process.
|
|
730
828
|
*/
|
|
731
|
-
function addViewLineItems(inputParameters, viewsDefinition, visualization, templateAnnotation, { serviceAVT, entityType, entitySet }, context, logger) {
|
|
829
|
+
function addViewLineItems(inputParameters, viewsDefinition, visualization, templateAnnotation, { serviceAVT, entityType, entitySet, isCapService }, context, logger) {
|
|
732
830
|
const { app, page } = context;
|
|
733
831
|
const tableId = `${ux_specification_types_1.DefinitionName.LRTableView}<${inputParameters.viewKey}>`;
|
|
734
832
|
const schemaIdForColumns = `${ux_specification_types_1.DefinitionName.LineItemsOfView}::${inputParameters.viewKey}`;
|
|
@@ -758,10 +856,10 @@ function addViewLineItems(inputParameters, viewsDefinition, visualization, templ
|
|
|
758
856
|
const dataForLineItem = {
|
|
759
857
|
isObjectPage: false,
|
|
760
858
|
appSchema: inputParameters.appSchema,
|
|
761
|
-
|
|
859
|
+
annotation: inputParameters.targetEntityType?.annotations.UI[annotationTerm],
|
|
762
860
|
entityType: inputParameters.targetEntityType,
|
|
763
861
|
oDataServiceAVT: serviceAVT,
|
|
764
|
-
|
|
862
|
+
annotationId: schemaIdForColumns
|
|
765
863
|
};
|
|
766
864
|
(0, utils_2.addLineItemsTypeToSchema)(dataForLineItem, ux_specification_types_1.DefinitionName.ViewTableColumn, ux_specification_types_1.DefinitionName.ViewCustomColumn, ux_specification_types_1.DefinitionName.ViewCustomAction);
|
|
767
865
|
// Table toolbar actions with custom actions
|
|
@@ -774,7 +872,7 @@ function addViewLineItems(inputParameters, viewsDefinition, visualization, templ
|
|
|
774
872
|
const customActionDefinition = inputParameters.appSchema.definitions[customActionDefinitionKey];
|
|
775
873
|
customActionDefinition.properties.position.$ref =
|
|
776
874
|
`${common_1.DEFINITION_LINK_PREFIX}${customActionPositionDefinitionKey}`;
|
|
777
|
-
const
|
|
875
|
+
const tableSchemaAdjustmentParameters = {
|
|
778
876
|
logger: logger,
|
|
779
877
|
context,
|
|
780
878
|
v4Page: page.target,
|
|
@@ -789,9 +887,10 @@ function addViewLineItems(inputParameters, viewsDefinition, visualization, templ
|
|
|
789
887
|
scopedCustomActionDefinitionKey: customActionDefinitionKey,
|
|
790
888
|
customActionDefinitionName: ux_specification_types_1.DefinitionName.ViewCustomAction,
|
|
791
889
|
sectionIdInManifest,
|
|
792
|
-
customActionPosition: customActionPositionDefinitionKey
|
|
890
|
+
customActionPosition: customActionPositionDefinitionKey,
|
|
891
|
+
isCapService
|
|
793
892
|
};
|
|
794
|
-
applyLRSchemaAdjustments(
|
|
893
|
+
applyLRSchemaAdjustments({ table: tableSchemaAdjustmentParameters });
|
|
795
894
|
// Add "manifestPath" for table properties
|
|
796
895
|
addManifestPathsToPropertiesLR(inputParameters.appSchema, ux_specification_types_1.DefinitionName.LRTableView, lrTableView, {
|
|
797
896
|
pageName: page.target.id,
|
|
@@ -803,7 +902,9 @@ function addViewLineItems(inputParameters, viewsDefinition, visualization, templ
|
|
|
803
902
|
}
|
|
804
903
|
}, true);
|
|
805
904
|
// Add "manifestPath" for view actions
|
|
806
|
-
(0, ListReportUtils_1.addManifestPathsToDefinitionPropertiesLR)(inputParameters.appSchema, page.target.id, schemaIdForActions, app.getManifest(), inputParameters.targetAnnotation,
|
|
905
|
+
(0, ListReportUtils_1.addManifestPathsToDefinitionPropertiesLR)(inputParameters.appSchema, page.target.id, schemaIdForActions, app.getManifest(), inputParameters.targetAnnotation, {
|
|
906
|
+
entitySet: inputParameters.entitySet
|
|
907
|
+
});
|
|
807
908
|
}
|
|
808
909
|
/**
|
|
809
910
|
* Adds the schema tags to a given view.
|
|
@@ -841,7 +942,9 @@ function addViewCustomExtensions(commonInputParameters, visualization, v4Page, m
|
|
|
841
942
|
(0, utils_2.addCustomColumnDefinition)(commonInputParameters.appSchema, v4Page, logger, `${ux_specification_types_1.DefinitionName.ViewCustomColumn}<${schemaIdForColumns}>`, schemaIdForColumns, sectionIdInManifest);
|
|
842
943
|
(0, utils_2.addFragmentEnumForAnchor)(commonInputParameters.appSchema, schemaIdForColumns, v4Page, `${ux_specification_types_1.DefinitionName.ViewPosition}<${schemaIdForColumns}>`, sectionIdInManifest);
|
|
843
944
|
// Add "manifestPath" for view columns
|
|
844
|
-
(0, ListReportUtils_1.addManifestPathsToDefinitionPropertiesLR)(commonInputParameters.appSchema, v4Page.id, schemaIdForColumns, manifest, commonInputParameters.targetAnnotation,
|
|
945
|
+
(0, ListReportUtils_1.addManifestPathsToDefinitionPropertiesLR)(commonInputParameters.appSchema, v4Page.id, schemaIdForColumns, manifest, commonInputParameters.targetAnnotation, {
|
|
946
|
+
entitySet: commonInputParameters.entitySet
|
|
947
|
+
});
|
|
845
948
|
// Remove generic position
|
|
846
949
|
if (commonInputParameters.appSchema.definitions.Position) {
|
|
847
950
|
delete commonInputParameters.appSchema.definitions.Position;
|
|
@@ -870,7 +973,7 @@ function addLRViewParts(visualization, viewsDefinition, commonInputParameters, {
|
|
|
870
973
|
}
|
|
871
974
|
else if (visualization?.indexOf('Chart') > -1) {
|
|
872
975
|
//Add Chart view
|
|
873
|
-
addViewChart(commonInputParameters, uiAnnotations,
|
|
976
|
+
addViewChart(commonInputParameters, uiAnnotations, context, viewsDefinition, commonInputParameters.viewKey, commonInputParameters.title, page, app);
|
|
874
977
|
}
|
|
875
978
|
else if (view['template']) {
|
|
876
979
|
const titleOnHover = view['label'] || `Custom View (key: ${commonInputParameters.viewKey})`;
|