@sapui5/sap.fe.core 1.131.0 → 1.133.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (317) hide show
  1. package/package.json +1 -1
  2. package/src/sap/fe/core/.library +1 -1
  3. package/src/sap/fe/core/ActionRuntime.js +17 -23
  4. package/src/sap/fe/core/AppComponent.js +74 -36
  5. package/src/sap/fe/core/AppComponent.ts +70 -3
  6. package/src/sap/fe/core/AppStateHandler.js +44 -13
  7. package/src/sap/fe/core/AppStateHandler.ts +38 -0
  8. package/src/sap/fe/core/BaseController.js +3 -3
  9. package/src/sap/fe/core/CommonUtils.js +30 -37
  10. package/src/sap/fe/core/CommonUtils.ts +15 -13
  11. package/src/sap/fe/core/ExtensionAPI.js +29 -34
  12. package/src/sap/fe/core/ExtensionAPI.ts +3 -0
  13. package/src/sap/fe/core/InsightsFormattersExtension.js +2 -2
  14. package/src/sap/fe/core/PageController.js +40 -31
  15. package/src/sap/fe/core/PageController.ts +14 -1
  16. package/src/sap/fe/core/ResourceModel.js +4 -4
  17. package/src/sap/fe/core/ReuseComponent.js +27 -13
  18. package/src/sap/fe/core/ReuseComponent.ts +18 -0
  19. package/src/sap/fe/core/TemplateComponent.js +102 -89
  20. package/src/sap/fe/core/TemplateComponent.ts +20 -1
  21. package/src/sap/fe/core/TemplateModel.js +6 -7
  22. package/src/sap/fe/core/UIProvider.js +1 -1
  23. package/src/sap/fe/core/UIProvider.ts +2 -9
  24. package/src/sap/fe/core/buildingBlocks/BuildingBlock.js +63 -48
  25. package/src/sap/fe/core/buildingBlocks/BuildingBlock.ts +56 -27
  26. package/src/sap/fe/core/buildingBlocks/IBuildingBlockOwnerComponent.js +9 -0
  27. package/src/sap/fe/core/buildingBlocks/IBuildingBlockOwnerComponent.ts +48 -0
  28. package/src/sap/fe/core/buildingBlocks/TraceInfo.js +4 -6
  29. package/src/sap/fe/core/buildingBlocks/templating/AttributeModel.js +2 -2
  30. package/src/sap/fe/core/buildingBlocks/templating/BuildingBlockSupport.js +2 -3
  31. package/src/sap/fe/core/buildingBlocks/templating/BuildingBlockTemplateProcessor.js +32 -18
  32. package/src/sap/fe/core/buildingBlocks/templating/BuildingBlockTemplateProcessor.ts +30 -3
  33. package/src/sap/fe/core/buildingBlocks/templating/BuildingBlockTemplatingBase.js +9 -13
  34. package/src/sap/fe/core/buildingBlocks/templating/BuildingBlockTemplatingBase.ts +2 -1
  35. package/src/sap/fe/core/buildingBlocks/templating/RuntimeBuildingBlock.js +2 -2
  36. package/src/sap/fe/core/buildingBlocks/templating/RuntimeBuildingBlockFragment.js +19 -25
  37. package/src/sap/fe/core/buildingBlocks/templating/RuntimeBuildingBlockFragment.ts +1 -1
  38. package/src/sap/fe/core/controllerextensions/BaseControllerExtension.js +3 -4
  39. package/src/sap/fe/core/controllerextensions/CollaborativeDraft.js +20 -24
  40. package/src/sap/fe/core/controllerextensions/CollaborativeDraft.ts +10 -15
  41. package/src/sap/fe/core/controllerextensions/ContextSharing.js +3 -3
  42. package/src/sap/fe/core/controllerextensions/EditFlow.js +296 -246
  43. package/src/sap/fe/core/controllerextensions/EditFlow.ts +253 -175
  44. package/src/sap/fe/core/controllerextensions/Feedback.js +10 -11
  45. package/src/sap/fe/core/controllerextensions/IntentBasedNavigation.js +6 -6
  46. package/src/sap/fe/core/controllerextensions/IntentBasedNavigation.ts +1 -0
  47. package/src/sap/fe/core/controllerextensions/InternalIntentBasedNavigation.js +27 -36
  48. package/src/sap/fe/core/controllerextensions/InternalRouting.js +57 -78
  49. package/src/sap/fe/core/controllerextensions/InternalRouting.ts +42 -50
  50. package/src/sap/fe/core/controllerextensions/KPIManagement.js +12 -19
  51. package/src/sap/fe/core/controllerextensions/MessageHandler.js +23 -17
  52. package/src/sap/fe/core/controllerextensions/MessageHandler.ts +21 -7
  53. package/src/sap/fe/core/controllerextensions/PageReady.js +15 -21
  54. package/src/sap/fe/core/controllerextensions/Paginator.js +3 -3
  55. package/src/sap/fe/core/controllerextensions/Placeholder.js +3 -3
  56. package/src/sap/fe/core/controllerextensions/Recommendations.js +23 -36
  57. package/src/sap/fe/core/controllerextensions/Recommendations.ts +1 -1
  58. package/src/sap/fe/core/controllerextensions/Routing.js +3 -3
  59. package/src/sap/fe/core/controllerextensions/Share.js +19 -28
  60. package/src/sap/fe/core/controllerextensions/SideEffects.js +68 -32
  61. package/src/sap/fe/core/controllerextensions/SideEffects.ts +58 -6
  62. package/src/sap/fe/core/controllerextensions/Telemetry.js +4 -5
  63. package/src/sap/fe/core/controllerextensions/ViewState.js +23 -24
  64. package/src/sap/fe/core/controllerextensions/ViewState.ts +6 -1
  65. package/src/sap/fe/core/controllerextensions/cards/CollaborationManager.js +13 -10
  66. package/src/sap/fe/core/controllerextensions/cards/CollaborationManager.ts +13 -8
  67. package/src/sap/fe/core/controllerextensions/collaboration/ActivityBase.js +5 -5
  68. package/src/sap/fe/core/controllerextensions/collaboration/CollaborationCommon.js +15 -16
  69. package/src/sap/fe/core/controllerextensions/collaboration/CollaborationCommon.ts +3 -4
  70. package/src/sap/fe/core/controllerextensions/dialog/OperationsDialog.js +288 -0
  71. package/src/sap/fe/core/controllerextensions/dialog/{OperationsDialog.block.tsx → OperationsDialog.tsx} +27 -29
  72. package/src/sap/fe/core/controllerextensions/editFlow/NotApplicableContextDialog.js +41 -5
  73. package/src/sap/fe/core/controllerextensions/editFlow/NotApplicableContextDialog.tsx +61 -8
  74. package/src/sap/fe/core/controllerextensions/editFlow/ODataOperation.js +404 -0
  75. package/src/sap/fe/core/controllerextensions/editFlow/ODataOperation.ts +502 -0
  76. package/src/sap/fe/core/controllerextensions/editFlow/TransactionHelper.js +35 -43
  77. package/src/sap/fe/core/controllerextensions/editFlow/TransactionHelper.ts +34 -14
  78. package/src/sap/fe/core/controllerextensions/editFlow/draft.js +37 -27
  79. package/src/sap/fe/core/controllerextensions/editFlow/draft.ts +27 -15
  80. package/src/sap/fe/core/controllerextensions/editFlow/draftDataLossPopup.js +51 -39
  81. package/src/sap/fe/core/controllerextensions/editFlow/draftDataLossPopup.ts +75 -34
  82. package/src/sap/fe/core/controllerextensions/editFlow/editFlowConstants.js +4 -4
  83. package/src/sap/fe/core/controllerextensions/editFlow/operations/facade.js +88 -427
  84. package/src/sap/fe/core/controllerextensions/editFlow/operations/facade.ts +82 -620
  85. package/src/sap/fe/core/controllerextensions/editFlow/sticky.js +9 -5
  86. package/src/sap/fe/core/controllerextensions/editFlow/sticky.ts +6 -5
  87. package/src/sap/fe/core/controllerextensions/messageHandler/messageHandling.js +116 -79
  88. package/src/sap/fe/core/controllerextensions/messageHandler/messageHandling.ts +87 -13
  89. package/src/sap/fe/core/controllerextensions/pageReady/DataQueryWatcher.js +4 -6
  90. package/src/sap/fe/core/controllerextensions/recommendations/Telemetry.js +5 -7
  91. package/src/sap/fe/core/controllerextensions/routing/ContextPathHelper.js +6 -7
  92. package/src/sap/fe/core/controllerextensions/routing/NavigationReason.js +4 -4
  93. package/src/sap/fe/core/controllerextensions/routing/RouterProxy.js +58 -20
  94. package/src/sap/fe/core/controllerextensions/routing/RouterProxy.ts +55 -4
  95. package/src/sap/fe/core/controllerextensions/viewState/IViewStateContributor.js +1 -1
  96. package/src/sap/fe/core/controllerextensions/viewState/IViewStateContributor.ts +1 -1
  97. package/src/sap/fe/core/controllerextensions/viewState/IViewStateContributorMixin.js +9 -12
  98. package/src/sap/fe/core/controls/CommandExecution.js +2 -2
  99. package/src/sap/fe/core/controls/ComponentLoader.js +20 -21
  100. package/src/sap/fe/core/controls/DataLossOrDraftDiscard/DraftDataLossDialog.js +250 -0
  101. package/src/sap/fe/core/controls/DataLossOrDraftDiscard/{DraftDataLossDialog.block.tsx → DraftDataLossDialog.tsx} +31 -19
  102. package/src/sap/fe/core/controls/FormElementWrapper.js +19 -21
  103. package/src/sap/fe/core/controls/HideFormGroupAutomatically.js +114 -0
  104. package/src/sap/fe/core/controls/HideFormGroupAutomatically.ts +115 -0
  105. package/src/sap/fe/core/controls/Recommendations/ConfirmRecommendationDialog.js +454 -0
  106. package/src/sap/fe/core/controls/Recommendations/{ConfirmRecommendationDialog.block.tsx → ConfirmRecommendationDialog.tsx} +5 -9
  107. package/src/sap/fe/core/converters/ConverterContext.js +17 -18
  108. package/src/sap/fe/core/converters/ConverterContext.ts +10 -15
  109. package/src/sap/fe/core/converters/ManifestSettings.js +29 -28
  110. package/src/sap/fe/core/converters/ManifestSettings.ts +22 -1
  111. package/src/sap/fe/core/converters/ManifestWrapper.js +26 -48
  112. package/src/sap/fe/core/converters/MetaModelConverter.js +21 -28
  113. package/src/sap/fe/core/converters/MetaModelConverter.ts +2 -0
  114. package/src/sap/fe/core/converters/TemplateConverter.js +17 -21
  115. package/src/sap/fe/core/converters/TemplateConverter.ts +5 -3
  116. package/src/sap/fe/core/converters/annotations/DataField.js +69 -66
  117. package/src/sap/fe/core/converters/annotations/DataField.ts +30 -0
  118. package/src/sap/fe/core/converters/common/AnnotationConverter.js +20 -23
  119. package/src/sap/fe/core/converters/controls/Common/Action.js +178 -43
  120. package/src/sap/fe/core/converters/controls/Common/Action.ts +202 -19
  121. package/src/sap/fe/core/converters/controls/Common/Chart.js +47 -22
  122. package/src/sap/fe/core/converters/controls/Common/Chart.ts +50 -5
  123. package/src/sap/fe/core/converters/controls/Common/DataVisualization.js +16 -23
  124. package/src/sap/fe/core/converters/controls/Common/Form.js +25 -38
  125. package/src/sap/fe/core/converters/controls/Common/Form.ts +3 -0
  126. package/src/sap/fe/core/converters/controls/Common/KPI.js +32 -47
  127. package/src/sap/fe/core/converters/controls/Common/Table.js +464 -506
  128. package/src/sap/fe/core/converters/controls/Common/Table.ts +335 -219
  129. package/src/sap/fe/core/converters/controls/Common/table/StandardActions.js +17 -28
  130. package/src/sap/fe/core/converters/controls/Common/table/StandardActions.ts +1 -2
  131. package/src/sap/fe/core/converters/controls/ListReport/FilterBar.js +66 -90
  132. package/src/sap/fe/core/converters/controls/ListReport/FilterBar.ts +10 -1
  133. package/src/sap/fe/core/converters/controls/ListReport/VisualFilters.js +49 -73
  134. package/src/sap/fe/core/converters/controls/ObjectPage/Avatar.js +6 -10
  135. package/src/sap/fe/core/converters/controls/ObjectPage/HeaderFacet.js +35 -50
  136. package/src/sap/fe/core/converters/controls/ObjectPage/SubSection.js +110 -60
  137. package/src/sap/fe/core/converters/controls/ObjectPage/SubSection.ts +137 -41
  138. package/src/sap/fe/core/converters/helpers/Aggregation.js +19 -30
  139. package/src/sap/fe/core/converters/helpers/Aggregation.ts +5 -5
  140. package/src/sap/fe/core/converters/helpers/ConfigurableObject.js +11 -14
  141. package/src/sap/fe/core/converters/helpers/DataFieldHelper.js +14 -21
  142. package/src/sap/fe/core/converters/helpers/InsightsHelpers.js +4 -6
  143. package/src/sap/fe/core/converters/helpers/IssueManager.js +7 -7
  144. package/src/sap/fe/core/converters/helpers/Key.js +1 -1
  145. package/src/sap/fe/core/converters/helpers/SelectionVariantHelper.js +2 -3
  146. package/src/sap/fe/core/converters/objectPage/FormMenuActions.js +18 -52
  147. package/src/sap/fe/core/converters/objectPage/FormMenuActions.ts +0 -34
  148. package/src/sap/fe/core/converters/objectPage/HeaderAndFooterAction.js +103 -74
  149. package/src/sap/fe/core/converters/objectPage/HeaderAndFooterAction.ts +111 -39
  150. package/src/sap/fe/core/converters/templates/ListReportConverter.js +28 -31
  151. package/src/sap/fe/core/converters/templates/ListReportConverter.ts +17 -9
  152. package/src/sap/fe/core/converters/templates/ObjectPageConverter.js +61 -52
  153. package/src/sap/fe/core/converters/templates/ObjectPageConverter.ts +60 -21
  154. package/src/sap/fe/core/definition/FEDefinition.js +104 -44
  155. package/src/sap/fe/core/designtime/AppComponent.designtime.js +37 -7
  156. package/src/sap/fe/core/designtime/AppComponent.designtime.ts +42 -2
  157. package/src/sap/fe/core/formatters/CollaborationFormatter.js +4 -5
  158. package/src/sap/fe/core/formatters/FiscalFormat.js +24 -24
  159. package/src/sap/fe/core/formatters/ValueFormatter.js +4 -23
  160. package/src/sap/fe/core/formatters/ValueFormatter.ts +0 -18
  161. package/src/sap/fe/core/fpm/Component.js +12 -14
  162. package/src/sap/fe/core/fpm/manifest.json +1 -1
  163. package/src/sap/fe/core/helpers/AppStartupHelper.js +20 -15
  164. package/src/sap/fe/core/helpers/AppStartupHelper.ts +22 -13
  165. package/src/sap/fe/core/helpers/BindingHelper.js +3 -3
  166. package/src/sap/fe/core/helpers/BindingHelper.ts +1 -1
  167. package/src/sap/fe/core/helpers/DeleteHelper.js +55 -62
  168. package/src/sap/fe/core/helpers/DeleteHelper.ts +48 -51
  169. package/src/sap/fe/core/helpers/ExcelFormatHelper.js +4 -7
  170. package/src/sap/fe/core/helpers/FPMHelper.js +4 -7
  171. package/src/sap/fe/core/helpers/HTTP503Handler.js +2 -1
  172. package/src/sap/fe/core/helpers/HTTP503Handler.ts +4 -3
  173. package/src/sap/fe/core/helpers/KeepAliveHelper.js +5 -5
  174. package/src/sap/fe/core/helpers/KeepAliveRefreshTypes.js +6 -6
  175. package/src/sap/fe/core/helpers/LoaderUtils.js +8 -3
  176. package/src/sap/fe/core/helpers/LoaderUtils.ts +15 -4
  177. package/src/sap/fe/core/helpers/MessageStrip.js +3 -4
  178. package/src/sap/fe/core/helpers/MetaModelFunction.js +26 -40
  179. package/src/sap/fe/core/helpers/MetaPath.js +9 -7
  180. package/src/sap/fe/core/helpers/MetaPath.ts +9 -3
  181. package/src/sap/fe/core/helpers/ModelHelper.js +33 -57
  182. package/src/sap/fe/core/helpers/ModelHelper.ts +3 -3
  183. package/src/sap/fe/core/helpers/PasteHelper.js +11 -19
  184. package/src/sap/fe/core/helpers/PromiseKeeper.js +1 -1
  185. package/src/sap/fe/core/helpers/RecommendationHelper.js +3 -4
  186. package/src/sap/fe/core/helpers/ResourceModelHelper.js +3 -5
  187. package/src/sap/fe/core/helpers/SizeHelper.js +3 -5
  188. package/src/sap/fe/core/helpers/StableIdHelper.js +13 -11
  189. package/src/sap/fe/core/helpers/StableIdHelper.ts +5 -1
  190. package/src/sap/fe/core/helpers/StandardRecommendationHelper.js +28 -38
  191. package/src/sap/fe/core/helpers/Synchronization.js +1 -1
  192. package/src/sap/fe/core/helpers/TitleHelper.js +19 -40
  193. package/src/sap/fe/core/helpers/TitleHelper.ts +5 -25
  194. package/src/sap/fe/core/helpers/TypeGuards.js +25 -18
  195. package/src/sap/fe/core/helpers/TypeGuards.ts +7 -0
  196. package/src/sap/fe/core/helpers/WebSocket.js +4 -4
  197. package/src/sap/fe/core/library.js +8 -7
  198. package/src/sap/fe/core/library.ts +2 -0
  199. package/src/sap/fe/core/manifestMerger/AddNewPage.js +9 -11
  200. package/src/sap/fe/core/manifestMerger/ChangePageConfiguration.js +14 -25
  201. package/src/sap/fe/core/manifestMerger/ChangePageConfiguration.ts +15 -17
  202. package/src/sap/fe/core/messagebundle.properties +21 -0
  203. package/src/sap/fe/core/messagebundle_ar.properties +5 -1
  204. package/src/sap/fe/core/messagebundle_bg.properties +4 -0
  205. package/src/sap/fe/core/messagebundle_ca.properties +4 -0
  206. package/src/sap/fe/core/messagebundle_cnr.properties +4 -0
  207. package/src/sap/fe/core/messagebundle_cs.properties +8 -4
  208. package/src/sap/fe/core/messagebundle_cy.properties +4 -0
  209. package/src/sap/fe/core/messagebundle_da.properties +4 -0
  210. package/src/sap/fe/core/messagebundle_de.properties +4 -0
  211. package/src/sap/fe/core/messagebundle_el.properties +4 -0
  212. package/src/sap/fe/core/messagebundle_en.properties +4 -0
  213. package/src/sap/fe/core/messagebundle_en_GB.properties +4 -0
  214. package/src/sap/fe/core/messagebundle_en_US_saprigi.properties +4 -0
  215. package/src/sap/fe/core/messagebundle_en_US_saptrc.properties +249 -231
  216. package/src/sap/fe/core/messagebundle_es.properties +5 -1
  217. package/src/sap/fe/core/messagebundle_es_MX.properties +4 -0
  218. package/src/sap/fe/core/messagebundle_et.properties +4 -0
  219. package/src/sap/fe/core/messagebundle_fi.properties +4 -0
  220. package/src/sap/fe/core/messagebundle_fr.properties +6 -2
  221. package/src/sap/fe/core/messagebundle_fr_CA.properties +4 -0
  222. package/src/sap/fe/core/messagebundle_hi.properties +4 -0
  223. package/src/sap/fe/core/messagebundle_hr.properties +4 -0
  224. package/src/sap/fe/core/messagebundle_hu.properties +4 -0
  225. package/src/sap/fe/core/messagebundle_id.properties +4 -0
  226. package/src/sap/fe/core/messagebundle_it.properties +4 -0
  227. package/src/sap/fe/core/messagebundle_iw.properties +4 -0
  228. package/src/sap/fe/core/messagebundle_ja.properties +4 -0
  229. package/src/sap/fe/core/messagebundle_kk.properties +4 -0
  230. package/src/sap/fe/core/messagebundle_ko.properties +4 -0
  231. package/src/sap/fe/core/messagebundle_lt.properties +4 -0
  232. package/src/sap/fe/core/messagebundle_lv.properties +4 -0
  233. package/src/sap/fe/core/messagebundle_mk.properties +4 -0
  234. package/src/sap/fe/core/messagebundle_ms.properties +4 -0
  235. package/src/sap/fe/core/messagebundle_nl.properties +4 -0
  236. package/src/sap/fe/core/messagebundle_no.properties +4 -0
  237. package/src/sap/fe/core/messagebundle_pl.properties +4 -0
  238. package/src/sap/fe/core/messagebundle_pt.properties +4 -0
  239. package/src/sap/fe/core/messagebundle_pt_PT.properties +4 -0
  240. package/src/sap/fe/core/messagebundle_ro.properties +4 -0
  241. package/src/sap/fe/core/messagebundle_ru.properties +4 -0
  242. package/src/sap/fe/core/messagebundle_sh.properties +4 -0
  243. package/src/sap/fe/core/messagebundle_sk.properties +4 -0
  244. package/src/sap/fe/core/messagebundle_sl.properties +4 -0
  245. package/src/sap/fe/core/messagebundle_sr.properties +4 -0
  246. package/src/sap/fe/core/messagebundle_sv.properties +4 -0
  247. package/src/sap/fe/core/messagebundle_th.properties +4 -0
  248. package/src/sap/fe/core/messagebundle_tr.properties +5 -1
  249. package/src/sap/fe/core/messagebundle_uk.properties +4 -0
  250. package/src/sap/fe/core/messagebundle_vi.properties +4 -0
  251. package/src/sap/fe/core/messagebundle_zh_CN.properties +4 -0
  252. package/src/sap/fe/core/messagebundle_zh_TW.properties +4 -0
  253. package/src/sap/fe/core/operationsHelper.js +23 -27
  254. package/src/sap/fe/core/operationsHelper.ts +6 -7
  255. package/src/sap/fe/core/rootView/Fcl.controller.js +53 -40
  256. package/src/sap/fe/core/rootView/Fcl.controller.ts +42 -7
  257. package/src/sap/fe/core/rootView/NavContainer.controller.js +7 -10
  258. package/src/sap/fe/core/rootView/RootViewBaseController.js +22 -21
  259. package/src/sap/fe/core/rootView/RootViewBaseController.ts +10 -2
  260. package/src/sap/fe/core/services/AsyncComponentServiceFactory.js +3 -3
  261. package/src/sap/fe/core/services/CacheHandlerServiceFactory.js +4 -3
  262. package/src/sap/fe/core/services/CacheHandlerServiceFactory.ts +1 -0
  263. package/src/sap/fe/core/services/CollaborationManagerServiceFactory.js +12 -10
  264. package/src/sap/fe/core/services/CollaborationManagerServiceFactory.ts +6 -2
  265. package/src/sap/fe/core/services/CollaborativeToolsServiceFactory.js +8 -13
  266. package/src/sap/fe/core/services/ContextSharingServiceFactory.js +5 -7
  267. package/src/sap/fe/core/services/EnvironmentServiceFactory.js +31 -8
  268. package/src/sap/fe/core/services/EnvironmentServiceFactory.ts +31 -5
  269. package/src/sap/fe/core/services/InlineEditServiceFactory.js +190 -0
  270. package/src/sap/fe/core/services/InlineEditServiceFactory.ts +226 -0
  271. package/src/sap/fe/core/services/NavigationServiceFactory.js +10 -15
  272. package/src/sap/fe/core/services/ResourceModelServiceFactory.js +3 -3
  273. package/src/sap/fe/core/services/RoutingServiceFactory.js +76 -56
  274. package/src/sap/fe/core/services/RoutingServiceFactory.ts +47 -14
  275. package/src/sap/fe/core/services/ShellServicesFactory.js +32 -34
  276. package/src/sap/fe/core/services/SideEffectsServiceFactory.js +75 -60
  277. package/src/sap/fe/core/services/SideEffectsServiceFactory.ts +58 -12
  278. package/src/sap/fe/core/services/TelemetryServiceFactory.js +8 -9
  279. package/src/sap/fe/core/services/TemplatedViewServiceFactory.js +13 -18
  280. package/src/sap/fe/core/services/TemplatedViewServiceFactory.ts +3 -0
  281. package/src/sap/fe/core/services/ValueHelpHistoryServiceFactory.js +7 -9
  282. package/src/sap/fe/core/services/collaborativeDraftServiceFactory.js +12 -16
  283. package/src/sap/fe/core/services/collaborativeDraftServiceFactory.ts +1 -1
  284. package/src/sap/fe/core/services/valueHelpService/HistoryOptOutProvider.js +4 -7
  285. package/src/sap/fe/core/services/view/TemplatingErrorPage.controller.js +5 -6
  286. package/src/sap/fe/core/support/CommonHelper.js +2 -3
  287. package/src/sap/fe/core/support/Diagnostics.js +1 -1
  288. package/src/sap/fe/core/templating/ActionHelper.js +3 -4
  289. package/src/sap/fe/core/templating/CommonFormatters.js +6 -8
  290. package/src/sap/fe/core/templating/CommonFormatters.ts +2 -2
  291. package/src/sap/fe/core/templating/CriticalityFormatters.js +53 -5
  292. package/src/sap/fe/core/templating/CriticalityFormatters.ts +129 -7
  293. package/src/sap/fe/core/templating/DataFieldFormatters.js +8 -11
  294. package/src/sap/fe/core/templating/DataFieldFormatters.ts +1 -1
  295. package/src/sap/fe/core/templating/DataModelPathHelper.js +33 -56
  296. package/src/sap/fe/core/templating/DisplayModeFormatter.js +4 -5
  297. package/src/sap/fe/core/templating/EntitySetHelper.js +11 -19
  298. package/src/sap/fe/core/templating/EntityTypeHelper.js +4 -5
  299. package/src/sap/fe/core/templating/FieldControlHelper.js +13 -20
  300. package/src/sap/fe/core/templating/FilterTemplating.js +6 -9
  301. package/src/sap/fe/core/templating/PropertyHelper.js +33 -63
  302. package/src/sap/fe/core/templating/PropertyHelper.ts +0 -1
  303. package/src/sap/fe/core/templating/SemanticObjectHelper.js +13 -21
  304. package/src/sap/fe/core/templating/UIFormatters.js +57 -78
  305. package/src/sap/fe/core/templating/UIFormatters.ts +2 -1
  306. package/src/sap/fe/core/type/Date.js +2 -2
  307. package/src/sap/fe/core/type/DateTimeWithTimezone.js +3 -3
  308. package/src/sap/fe/core/type/EDM.js +3 -5
  309. package/src/sap/fe/core/type/Email.js +17 -6
  310. package/src/sap/fe/core/type/Email.ts +23 -4
  311. package/src/sap/fe/core/type/FiscalDate.js +8 -9
  312. package/src/sap/fe/core/type/InputMask.js +3 -4
  313. package/src/sap/fe/core/controllerextensions/dialog/OperationsDialog.block.js +0 -299
  314. package/src/sap/fe/core/controls/ActionParameterDialog.fragment.xml +0 -87
  315. package/src/sap/fe/core/controls/ActionParameterDialogValueHelp.fragment.xml +0 -43
  316. package/src/sap/fe/core/controls/DataLossOrDraftDiscard/DraftDataLossDialog.block.js +0 -251
  317. package/src/sap/fe/core/controls/Recommendations/ConfirmRecommendationDialog.block.js +0 -471
@@ -18,6 +18,7 @@ import type {
18
18
  DataField,
19
19
  DataFieldAbstractTypes,
20
20
  DataFieldForAction,
21
+ DataFieldForActionGroup,
21
22
  DataFieldForActionTypes,
22
23
  DataFieldForAnnotation,
23
24
  DataFieldForIntentBasedNavigation,
@@ -61,13 +62,16 @@ import {
61
62
  hasFieldGroupTarget,
62
63
  isDataField,
63
64
  isDataFieldForActionAbstract,
65
+ isDataFieldForActionGroup,
64
66
  isDataFieldForAnnotation,
65
67
  isDataFieldTypes,
66
68
  isDataPointFromDataFieldDefault,
67
- isRatingVisualizationFromDataFieldDefault
69
+ isRatingVisualizationFromDataFieldDefault,
70
+ visibleExpression
68
71
  } from "sap/fe/core/converters/annotations/DataField";
69
72
  import type {
70
73
  AnnotationAction,
74
+ AnnotationActionGroup,
71
75
  BaseAction,
72
76
  CombinedAction,
73
77
  CustomAction,
@@ -76,9 +80,12 @@ import type {
76
80
  import {
77
81
  dataFieldIsCopyAction,
78
82
  getActionsFromManifest,
83
+ getAnnotationMenuActionItems,
79
84
  getCopyAction,
80
85
  getEnabledForAnnotationAction,
81
- isActionNavigable,
86
+ getMatchingManifestAction,
87
+ getVisibilityEnablementMenuActions,
88
+ prepareMenuActions,
82
89
  removeDuplicateActions
83
90
  } from "sap/fe/core/converters/controls/Common/Action";
84
91
  import type { ConfigurableObject, CustomElement } from "sap/fe/core/converters/helpers/ConfigurableObject";
@@ -96,9 +103,11 @@ import {
96
103
  isProperty,
97
104
  isTypeDefinition
98
105
  } from "sap/fe/core/helpers/TypeGuards";
106
+ import { criticalityExpressionForIntegrationCards } from "sap/fe/core/templating/CriticalityFormatters";
99
107
  import {
100
108
  enhanceDataModelPath,
101
109
  getContextPropertyRestriction,
110
+ getContextRelativeTargetObjectPath,
102
111
  getHierarchyParentNavigationPropertyPath,
103
112
  getNonUpdatableNavigationProperties,
104
113
  getTargetObjectPath,
@@ -112,9 +121,12 @@ import { getRestrictionsOnProperties, type RestrictionsOnProperties } from "sap/
112
121
  import { hasFieldControlNotMandatory, isStaticallyMandatory } from "sap/fe/core/templating/FieldControlHelper";
113
122
  import {
114
123
  getAssociatedCurrencyProperty,
124
+ getAssociatedCurrencyPropertyPath,
115
125
  getAssociatedTextProperty,
126
+ getAssociatedTextPropertyPath,
116
127
  getAssociatedTimezoneProperty,
117
128
  getAssociatedUnitProperty,
129
+ getAssociatedUnitPropertyPath,
118
130
  getStaticTimezone,
119
131
  getStaticUnitOrCurrency,
120
132
  isTimezone
@@ -185,12 +197,28 @@ type UploadTableSettings = {
185
197
  maxLength?: int;
186
198
  uploadAction?: StandardAction;
187
199
  };
200
+
201
+ type RowNavigationInfo =
202
+ | {
203
+ type: "Outbound";
204
+ navigationTarget: string;
205
+ navigationInEditMode?: boolean;
206
+ }
207
+ | {
208
+ type: "Navigation";
209
+ targetPath: string;
210
+ checkEditable: boolean;
211
+ recreateContext: boolean;
212
+ routePath: string;
213
+ navigationInEditMode?: boolean;
214
+ };
215
+
188
216
  type RowConfiguration = {
189
217
  action?: string;
190
- press?: string;
191
- openInNewTabPress?: string;
218
+ navigationInfo?: RowNavigationInfo;
192
219
  rowHighlighting: CompiledBindingToolkitExpression;
193
220
  rowNavigated: CompiledBindingToolkitExpression;
221
+ rowCriticalityForInsights?: CompiledBindingToolkitExpression;
194
222
  visible?: CompiledBindingToolkitExpression;
195
223
  };
196
224
 
@@ -217,6 +245,10 @@ type TableAggregateConditions = Record<string, object>;
217
245
 
218
246
  type TableP13nMode = "Aggregate" | "Column" | "Filter" | "Group" | "Sort";
219
247
 
248
+ export type AnalyticalConfiguration = {
249
+ aggregationOnLeafLevel?: boolean;
250
+ };
251
+
220
252
  export type TableAnnotationConfiguration = {
221
253
  collection: string;
222
254
  variantManagement: VariantManagementType;
@@ -314,7 +346,7 @@ export type TableControlConfiguration = {
314
346
  inlineCreationRowsHiddenInEditMode?: boolean;
315
347
  massEdit: MassEditTableConfiguration;
316
348
  enableAutoColumnWidth: boolean;
317
- dataStateIndicatorFilter: string | undefined;
349
+ hasDataStateIndicatorFilter: boolean;
318
350
  isCompactType?: boolean;
319
351
  hierarchyQualifier?: string;
320
352
  isHierarchyParentNodeUpdatable?: boolean;
@@ -333,9 +365,10 @@ export type TableControlConfiguration = {
333
365
  exportRequestSize?: number;
334
366
  enableUploadPlugin?: boolean;
335
367
  modeForNoDataMessage?: string;
368
+ analyticalConfiguration?: AnalyticalConfiguration;
336
369
  };
337
370
  export type TableType = "GridTable" | "ResponsiveTable" | "AnalyticalTable" | "TreeTable";
338
- export type TableRowCountMode = "Auto" | "Fixed";
371
+ export type TableRowCountMode = "Auto" | "Fixed" | "Interactive";
339
372
 
340
373
  enum ColumnType {
341
374
  Default = "Default", // Default Type (Custom Column)
@@ -473,6 +506,7 @@ export type AnnotationTableColumn = AnnotationTableColumnForOverride & {
473
506
  visualSettings?: VisualSettings;
474
507
  typeConfig?: PropertyTypeConfig;
475
508
  isPartOfLineItem?: boolean; // temporary indicator to only allow filtering on navigation properties when they're part of a line item
509
+ isPartOfCustomColumn?: boolean;
476
510
  additionalLabels?: string[];
477
511
  exportDataPointTargetValue?: string;
478
512
  aggregatable?: boolean;
@@ -529,12 +563,9 @@ export type TableVisualization = {
529
563
  isInsightsEnabled?: boolean;
530
564
  header?: string;
531
565
  headerVisible?: boolean;
532
- clearSelectionOnFilter: boolean;
533
- events?: Record<string, string | undefined>;
566
+ handlePatchSent: boolean;
534
567
  };
535
568
 
536
- // maximum number of items to open in new tabs simultanously
537
- const selectionLimitForOpenInNewTab = 10;
538
569
  /**
539
570
  * Returns an array of all standard, annotation-based, and manifest-based table actions.
540
571
  * @param lineItemAnnotation
@@ -551,7 +582,9 @@ export function getTableActions(
551
582
  standardActions: StandardActionsConfiguration["standardActions"],
552
583
  navigationSettings?: NavigationSettingsConfiguration
553
584
  ): CombinedAction {
585
+ // 1. Get actions from annotations
554
586
  const tableActions = getTableAnnotationActions(lineItemAnnotation, visualizationPath, converterContext);
587
+ // 2. Get actions from manifest
555
588
  const manifestActions = getActionsFromManifest(
556
589
  converterContext.getManifestControlConfiguration<TableManifestConfiguration>(visualizationPath).actions as Record<
557
590
  string,
@@ -603,14 +636,28 @@ export function getTableActions(
603
636
  visibleForContextMenu: OverrideType.overwrite,
604
637
  defaultValuesExtensionFunction: OverrideType.overwrite,
605
638
  command: OverrideType.overwrite,
606
- position: OverrideType.overwrite
639
+ position: OverrideType.overwrite,
640
+ menu: OverrideType.overwrite
607
641
  };
608
- let actions = insertCustomElements(annotationAndStandardActions, nonStandardManifestActions, actionOverwriteConfig);
642
+ // 3. Get all annotation menu items
643
+ const annotationMenuActionItems = getAnnotationMenuActionItems(annotationActions);
644
+ // 4. Find manifest actions which override any annotation menu items
645
+ const matchingManifestActions = getMatchingManifestAction(annotationMenuActionItems, manifestActions.actions);
646
+ // 5. Get overridden annotation menu items
647
+ const overwrittenMenuActionItems = insertCustomElements(annotationMenuActionItems, matchingManifestActions, actionOverwriteConfig);
648
+ // 6. Override all actions
649
+ let actions = insertCustomElements(annotationAndStandardActions, nonStandardManifestActions, actionOverwriteConfig) as CustomAction[];
609
650
  actions = insertCustomElements(actions, standardManifestActions, {
610
651
  position: OverrideType.overwrite
611
652
  });
653
+ // 7. Replace original menu items with their corresponding overridden menu items
654
+ prepareMenuActions(actions, overwrittenMenuActionItems);
655
+ // 8. Remove duplicate actions which are menu items
656
+ actions = removeDuplicateActions(actions);
657
+ // 9. Hide menus where all menu items are hidden
658
+ actions = getVisibilityEnablementMenuActions(actions);
612
659
  return {
613
- actions,
660
+ actions: actions,
614
661
  commandActions: manifestActions.commandActions
615
662
  };
616
663
  }
@@ -620,22 +667,19 @@ export function getTableActions(
620
667
  * @param lineItemAnnotation Collection of data fields for representation in a table or list
621
668
  * @param visualizationPath
622
669
  * @param converterContext
623
- * @param navigationSettings
624
670
  * @returns Returns all table columns that should be available, regardless of templating or personalization or their origin
625
671
  */
626
672
  export function getTableColumns(
627
673
  lineItemAnnotation: LineItem,
628
674
  visualizationPath: string,
629
- converterContext: ConverterContext<PageContextPathTarget>,
630
- navigationSettings?: NavigationSettingsConfiguration
675
+ converterContext: ConverterContext<PageContextPathTarget>
631
676
  ): TableColumn[] {
632
677
  const annotationColumns = getColumnsFromAnnotations(lineItemAnnotation, visualizationPath, converterContext);
633
678
  const manifestColumns = getColumnsFromManifest(
634
679
  converterContext.getManifestControlConfiguration<TableManifestConfiguration>(visualizationPath).columns ?? {},
635
680
  annotationColumns,
636
681
  converterContext,
637
- converterContext.getAnnotationEntityType(lineItemAnnotation),
638
- navigationSettings
682
+ converterContext.getAnnotationEntityType(lineItemAnnotation)
639
683
  );
640
684
 
641
685
  const tableColumns: TableColumn[] = insertCustomElements(
@@ -787,7 +831,14 @@ export function updateTableVisualizationForType(
787
831
  } else {
788
832
  tableVisualization.requestAtLeast = ["HasActiveEntity"];
789
833
  }
834
+
835
+ // We always load 'HasDraftEntity' in a LR because it's needed to navigate to the draft instance if there's one when clicking on the active instance
836
+ if (ModelHelper.isDraftRoot(converterContext.getEntitySet())) {
837
+ tableVisualization.requestAtLeast.push("HasDraftEntity");
838
+ }
790
839
  }
840
+ } else {
841
+ Log.error(`Aggregation not supported for this entity type: ${entityType.name}`);
791
842
  }
792
843
  tableVisualization.control.type = "GridTable"; // AnalyticalTable isn't a real type for the MDC:Table, so we always switch back to Grid
793
844
  } else if (tableVisualization.control.type === "ResponsiveTable") {
@@ -808,6 +859,15 @@ export function updateTableVisualizationForType(
808
859
  tableVisualization.annotation.allowDropBetweenNodes =
809
860
  !!entityType.annotations.Hierarchy?.[`RecursiveHierarchyActions#${tableVisualization.control.hierarchyQualifier ?? ""}`]
810
861
  ?.ChangeNextSiblingAction;
862
+
863
+ // We always load 'HasDraftEntity' in a LR because it's needed to navigate to the draft instance if there's one when clicking on the active instance
864
+ if (ModelHelper.isDraftRoot(converterContext.getEntitySet())) {
865
+ if (tableVisualization.requestAtLeast) {
866
+ tableVisualization.requestAtLeast.push("HasDraftEntity");
867
+ } else {
868
+ tableVisualization.requestAtLeast = ["HasDraftEntity"];
869
+ }
870
+ }
811
871
  }
812
872
 
813
873
  if (tableVisualization.control.enableUploadPlugin) {
@@ -828,11 +888,6 @@ export function updateTableVisualizationForType(
828
888
  uploadAction: uploadAction
829
889
  };
830
890
  }
831
-
832
- // We don't keep table selection after searching/filtering, except in responsive tables
833
- if (tableVisualization.control.type !== "ResponsiveTable") {
834
- tableVisualization.clearSelectionOnFilter = true;
835
- }
836
891
  }
837
892
 
838
893
  /**
@@ -940,52 +995,99 @@ function findColumnByPath(path: string, tableColumns: TableColumn[]): TableColum
940
995
  }
941
996
  /**
942
997
  * Sets the 'unit', 'textArrangement', 'timezone' and 'exportsettings' properties in columns when necessary.
943
- * @param entityType The entity type displayed in the table
998
+ * @param converterContext The instance of the converter context
944
999
  * @param tableColumns The columns to be updated
945
1000
  */
946
- export function updateLinkedProperties(entityType: EntityType, tableColumns: TableColumn[]): void {
1001
+ export function updateLinkedProperties(converterContext: ConverterContext, tableColumns: TableColumn[]): void {
1002
+ const dataModelObjectPath = converterContext.getConverterContextFor(converterContext.getContextPath()).getDataModelObjectPath();
947
1003
  tableColumns.forEach((oColumn) => {
948
1004
  const tableColumn = oColumn as AnnotationTableColumn;
949
1005
  if (tableColumn.propertyInfos === undefined && tableColumn.relativePath) {
950
- const property = entityType.entityProperties.find((prop: Property) => prop.name === tableColumn.relativePath);
1006
+ const propertyDataModelObjectPath = enhanceDataModelPath<Property>(dataModelObjectPath, tableColumn.relativePath);
1007
+ const property = propertyDataModelObjectPath.targetObject;
951
1008
  if (property) {
952
- const unitProperty = getAssociatedCurrencyProperty(property) || getAssociatedUnitProperty(property);
1009
+ addCurrencyOrUoMToProperty(property, propertyDataModelObjectPath, tableColumns, tableColumn);
953
1010
  const timezoneProperty = getAssociatedTimezoneProperty(property);
954
1011
  const timezone = property?.annotations?.Common?.Timezone;
955
- if (unitProperty) {
956
- const unitColumn = findColumnByPath(unitProperty.name, tableColumns);
957
- tableColumn.unit = unitColumn?.name;
958
- } else {
959
- const unit = property?.annotations?.Measures?.ISOCurrency || property?.annotations?.Measures?.Unit;
960
- if (unit) {
961
- tableColumn.unitText = `${unit}`;
962
- }
963
- }
964
1012
  if (timezoneProperty) {
965
1013
  const oTimezoneColumn = findColumnByPath(timezoneProperty.name, tableColumns);
966
1014
  tableColumn.timezone = oTimezoneColumn?.name;
967
1015
  } else if (timezone) {
968
1016
  tableColumn.timezoneText = timezone.toString();
969
1017
  }
970
- const displayMode = getDisplayMode(property),
971
- textAnnotation = property.annotations.Common?.Text;
972
- if (isPathAnnotationExpression(textAnnotation) && displayMode !== "Value") {
973
- const textColumn = findColumnByPath(textAnnotation.path, tableColumns);
974
- if (textColumn && textColumn.name !== tableColumn.name) {
975
- tableColumn.textArrangement = {
976
- textProperty: textColumn.name,
977
- mode: displayMode
978
- };
979
- // If text properties are used but hidden, we must include them to the export as there are used in the paste
980
- if (!textColumn.exportSettings) {
981
- textColumn.exportSettings = { type: "String" };
982
- }
983
- }
984
- }
1018
+ addTextArrangentInfoToProperty(property, propertyDataModelObjectPath, tableColumns, tableColumn);
985
1019
  }
986
1020
  }
987
1021
  });
988
1022
  }
1023
+
1024
+ /**
1025
+ * Adds the "unit" property into the columns when neccesary for columns with unit of measure and currencies.
1026
+ * @param property The property referenced on the column
1027
+ * @param dataModelObjectPath The property DataModelObjectPath.
1028
+ * @param tableColumns The list of columns displayed on the table
1029
+ * @param tableColumn The table column which adds the currency or unit
1030
+ * @returns The updated property with the UoM or currency
1031
+ */
1032
+
1033
+ function addCurrencyOrUoMToProperty(
1034
+ property: Property,
1035
+ propertyDataModelObjectPath: DataModelObjectPath<Property>,
1036
+ tableColumns: TableColumn[],
1037
+ tableColumn: AnnotationTableColumn
1038
+ ): void {
1039
+ const currencyOrUoMProperty = getAssociatedCurrencyPropertyPath(property) || getAssociatedUnitPropertyPath(property);
1040
+ if (currencyOrUoMProperty) {
1041
+ const currencyOrUoMPropertyDataModelObjectPath = enhanceDataModelPath<Property>(propertyDataModelObjectPath, currencyOrUoMProperty);
1042
+ const currencyOrUoMRelativePath = getContextRelativeTargetObjectPath(currencyOrUoMPropertyDataModelObjectPath);
1043
+ if (currencyOrUoMRelativePath) {
1044
+ const unitColumn = findColumnByPath(currencyOrUoMRelativePath, tableColumns);
1045
+ tableColumn.unit = unitColumn?.name;
1046
+ }
1047
+ } else {
1048
+ const unit = property?.annotations?.Measures?.ISOCurrency || property?.annotations?.Measures?.Unit;
1049
+ if (unit) {
1050
+ tableColumn.unitText = `${unit}`;
1051
+ }
1052
+ }
1053
+ }
1054
+
1055
+ /**
1056
+ * Add the "textArrangement" object to columns when necessary for columns containing text, such as descriptions.
1057
+ * @param property The property referenced by the column
1058
+ * @param dataModelObjectPath The property DataModelObjectPath.
1059
+ * @param tableColumns The list of columns displayed on the table
1060
+ * @param tableColumn The table column which adds the text
1061
+ * @returns The updated property with text arrangement information
1062
+ */
1063
+
1064
+ function addTextArrangentInfoToProperty(
1065
+ property: Property,
1066
+ propertyDataModelObjectPath: DataModelObjectPath<Property>,
1067
+ tableColumns: TableColumn[],
1068
+ tableColumn: AnnotationTableColumn
1069
+ ): void {
1070
+ const displayMode = getDisplayMode(property),
1071
+ textPropertyPath = getAssociatedTextPropertyPath(property);
1072
+ if (textPropertyPath && displayMode !== "Value") {
1073
+ const textPropertyDataModelObjectPath = enhanceDataModelPath<Property>(propertyDataModelObjectPath, textPropertyPath);
1074
+ const textRelativePath = getContextRelativeTargetObjectPath(textPropertyDataModelObjectPath);
1075
+ if (textRelativePath) {
1076
+ const textColumn = findColumnByPath(textRelativePath, tableColumns);
1077
+ if (textColumn && textColumn.name !== tableColumn.name) {
1078
+ tableColumn.textArrangement = {
1079
+ textProperty: textColumn.name,
1080
+ mode: displayMode
1081
+ };
1082
+ // If text properties are used but hidden, we must include them to the export as there are used in the paste
1083
+ if (!textColumn.exportSettings) {
1084
+ textColumn.exportSettings = { type: "String" };
1085
+ }
1086
+ }
1087
+ }
1088
+ }
1089
+ }
1090
+
989
1091
  function getSemanticKeysAndTitleInfo(converterContext: ConverterContext<PageContextPathTarget>): {
990
1092
  headerInfoTitlePath: string;
991
1093
  semanticKeyColumns: string[];
@@ -1024,7 +1126,7 @@ export function createTableVisualization(
1024
1126
  const { navigationPropertyPath } = splitPath(visualizationPath);
1025
1127
  const navigationTargetPath = getNavigationTargetPath(converterContext, navigationPropertyPath);
1026
1128
  const navigationSettings = converterContext.getManifestWrapper().getNavigationConfiguration(navigationTargetPath);
1027
- const columns = getTableColumns(lineItemAnnotation, visualizationPath, converterContext, navigationSettings);
1129
+ const columns = getTableColumns(lineItemAnnotation, visualizationPath, converterContext);
1028
1130
  const operationAvailableMap = getOperationAvailableMap(lineItemAnnotation, converterContext);
1029
1131
  const semanticKeysAndHeaderInfoTitle = getSemanticKeysAndTitleInfo(converterContext);
1030
1132
  const standardActionsConfiguration = getStandardActionsConfiguration(
@@ -1058,7 +1160,7 @@ export function createTableVisualization(
1058
1160
  type: VisualizationType.Table,
1059
1161
  annotation: tableAnnotation,
1060
1162
  control: tableManifestConfig,
1061
- actions: removeDuplicateActions(tableActions.actions),
1163
+ actions: tableActions.actions,
1062
1164
  commandActions: tableActions.commandActions,
1063
1165
  columns: columns,
1064
1166
  operationAvailableMap: JSON.stringify(operationAvailableMap),
@@ -1071,15 +1173,9 @@ export function createTableVisualization(
1071
1173
  header: header,
1072
1174
  headerVisible: tableManifestConfig.headerVisible,
1073
1175
  requestAtLeast: createRequestedProperties(lineItemAnnotation, converterContext, operationAvailable, presentationVariantAnnotation),
1074
- clearSelectionOnFilter: false,
1075
- events: {
1076
- patchSent:
1077
- converterContext.getManifestWrapper().getTemplateType() !== TemplateType.ListReport
1078
- ? ".editFlow.handlePatchSent"
1079
- : undefined
1080
- }
1176
+ handlePatchSent: converterContext.getManifestWrapper().getTemplateType() !== TemplateType.ListReport
1081
1177
  };
1082
- updateLinkedProperties(converterContext.getAnnotationEntityType(lineItemAnnotation), columns);
1178
+ updateLinkedProperties(converterContext, columns);
1083
1179
  updateTableVisualizationForType(
1084
1180
  oVisualization,
1085
1181
  converterContext.getAnnotationEntityType(lineItemAnnotation),
@@ -1136,15 +1232,9 @@ export function createDefaultTableVisualization(
1136
1232
  enable$$getKeepAliveContext: true,
1137
1233
  header: tableManifestConfig.header,
1138
1234
  headerVisible: tableManifestConfig.headerVisible,
1139
- clearSelectionOnFilter: false,
1140
- events: {
1141
- patchSent:
1142
- converterContext.getManifestWrapper().getTemplateType() !== TemplateType.ListReport
1143
- ? ".editFlow.handlePatchSent"
1144
- : undefined
1145
- }
1235
+ handlePatchSent: converterContext.getManifestWrapper().getTemplateType() !== TemplateType.ListReport
1146
1236
  };
1147
- updateLinkedProperties(converterContext.getEntityType(), columns);
1237
+ updateLinkedProperties(converterContext, columns);
1148
1238
  updateTableVisualizationForType(oVisualization, converterContext.getEntityType(), converterContext);
1149
1239
  return oVisualization;
1150
1240
  }
@@ -1438,9 +1528,19 @@ export function getSelectionMode(
1438
1528
  cutButtonVisibilityExpression: BindingToolkitExpression<boolean> = constant(false)
1439
1529
  ): string | undefined {
1440
1530
  const tableManifestSettings = converterContext.getManifestControlConfiguration<TableManifestConfiguration>(visualizationPath);
1531
+ const tableType = tableManifestSettings.tableSettings?.type;
1441
1532
  let selectionMode = tableManifestSettings.tableSettings?.selectionMode;
1442
- // If the selection mode is forced to 'None' in the manifest/macro table parameters, we ignore the rest of the logic and keep it as specified
1533
+
1534
+ // The collapse/Expand action of a tree table is a bound action, as a result, a tree table should always have a selection mode to "Multi" when no selectionMode has been set in the manifest
1535
+ if (tableType === "TreeTable" && !selectionMode) {
1536
+ return SelectionMode.Multi;
1537
+ }
1538
+
1539
+ // If the selection mode is forced to 'None' in the manifest/macro table parameters, we keep it unless here is a delete button
1443
1540
  if (!lineItemAnnotation || selectionMode === SelectionMode.None) {
1541
+ if (targetCapabilities.isDeletable && deleteButtonVisibilityExpression) {
1542
+ return compileExpression(ifElse(deleteButtonVisibilityExpression, constant(SelectionMode.Multi), constant(SelectionMode.None)));
1543
+ }
1444
1544
  return SelectionMode.None;
1445
1545
  }
1446
1546
  if (selectionMode === SelectionMode.ForceMulti) {
@@ -1572,44 +1672,20 @@ function getTableAnnotationActions(
1572
1672
  lineItemAnnotation: LineItem,
1573
1673
  visualizationPath: string,
1574
1674
  converterContext: ConverterContext<PageContextPathTarget>
1575
- ): { tableActions: AnnotationAction[] } {
1576
- const tableActions: AnnotationAction[] = [];
1675
+ ): { tableActions: Array<AnnotationAction | AnnotationActionGroup> } {
1676
+ const tableActions: Array<AnnotationAction | AnnotationActionGroup> = [];
1577
1677
  const copyDataField = getCopyAction(
1578
1678
  lineItemAnnotation.filter((dataField) => {
1579
1679
  return dataFieldIsCopyAction(dataField as DataFieldForActionTypes);
1580
1680
  }) as DataFieldForActionTypes[]
1581
1681
  );
1582
- const sEntityType = converterContext.getEntityType().fullyQualifiedName;
1583
- const visibleExpression = function (
1584
- dataField: DataFieldForAction | DataFieldForIntentBasedNavigation | undefined
1585
- ): BindingToolkitExpression<boolean> {
1586
- return not(
1587
- equal(
1588
- getExpressionFromAnnotation(
1589
- dataField?.annotations?.UI?.Hidden,
1590
- [],
1591
- undefined,
1592
- converterContext.getRelativeModelPathFunction()
1593
- ),
1594
- true
1595
- )
1596
- );
1597
- };
1598
- // For the context menu, the visibility should also consider the 'inactiveContext' property:
1599
- // only when at least one selected context is active (i.e. "contextmenu/inactiveContext" is false), the action should be visible in the context menu
1600
- // This is only relevant when the table manifest setting "creationMode" is "InlineCreationRows"
1601
- const visibleForContextMenuExpression = function (
1602
- dataField: DataFieldForAction | DataFieldForIntentBasedNavigation | undefined
1603
- ): BindingToolkitExpression<boolean> {
1604
- return and(visibleExpression(dataField), equal(pathInModel("contextmenu/inactiveContext", "internal"), false));
1605
- };
1606
1682
  if (copyDataField) {
1607
1683
  tableActions.push({
1608
1684
  type: ActionType.Copy,
1609
1685
  annotationPath: converterContext.getEntitySetBasedAnnotationPath(copyDataField.fullyQualifiedName),
1610
1686
  key: KeyHelper.generateKeyFromDataField(copyDataField),
1611
- visible: compileExpression(visibleExpression(copyDataField)),
1612
- visibleForContextMenu: compileExpression(visibleForContextMenuExpression(copyDataField)),
1687
+ visible: compileExpression(visibleExpression(copyDataField, converterContext)),
1688
+ visibleForContextMenu: compileExpression(visibleForContextMenuExpression(copyDataField, converterContext)),
1613
1689
  text: copyDataField.Label?.toString() ?? Library.getResourceBundleFor("sap.fe.core")!.getText("C_COMMON_COPY"),
1614
1690
  isNavigable: true
1615
1691
  });
@@ -1624,39 +1700,75 @@ function getTableAnnotationActions(
1624
1700
  dataField.Inline?.valueOf() !== true &&
1625
1701
  dataField.Determining?.valueOf() !== true
1626
1702
  ) {
1627
- switch (dataField.$Type) {
1628
- case UIAnnotationTypes.DataFieldForAction:
1629
- const tableAction: AnnotationAction = {
1630
- type: ActionType.DataFieldForAction,
1631
- annotationPath: converterContext.getEntitySetBasedAnnotationPath(dataField.fullyQualifiedName),
1632
- key: KeyHelper.generateKeyFromDataField(dataField),
1633
- visible: compileExpression(visibleExpression(dataField)),
1634
- visibleForContextMenu: compileExpression(visibleForContextMenuExpression(dataField)),
1635
- isNavigable: true
1636
- };
1637
- if (_useEnabledExpression(dataField, sEntityType)) {
1638
- tableAction.enabled = getEnabledForAnnotationAction(converterContext, dataField.ActionTarget, true);
1639
- }
1640
- tableActions.push(tableAction);
1641
- break;
1642
- case UIAnnotationTypes.DataFieldForIntentBasedNavigation:
1643
- tableActions.push({
1644
- type: ActionType.DataFieldForIntentBasedNavigation,
1645
- annotationPath: converterContext.getEntitySetBasedAnnotationPath(dataField.fullyQualifiedName),
1646
- key: KeyHelper.generateKeyFromDataField(dataField),
1647
- visible: compileExpression(visibleExpression(dataField)),
1648
- visibleForContextMenu: compileExpression(visibleForContextMenuExpression(dataField))
1649
- });
1650
- break;
1651
- default:
1652
- break;
1703
+ const tableAction = getDataFieldAnnotationAction(dataField, converterContext);
1704
+ if (tableAction) {
1705
+ tableActions.push(tableAction);
1706
+ }
1707
+ } else if (isDataFieldForActionGroup(dataField)) {
1708
+ const dataFieldGroup = getDataFieldAnnotationAction(dataField, converterContext);
1709
+ if (dataFieldGroup) {
1710
+ tableActions.push(dataFieldGroup);
1653
1711
  }
1654
1712
  }
1655
1713
  });
1714
+
1656
1715
  return {
1657
1716
  tableActions
1658
1717
  };
1659
1718
  }
1719
+
1720
+ // For the context menu, the visibility should also consider the 'inactiveContext' property:
1721
+ // only when at least one selected context is active (i.e. "contextmenu/inactiveContext" is false), the action should be visible in the context menu
1722
+ // This is only relevant when the table manifest setting "creationMode" is "InlineCreationRows"
1723
+ function visibleForContextMenuExpression(
1724
+ dataField: DataFieldForAction | DataFieldForIntentBasedNavigation | DataFieldForActionGroup | undefined,
1725
+ converterContext: ConverterContext<PageContextPathTarget>
1726
+ ): BindingToolkitExpression<boolean> {
1727
+ return and(visibleExpression(dataField, converterContext), equal(pathInModel("contextmenu/inactiveContext", "internal"), false));
1728
+ }
1729
+
1730
+ function getDataFieldAnnotationAction(
1731
+ dataField: DataFieldAbstractTypes,
1732
+ converterContext: ConverterContext<PageContextPathTarget>
1733
+ ): AnnotationAction | AnnotationActionGroup | void {
1734
+ switch (dataField.$Type) {
1735
+ case UIAnnotationTypes.DataFieldForAction:
1736
+ const tableAction: AnnotationAction = {
1737
+ type: ActionType.DataFieldForAction,
1738
+ annotationPath: converterContext.getEntitySetBasedAnnotationPath(dataField.fullyQualifiedName),
1739
+ key: KeyHelper.generateKeyFromDataField(dataField),
1740
+ visible: compileExpression(visibleExpression(dataField, converterContext)),
1741
+ visibleForContextMenu: compileExpression(visibleForContextMenuExpression(dataField, converterContext)),
1742
+ isNavigable: true
1743
+ };
1744
+ const sEntityType = converterContext.getEntityType().fullyQualifiedName;
1745
+ if (_useEnabledExpression(dataField, sEntityType)) {
1746
+ tableAction.enabled = getEnabledForAnnotationAction(converterContext, dataField.ActionTarget, true);
1747
+ }
1748
+ return tableAction;
1749
+ case UIAnnotationTypes.DataFieldForIntentBasedNavigation:
1750
+ return {
1751
+ type: ActionType.DataFieldForIntentBasedNavigation,
1752
+ annotationPath: converterContext.getEntitySetBasedAnnotationPath(dataField.fullyQualifiedName),
1753
+ key: KeyHelper.generateKeyFromDataField(dataField),
1754
+ visible: compileExpression(visibleExpression(dataField, converterContext)),
1755
+ visibleForContextMenu: compileExpression(visibleForContextMenuExpression(dataField, converterContext))
1756
+ };
1757
+ case UIAnnotationTypes.DataFieldForActionGroup:
1758
+ return {
1759
+ type: ActionType.Menu,
1760
+ key: KeyHelper.generateKeyFromDataField(dataField),
1761
+ id: KeyHelper.generateKeyFromDataField(dataField),
1762
+ text: dataField.Label?.toString(),
1763
+ visible: compileExpression(visibleExpression(dataField, converterContext)),
1764
+ visibleForContextMenu: compileExpression(visibleForContextMenuExpression(dataField, converterContext)),
1765
+ menu: dataField.Actions.map((action) => getDataFieldAnnotationAction(action, converterContext))
1766
+ } as AnnotationActionGroup;
1767
+ default:
1768
+ return;
1769
+ }
1770
+ }
1771
+
1660
1772
  /**
1661
1773
  * Generate the bindingExpression for the highlight rowSetting parameter.
1662
1774
  * @param criticalityAnnotation Path or value of the criticality
@@ -1685,7 +1797,8 @@ function getHighlightRowBinding(
1685
1797
  isDraftRootOrNode && Entity.HasActive,
1686
1798
  isDraftRootOrNode && Entity.IsActive,
1687
1799
  `${isDraftRootOrNode}`,
1688
- pathInModel("@$ui5.fe.contextPath")
1800
+ pathInModel("@$ui5.fe.contextPath"),
1801
+ UI.IsInactive
1689
1802
  ],
1690
1803
  tableFormatters.rowHighlighting,
1691
1804
  targetEntityType
@@ -1775,31 +1888,34 @@ const _getRowConfigurationProperty = function (
1775
1888
  converterContext: ConverterContext<PageContextPathTarget>,
1776
1889
  navigationSettings: NavigationSettingsConfiguration,
1777
1890
  targetPath: string,
1778
- tableType: TableType
1891
+ tableType: TableType,
1892
+ disableNavigation?: boolean
1779
1893
  ): RowConfiguration {
1780
- let pressProperty, openInNewTabPressProperty, navigationTarget;
1894
+ let navigationInfo: RowNavigationInfo | undefined;
1781
1895
  let criticalityProperty: BindingToolkitExpression<MessageType> = constant(MessageType.None);
1782
1896
  const targetEntityType = converterContext.getEntityType();
1783
- if (navigationSettings && lineItemAnnotation) {
1784
- navigationTarget = navigationSettings.display?.target || navigationSettings.detail?.outbound;
1897
+ const criticalityAnnotation = lineItemAnnotation?.annotations?.UI?.Criticality;
1898
+ if (!disableNavigation && navigationSettings && lineItemAnnotation) {
1899
+ const navigationTarget = navigationSettings.display?.target || navigationSettings.detail?.outbound;
1785
1900
  const targetEntitySet = converterContext.getEntitySet();
1786
1901
  criticalityProperty = getHighlightRowBinding(
1787
- lineItemAnnotation.annotations?.UI?.Criticality,
1902
+ criticalityAnnotation,
1788
1903
  !!ModelHelper.getDraftRoot(targetEntitySet) || !!ModelHelper.getDraftNode(targetEntitySet),
1789
1904
  targetEntityType
1790
1905
  );
1791
1906
  if (navigationTarget) {
1792
- pressProperty = `API.onChevronPressNavigateOutBound($event, $controller ,'${navigationTarget}', \${$parameters>bindingContext})`;
1793
- openInNewTabPressProperty = `.onOpenInNewTabNavigateOutBound('${navigationTarget}', %{internal>contextmenu/selectedContexts}, "", ${selectionLimitForOpenInNewTab})`;
1907
+ navigationInfo = { type: "Outbound", navigationTarget };
1794
1908
  }
1795
1909
  if (!navigationTarget && navigationSettings.detail?.route) {
1796
- const editable =
1797
- ModelHelper.getDraftRoot(targetEntitySet) || ModelHelper.getDraftNode(targetEntitySet)
1798
- ? "!${$parameters>bindingContext}.getProperty('IsActiveEntity')"
1799
- : "undefined";
1800
- const recreateContext = tableType === "AnalyticalTable" ? ", recreateContext: true" : "";
1801
- pressProperty = `API.onTableRowPress($event, $controller, \${$parameters>bindingContext}, { callExtension: true, targetPath: '${targetPath}', editable: ${editable} ${recreateContext} })`; //Need to access to DraftRoot and DraftNode !!!!!!!
1802
- openInNewTabPressProperty = `API.onOpenInNewTabPress($event, $controller, %{internal>contextmenu/selectedContexts}, { callExtension: true, targetPath: '${targetPath}', navMode: 'openInNewTab' }, ${selectionLimitForOpenInNewTab})`;
1910
+ const checkEditable =
1911
+ ModelHelper.getDraftRoot(targetEntitySet) !== undefined || ModelHelper.getDraftNode(targetEntitySet) !== undefined;
1912
+ navigationInfo = {
1913
+ type: "Navigation",
1914
+ routePath: navigationSettings.detail.route,
1915
+ targetPath,
1916
+ checkEditable,
1917
+ recreateContext: tableType === "AnalyticalTable"
1918
+ };
1803
1919
  }
1804
1920
  }
1805
1921
  const rowNavigatedExpression: BindingToolkitExpression<boolean> = formatResult(
@@ -1808,11 +1924,11 @@ const _getRowConfigurationProperty = function (
1808
1924
  targetEntityType
1809
1925
  );
1810
1926
  return {
1811
- press: pressProperty,
1812
- openInNewTabPress: openInNewTabPressProperty,
1813
- action: pressProperty ? "Navigation" : undefined,
1927
+ navigationInfo,
1928
+ action: navigationInfo ? "Navigation" : undefined,
1814
1929
  rowHighlighting: compileExpression(criticalityProperty),
1815
1930
  rowNavigated: compileExpression(rowNavigatedExpression),
1931
+ rowCriticalityForInsights: criticalityAnnotation ? criticalityExpressionForIntegrationCards(criticalityAnnotation) : undefined,
1816
1932
  visible: compileExpression(not(UI.IsInactive))
1817
1933
  };
1818
1934
  };
@@ -1960,6 +2076,7 @@ export const getColumnsFromEntityType = function (
1960
2076
  * @param restrictionsOnProperties The existing restrictions on properties
1961
2077
  * @param tableCreationMode The creation mode of the table
1962
2078
  * @param relatedPropertiesInfo The properties identified so far for the column
2079
+ * @param relativePathForMultiValue The MDC path used for the 1:n property to allow filtering from MDC
1963
2080
  * @returns The annotation column definition
1964
2081
  */
1965
2082
  const getColumnDefinitionFromProperty = function (
@@ -1973,10 +2090,10 @@ const getColumnDefinitionFromProperty = function (
1973
2090
  displayModeOfDescriptionPropertiesMap: Record<string, DisplayMode>,
1974
2091
  restrictionsOnProperties?: RestrictionsOnProperties,
1975
2092
  tableCreationMode?: CreationMode,
1976
- relatedPropertiesInfo?: ComplexPropertyInfo
2093
+ relatedPropertiesInfo?: ComplexPropertyInfo,
2094
+ relativePathForMultiValue?: string
1977
2095
  ): AnnotationTableColumn | TechnicalColumn {
1978
- const name = useDataFieldPrefix ? relativePath : `Property::${relativePath}`;
1979
- const key = (useDataFieldPrefix ? "DataField::" : "Property::") + replaceSpecialChars(relativePath);
2096
+ let name, key;
1980
2097
  const semanticObjectAnnotationPath = getSemanticObjectPath(converterContext, property);
1981
2098
  const isHidden = isReferencePropertyStaticallyHidden(property);
1982
2099
  const groupPath: string | undefined = property.name ? _sliceAtSlash(property.name, true, false) : undefined;
@@ -2000,6 +2117,14 @@ const getColumnDefinitionFromProperty = function (
2000
2117
  const availability: AvailabilityType =
2001
2118
  !availableForAdaptation || isHidden || displayModeOfDescriptionPropertiesMap[relativePath] ? "Hidden" : "Adaptation";
2002
2119
  const collectedNavigationPropertyLabels: string[] | undefined = _getCollectedNavigationPropertyLabels(relativePath, converterContext);
2120
+ if (relativePathForMultiValue) {
2121
+ name = relativePathForMultiValue;
2122
+ key = "DataField::" + replaceSpecialChars(relativePathForMultiValue);
2123
+ relativePath = relativePathForMultiValue;
2124
+ } else {
2125
+ name = useDataFieldPrefix ? relativePath : `Property::${relativePath}`;
2126
+ key = (useDataFieldPrefix ? "DataField::" : "Property::") + replaceSpecialChars(relativePath);
2127
+ }
2003
2128
 
2004
2129
  const column: AnnotationTableColumn = {
2005
2130
  key: key,
@@ -2133,16 +2258,20 @@ const removeUndefinedFromExportSettings = function (exportSettings: ColumnExport
2133
2258
  * @param annotationColumns The array of columns created based on LineItem annotations.
2134
2259
  * @param columnsToBeCreated The columns to be created
2135
2260
  * @param columnInfo The column definition
2261
+ * @param columnName The name of the column
2136
2262
  */
2137
2263
  function updatePropertyLabel(
2138
2264
  annotationColumns: AnnotationTableColumn[],
2139
2265
  columnsToBeCreated: Record<string, Property>,
2140
- columnInfo: AnnotationTableColumn
2266
+ columnInfo: AnnotationTableColumn,
2267
+ columnName?: string
2141
2268
  ): void {
2142
- const linkedAnnotationColumns = annotationColumns.filter((col) => col.propertyInfos?.includes(columnInfo.relativePath));
2269
+ const linkedAnnotationColumns = annotationColumns.filter(
2270
+ (col) => col.propertyInfos?.includes(columnInfo.relativePath) || (columnName && col.propertyInfos?.includes(columnName))
2271
+ );
2143
2272
  if (
2144
2273
  linkedAnnotationColumns?.length === 1 &&
2145
- columnsToBeCreated[columnInfo.relativePath] &&
2274
+ (columnsToBeCreated[columnInfo.relativePath] || (columnName && columnsToBeCreated[columnName])) &&
2146
2275
  linkedAnnotationColumns[0].propertyInfos?.length === 1
2147
2276
  ) {
2148
2277
  columnInfo.label = linkedAnnotationColumns[0].label;
@@ -2386,7 +2515,29 @@ const _createRelatedColumns = function (
2386
2515
  annotationPath = converterContext.getAbsoluteAnnotationPath(name),
2387
2516
  // Check whether the related column already exists.
2388
2517
  relatedColumn = existingColumns.find((column) => column.name === name);
2389
- if (relatedColumn === undefined) {
2518
+ const dataModelObjectPath = converterContext.getConverterContextFor(converterContext.getContextPath()).getDataModelObjectPath();
2519
+ const propertyObjectPath = enhanceDataModelPath<PageContextPathTarget>(dataModelObjectPath, name);
2520
+ if (isMultiValueField(propertyObjectPath)) {
2521
+ const newNameRelativeTargetPath = getContextRelativeTargetObjectPath(propertyObjectPath, false, true);
2522
+ const column = getColumnDefinitionFromProperty(
2523
+ property,
2524
+ annotationPath,
2525
+ name,
2526
+ true,
2527
+ false,
2528
+ aggregationHelper,
2529
+ converterContext,
2530
+ displayModeOfDescriptionPropertiesMap,
2531
+ restrictionsOnProperties,
2532
+ tableCreationMode,
2533
+ undefined,
2534
+ newNameRelativeTargetPath
2535
+ );
2536
+ computeHiddenOnRelatedColumns(existingColumns, name, column);
2537
+ updatePropertyLabel(existingColumns, columnsToBeCreated, column, name);
2538
+ relatedColumns.push(column);
2539
+ relatedPropertyNameMap[name] = newNameRelativeTargetPath ?? name;
2540
+ } else if (relatedColumn === undefined) {
2390
2541
  // Case 1: Key contains DataField prefix to ensure all property columns have the same key format.
2391
2542
  // New created property column is set to hidden.
2392
2543
  const column = getColumnDefinitionFromProperty(
@@ -2610,12 +2761,22 @@ const _isColumnMultiValued = function (
2610
2761
  * @param dataField The data field being processed
2611
2762
  * @param propertyPath The property path
2612
2763
  * @param nonSortableColumns Collection of non-sortable column names as per annotation
2764
+ * @param relatedPropertiesInfo The related properties linked to the column
2613
2765
  * @returns True if the column is sortable
2614
2766
  */
2615
- const _isColumnSortable = function (dataField: DataFieldAbstractTypes, propertyPath: string, nonSortableColumns: string[]): boolean {
2767
+ const _isColumnSortable = function (
2768
+ dataField: DataFieldAbstractTypes,
2769
+ propertyPath: string,
2770
+ nonSortableColumns: string[],
2771
+ relatedPropertiesInfo: ComplexPropertyInfo
2772
+ ): boolean {
2616
2773
  return (
2617
2774
  !nonSortableColumns.includes(propertyPath) && // Column is not marked as non-sortable via annotation
2618
- (dataField.$Type === UIAnnotationTypes.DataField ||
2775
+ (((dataField.$Type === UIAnnotationTypes.DataField || dataField.$Type === UIAnnotationTypes.DataFieldForAnnotation) &&
2776
+ Object.keys(relatedPropertiesInfo.properties).some((propName) => {
2777
+ const isHidden = isReferencePropertyStaticallyHidden(relatedPropertiesInfo.properties[propName].annotationProperty);
2778
+ return !isHidden && !nonSortableColumns.includes(propName);
2779
+ })) ||
2619
2780
  dataField.$Type === UIAnnotationTypes.DataFieldWithUrl ||
2620
2781
  dataField.$Type === UIAnnotationTypes.DataFieldWithIntentBasedNavigation ||
2621
2782
  dataField.$Type === UIAnnotationTypes.DataFieldWithAction)
@@ -2964,7 +3125,9 @@ const getColumnsFromAnnotations = function (
2964
3125
  // for charts
2965
3126
  visualSettings.widthCalculation = null;
2966
3127
  }
2967
- const sortable = !isMultiValue && _isColumnSortable(dataField, relativePath, restrictionsOnProperties.nonSortableProperties);
3128
+ const sortable =
3129
+ !isMultiValue &&
3130
+ _isColumnSortable(dataField, relativePath, restrictionsOnProperties.nonSortableProperties, relatedPropertiesInfo);
2968
3131
  const availability = isReferencePropertyStaticallyHidden(dataField) ? "Hidden" : "Default";
2969
3132
  const column: AnnotationTableColumn = {
2970
3133
  key: KeyHelper.generateKeyFromDataField(dataField),
@@ -3248,18 +3411,16 @@ const _appendCustomTemplate = function (properties: string[] | undefined, export
3248
3411
  * @param annotationColumns
3249
3412
  * @param converterContext
3250
3413
  * @param entityType
3251
- * @param navigationSettings
3252
3414
  * @returns The columns from the manifest
3253
3415
  */
3254
3416
  const getColumnsFromManifest = function (
3255
3417
  columns: Record<string, CustomDefinedTableColumn | CustomDefinedTableColumnForOverride>,
3256
3418
  annotationColumns: AnnotationTableColumn[],
3257
3419
  converterContext: ConverterContext<PageContextPathTarget>,
3258
- entityType: EntityType,
3259
- navigationSettings?: NavigationSettingsConfiguration
3420
+ entityType: EntityType
3260
3421
  ): Record<string, ManifestColumn> {
3261
3422
  const internalColumns: Record<string, ManifestColumn> = {};
3262
- function isAnnotationColumn(
3423
+ function isColumnOverride(
3263
3424
  column: CustomDefinedTableColumn | CustomDefinedTableColumnForOverride,
3264
3425
  key: string
3265
3426
  ): column is CustomDefinedTableColumnForOverride {
@@ -3279,6 +3440,7 @@ const getColumnsFromManifest = function (
3279
3440
  prop.sortable = !restrictionsOnProperties.nonSortableProperties.includes(property.replace("Property::", ""));
3280
3441
  prop.isGroupable = prop.sortable;
3281
3442
  prop.filterable = !restrictionsOnProperties.nonFilterableProperties.includes(property.replace("Property::", ""));
3443
+ prop.isPartOfCustomColumn = true;
3282
3444
  }
3283
3445
  });
3284
3446
  });
@@ -3297,16 +3459,14 @@ const getColumnsFromManifest = function (
3297
3459
  },
3298
3460
  caseSensitive: isFilteringCaseSensitive(converterContext)
3299
3461
  };
3300
- if (isAnnotationColumn(manifestColumn, key)) {
3462
+ if (isColumnOverride(manifestColumn, key)) {
3301
3463
  const propertiesToOverwriteAnnotationColumn: CustomElement<AnnotationTableColumnForOverride> = {
3302
3464
  ...baseTableColumn,
3303
3465
  importance: manifestColumn?.importance,
3304
3466
  horizontalAlign: manifestColumn?.horizontalAlign,
3305
3467
  availability: manifestColumn?.availability,
3306
3468
  type: ColumnType.Annotation,
3307
- isNavigable: isAnnotationColumn(manifestColumn, key)
3308
- ? undefined
3309
- : isActionNavigable(manifestColumn, navigationSettings, true),
3469
+ isNavigable: undefined,
3310
3470
  settings: manifestColumn.settings,
3311
3471
  formatOptions: _getDefaultFormatOptionsForTable(manifestColumn.formatOptions),
3312
3472
  exportSettings: getCustomExportSettings(
@@ -3390,54 +3550,6 @@ const getColumnsFromManifest = function (
3390
3550
  return internalColumns;
3391
3551
  };
3392
3552
 
3393
- /**
3394
- * Adds references to columns that are needed to display the draft indicator column properly.
3395
- * @param draftIndicatorColumn
3396
- * @param tableColumns
3397
- * @param converterContext
3398
- */
3399
- function addReferencesForDraftIndicatorColumn(
3400
- draftIndicatorColumn: ComputedTableColumn,
3401
- tableColumns: TableColumn[],
3402
- converterContext: ConverterContext<PageContextPathTarget>
3403
- ): void {
3404
- function createRelatedColumn(propertyPath: string): void {
3405
- const key = "Property_Technical::" + propertyPath.replace(/\//g, ":");
3406
- const newColumn: TechnicalColumn = {
3407
- key,
3408
- name: key,
3409
- annotationPath: converterContext.getAbsoluteAnnotationPath(propertyPath),
3410
- relativePath: propertyPath,
3411
- isGroupable: false,
3412
- sortable: false,
3413
- availability: "Hidden",
3414
- caseSensitive: false,
3415
- type: ColumnType.Annotation,
3416
- extension: {
3417
- technicallyAggregatable: false,
3418
- technicallyGroupable: true
3419
- }
3420
- };
3421
- tableColumns.push(newColumn);
3422
- draftIndicatorColumn.propertyInfos!.push(key);
3423
- }
3424
-
3425
- draftIndicatorColumn.propertyInfos = [];
3426
- createRelatedColumn("HasDraftEntity");
3427
- createRelatedColumn("DraftAdministrativeData/InProcessByUser");
3428
- createRelatedColumn("DraftAdministrativeData/LastChangedByUser");
3429
- createRelatedColumn("DraftAdministrativeData/LastChangeDateTime");
3430
-
3431
- const draftAdminDataProperties = enhanceDataModelPath(converterContext.getDataModelObjectPath(), "DraftAdministrativeData")
3432
- .targetEntityType.entityProperties;
3433
- if (draftAdminDataProperties.find((prop) => prop.name === "InProcessByUserDescription")) {
3434
- createRelatedColumn("DraftAdministrativeData/InProcessByUserDescription");
3435
- }
3436
- if (draftAdminDataProperties.find((prop) => prop.name === "LastChangedByUserDescription")) {
3437
- createRelatedColumn("DraftAdministrativeData/LastChangedByUserDescription");
3438
- }
3439
- }
3440
-
3441
3553
  /**
3442
3554
  * Adds computed columns such as the draft status and situations status.
3443
3555
  * @param tableColumns The table columns collected so far
@@ -3531,11 +3643,6 @@ export function addComputedColumns(
3531
3643
  columnIndexToInsertAfter = tableColumns.findIndex((column) => column.availability !== "Hidden");
3532
3644
  }
3533
3645
  tableColumns.splice(columnIndexToInsertAfter + 1, 0, draftIndicatorColumn);
3534
-
3535
- // On an analytical table, we need to explicitely load some data for the draft indicator column --> we add referenced columns for that
3536
- if (tableType === "AnalyticalTable") {
3537
- addReferencesForDraftIndicatorColumn(draftIndicatorColumn, tableColumns, converterContext);
3538
- }
3539
3646
  }
3540
3647
 
3541
3648
  return tableColumns;
@@ -3662,7 +3769,7 @@ function getInitialExpansionLevel(presentationVariantAnnotation: PresentationVar
3662
3769
  return undefined;
3663
3770
  }
3664
3771
  const level = presentationVariantAnnotation.InitialExpansionLevel?.valueOf();
3665
- return typeof level === "number" ? level : undefined;
3772
+ return typeof level === "number" ? level + 1 : undefined;
3666
3773
  }
3667
3774
  /**
3668
3775
  * Converts an array of propertyPath to an array of propertyInfo names.
@@ -3727,6 +3834,11 @@ function _updatePropertyInfosWithAggregatesDefinitions(tableVisualization: Table
3727
3834
  const aggregatablePropertyDefinition = tableVisualization.analyticsExtensions![aggregatablePropertyName];
3728
3835
  column.aggregatable = !aggregatablePropertyDefinition.fromGroupableProperty;
3729
3836
  column.extension = aggregatablePropertyDefinition ?? {};
3837
+ if (!column.isGroupable && !column.aggregatable) {
3838
+ // The column is neither aggregatable nor groupable --> it's a hidden column to allow filtering in P13N
3839
+ // We need to remove additionalProperties, as it's not needed and causes an error in the MDC table code
3840
+ delete column.extension.additionalProperties;
3841
+ }
3730
3842
  }
3731
3843
  if (column.additionalPropertyInfos?.length) {
3732
3844
  column.additionalPropertyInfos.forEach((additionalPropertyInfo) => {
@@ -3931,7 +4043,8 @@ export function getTableAnnotationConfiguration(
3931
4043
  converterContext,
3932
4044
  navigationSettings,
3933
4045
  navigationTargetPath,
3934
- tableManifestConfiguration.type
4046
+ tableManifestConfiguration.type,
4047
+ tableManifestConfiguration.analyticalConfiguration?.aggregationOnLeafLevel // the navigation is disabled if the aggregationOnLeafLevel is set to true
3935
4048
  ),
3936
4049
  p13nMode,
3937
4050
  isInsertUpdateActionsTemplated: standardActionsConfiguration.isInsertUpdateActionsTemplated,
@@ -4091,7 +4204,7 @@ function _getTableMode(
4091
4204
  } else {
4092
4205
  return {
4093
4206
  rowCountMode: tableSettings.rowCountMode ?? "Fixed",
4094
- rowCount: tableSettings.rowCount ? tableSettings.rowCount : 5
4207
+ rowCount: tableSettings.rowCount ?? (tableType === "GridTable" ? 5 : 10)
4095
4208
  };
4096
4209
  }
4097
4210
  } else {
@@ -4402,7 +4515,6 @@ export function getTableManifestConfiguration(
4402
4515
  const enableAutoColumnWidth = !_manifestWrapper.isPhone();
4403
4516
  const disableCopyToClipboard = tableSettings.disableCopyToClipboard;
4404
4517
  const templateType = converterContext.getTemplateType();
4405
- const dataStateIndicatorFilter = templateType === TemplateType.ListReport ? "API.dataStateIndicatorFilter" : undefined;
4406
4518
  const isCondensedTableLayoutCompliant = checkCondensedLayout && _manifestWrapper.isCondensedLayoutCompliant();
4407
4519
  const oFilterConfiguration = lineItemAnnotation
4408
4520
  ? getFilterConfiguration(tableSettings, lineItemAnnotation, converterContext, selectionVariantAnnotation)
@@ -4410,6 +4522,7 @@ export function getTableManifestConfiguration(
4410
4522
  const customValidationFunction = tableSettings.creationMode?.customValidationFunction;
4411
4523
  const exportRequestSize = tableSettings.exportRequestSize;
4412
4524
  const tableType = getTableType(converterContext, tableManifestSettings);
4525
+ const analyticalConfiguration = tableSettings.analyticalConfiguration;
4413
4526
  // By default, paste is enabled on an ObjectPage and on a ListReport with a draft TreeTable
4414
4527
  const enablePaste =
4415
4528
  tableSettings.enablePaste ??
@@ -4443,12 +4556,13 @@ export function getTableManifestConfiguration(
4443
4556
  ? getFieldList(tableSettings.creationMode?.creationFields, converterContext)
4444
4557
  : undefined,
4445
4558
  customValidationFunction: customValidationFunction,
4446
- dataStateIndicatorFilter: dataStateIndicatorFilter,
4559
+ hasDataStateIndicatorFilter: templateType === TemplateType.ListReport,
4447
4560
  // if a custom validation function is provided, disableAddRowButtonForEmptyData should not be considered, i.e. set to false
4448
4561
  disableAddRowButtonForEmptyData: !customValidationFunction ? !!tableSettings.creationMode?.disableAddRowButtonForEmptyData : false,
4449
4562
  enableAutoColumnWidth: enableAutoColumnWidth,
4450
4563
  enablePastingOfComputedProperties: tableSettings.enablePastingOfComputedProperties,
4451
4564
  enableExport: _getEnableExport(tableSettings, converterContext, enablePaste),
4565
+ analyticalConfiguration,
4452
4566
  frozenColumnCount: _getFrozenColumnCount(tableSettings),
4453
4567
  widthIncludingColumnHeader: _getWidthIncludingColumnHeader(tableSettings),
4454
4568
  enableFullScreen: _getFullScreenBasedOnDevice(tableSettings, converterContext, _manifestWrapper.isPhone()),
@@ -4627,7 +4741,9 @@ function addPropertyToDisplayModeOfDescriptionPropertiesMap(
4627
4741
  */
4628
4742
  function computeHiddenOnRelatedColumns(existingColumns: AnnotationTableColumn[], name: string, column: AnnotationTableColumn): void {
4629
4743
  const relatedAnnotationColumns = existingColumns.filter(
4630
- (existingColumn) => existingColumn.propertyInfos?.includes(name) && existingColumn.isPartOfLineItem
4744
+ (existingColumn) =>
4745
+ (existingColumn.propertyInfos?.includes(name) && existingColumn.isPartOfLineItem) ||
4746
+ (existingColumn.isPartOfLineItem && existingColumn.relativePath === column.relativePath)
4631
4747
  );
4632
4748
  column.isPartOfLineItem = !!relatedAnnotationColumns.length;
4633
4749
  if (