@sapui5/sap.fe.core 1.97.0 → 1.100.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 (306) hide show
  1. package/package.json +7 -4
  2. package/src/sap/fe/core/.library +1 -1
  3. package/src/sap/fe/core/AnnotationHelper.js +309 -405
  4. package/src/sap/fe/core/AnnotationHelper.ts +315 -0
  5. package/src/sap/fe/core/AppComponent.js +389 -397
  6. package/src/sap/fe/core/AppComponent.ts +403 -0
  7. package/src/sap/fe/core/AppStateHandler.js +198 -181
  8. package/src/sap/fe/core/AppStateHandler.ts +171 -0
  9. package/src/sap/fe/core/BaseController.js +83 -58
  10. package/src/sap/fe/core/BaseController.ts +68 -0
  11. package/src/sap/fe/core/BusyLocker.js +105 -121
  12. package/src/sap/fe/core/BusyLocker.ts +98 -0
  13. package/src/sap/fe/core/CommonUtils.js +2164 -2379
  14. package/src/sap/fe/core/CommonUtils.ts +2177 -0
  15. package/src/sap/fe/core/ExtensionAPI.js +279 -266
  16. package/src/sap/fe/core/ExtensionAPI.ts +250 -0
  17. package/src/sap/fe/core/PageController.js +218 -125
  18. package/src/sap/fe/core/PageController.ts +129 -0
  19. package/src/sap/fe/core/RouterProxy.js +924 -807
  20. package/src/sap/fe/core/RouterProxy.ts +840 -0
  21. package/src/sap/fe/core/Synchronization.js +41 -35
  22. package/src/sap/fe/core/Synchronization.ts +29 -0
  23. package/src/sap/fe/core/TemplateComponent.js +173 -155
  24. package/src/sap/fe/core/TemplateComponent.ts +173 -0
  25. package/src/sap/fe/core/TemplateModel.js +79 -54
  26. package/src/sap/fe/core/TemplateModel.ts +63 -0
  27. package/src/sap/fe/core/TransactionHelper.js +1560 -1579
  28. package/src/sap/fe/core/TransactionHelper.ts +1717 -0
  29. package/src/sap/fe/core/actions/collaboration/ActivitySync.js +392 -0
  30. package/src/sap/fe/core/actions/collaboration/ActivitySync.ts +355 -0
  31. package/src/sap/fe/core/actions/collaboration/CollaborationCommon.js +136 -0
  32. package/src/sap/fe/core/actions/collaboration/CollaborationCommon.ts +119 -0
  33. package/src/sap/fe/core/actions/collaboration/Manage.js +262 -0
  34. package/src/sap/fe/core/actions/collaboration/Manage.ts +244 -0
  35. package/src/sap/fe/core/actions/collaboration/ManageDialog.fragment.xml +103 -0
  36. package/src/sap/fe/core/actions/collaboration/UserDetails.fragment.xml +13 -0
  37. package/src/sap/fe/core/actions/draft.js +521 -581
  38. package/src/sap/fe/core/actions/draft.ts +566 -0
  39. package/src/sap/fe/core/actions/messageHandling.js +564 -511
  40. package/src/sap/fe/core/actions/messageHandling.ts +552 -0
  41. package/src/sap/fe/core/actions/nonDraft.js +17 -19
  42. package/src/sap/fe/core/actions/nonDraft.ts +12 -0
  43. package/src/sap/fe/core/actions/operations.js +1093 -1211
  44. package/src/sap/fe/core/actions/operations.ts +1192 -0
  45. package/src/sap/fe/core/actions/sticky.js +114 -104
  46. package/src/sap/fe/core/actions/sticky.ts +119 -0
  47. package/src/sap/fe/core/controllerextensions/ControllerExtensionMetadata.js +70 -66
  48. package/src/sap/fe/core/controllerextensions/ControllerExtensionMetadata.ts +65 -0
  49. package/src/sap/fe/core/controllerextensions/EditFlow.js +1594 -1701
  50. package/src/sap/fe/core/controllerextensions/EditFlow.ts +1672 -0
  51. package/src/sap/fe/core/controllerextensions/IntentBasedNavigation.js +80 -54
  52. package/src/sap/fe/core/controllerextensions/IntentBasedNavigation.ts +61 -0
  53. package/src/sap/fe/core/controllerextensions/InternalEditFlow.js +719 -505
  54. package/src/sap/fe/core/controllerextensions/InternalEditFlow.ts +783 -0
  55. package/src/sap/fe/core/controllerextensions/InternalIntentBasedNavigation.js +797 -813
  56. package/src/sap/fe/core/controllerextensions/InternalIntentBasedNavigation.ts +803 -0
  57. package/src/sap/fe/core/controllerextensions/InternalRouting.js +1005 -973
  58. package/src/sap/fe/core/controllerextensions/InternalRouting.ts +978 -0
  59. package/src/sap/fe/core/controllerextensions/KPIManagement.js +530 -476
  60. package/src/sap/fe/core/controllerextensions/KPIManagement.ts +137 -46
  61. package/src/sap/fe/core/controllerextensions/MassEdit.js +144 -0
  62. package/src/sap/fe/core/controllerextensions/MassEdit.ts +156 -0
  63. package/src/sap/fe/core/controllerextensions/MessageHandler.js +234 -232
  64. package/src/sap/fe/core/controllerextensions/MessageHandler.ts +225 -0
  65. package/src/sap/fe/core/controllerextensions/PageReady.js +302 -337
  66. package/src/sap/fe/core/controllerextensions/PageReady.ts +23 -17
  67. package/src/sap/fe/core/controllerextensions/Paginator.js +189 -148
  68. package/src/sap/fe/core/controllerextensions/Paginator.ts +163 -0
  69. package/src/sap/fe/core/controllerextensions/Placeholder.js +158 -146
  70. package/src/sap/fe/core/controllerextensions/Placeholder.ts +151 -0
  71. package/src/sap/fe/core/controllerextensions/Routing.js +145 -106
  72. package/src/sap/fe/core/controllerextensions/Routing.ts +132 -0
  73. package/src/sap/fe/core/controllerextensions/RoutingListener.js +8 -6
  74. package/src/sap/fe/core/controllerextensions/RoutingListener.ts +3 -0
  75. package/src/sap/fe/core/controllerextensions/Share.js +220 -244
  76. package/src/sap/fe/core/controllerextensions/Share.ts +231 -0
  77. package/src/sap/fe/core/controllerextensions/SideEffects.js +593 -634
  78. package/src/sap/fe/core/controllerextensions/SideEffects.ts +29 -27
  79. package/src/sap/fe/core/controllerextensions/ViewState.js +789 -806
  80. package/src/sap/fe/core/controllerextensions/ViewState.ts +805 -0
  81. package/src/sap/fe/core/controls/ActionParameterDialog.fragment.xml +4 -3
  82. package/src/sap/fe/core/controls/ActionPartial.fragment.xml +2 -2
  83. package/src/sap/fe/core/controls/CommandExecution.js +68 -66
  84. package/src/sap/fe/core/controls/CommandExecution.ts +72 -0
  85. package/src/sap/fe/core/controls/ConditionalWrapper.js +91 -75
  86. package/src/sap/fe/core/controls/ConditionalWrapper.ts +83 -0
  87. package/src/sap/fe/core/controls/CustomQuickViewPage.js +131 -125
  88. package/src/sap/fe/core/controls/CustomQuickViewPage.ts +126 -0
  89. package/src/sap/fe/core/controls/DataLossOrDraftDiscard/DataLossOrDraftDiscardHandler.js +105 -110
  90. package/src/sap/fe/core/controls/DataLossOrDraftDiscard/DataLossOrDraftDiscardHandler.ts +101 -0
  91. package/src/sap/fe/core/controls/FieldWrapper.js +122 -140
  92. package/src/sap/fe/core/controls/FieldWrapper.ts +115 -0
  93. package/src/sap/fe/core/controls/FilterBar.js +163 -159
  94. package/src/sap/fe/core/controls/FilterBar.ts +143 -0
  95. package/src/sap/fe/core/controls/FormElementWrapper.js +46 -44
  96. package/src/sap/fe/core/controls/FormElementWrapper.ts +40 -0
  97. package/src/sap/fe/core/controls/MultiValueParameterDelegate.js +38 -42
  98. package/src/sap/fe/core/controls/MultiValueParameterDelegate.ts +31 -0
  99. package/src/sap/fe/core/controls/NonComputedVisibleKeyFieldsDialog.fragment.xml +2 -1
  100. package/src/sap/fe/core/controls/filterbar/FilterContainer.js +127 -116
  101. package/src/sap/fe/core/controls/filterbar/FilterContainer.ts +98 -0
  102. package/src/sap/fe/core/controls/filterbar/VisualFilter.js +242 -255
  103. package/src/sap/fe/core/controls/filterbar/VisualFilter.ts +245 -0
  104. package/src/sap/fe/core/controls/filterbar/VisualFilterContainer.js +151 -141
  105. package/src/sap/fe/core/controls/filterbar/VisualFilterContainer.ts +125 -0
  106. package/src/sap/fe/core/controls/filterbar/utils/VisualFilterUtils.js +336 -322
  107. package/src/sap/fe/core/controls/filterbar/utils/VisualFilterUtils.ts +337 -0
  108. package/src/sap/fe/core/controls/massEdit/MassEditDialog.fragment.xml +106 -0
  109. package/src/sap/fe/core/controls/massEdit/MassEditHandlers.js +79 -0
  110. package/src/sap/fe/core/controls/massEdit/MassEditHandlers.ts +70 -0
  111. package/src/sap/fe/core/converters/ConverterContext.js +348 -367
  112. package/src/sap/fe/core/converters/ConverterContext.ts +33 -19
  113. package/src/sap/fe/core/converters/ManifestSettings.js +12 -1
  114. package/src/sap/fe/core/converters/ManifestSettings.ts +16 -1
  115. package/src/sap/fe/core/converters/ManifestWrapper.js +354 -354
  116. package/src/sap/fe/core/converters/ManifestWrapper.ts +34 -6
  117. package/src/sap/fe/core/converters/MetaModelConverter.js +72 -9
  118. package/src/sap/fe/core/converters/MetaModelConverter.ts +75 -16
  119. package/src/sap/fe/core/converters/TemplateConverter.js +1 -1
  120. package/src/sap/fe/core/converters/TemplateConverter.ts +4 -3
  121. package/src/sap/fe/core/converters/annotations/DataField.js +28 -14
  122. package/src/sap/fe/core/converters/annotations/DataField.ts +38 -14
  123. package/src/sap/fe/core/converters/common/AnnotationConverter.js +33 -21
  124. package/src/sap/fe/core/converters/controls/Common/Action.js +11 -2
  125. package/src/sap/fe/core/converters/controls/Common/Action.ts +8 -2
  126. package/src/sap/fe/core/converters/controls/Common/Chart.js +5 -3
  127. package/src/sap/fe/core/converters/controls/Common/Chart.ts +11 -3
  128. package/src/sap/fe/core/converters/controls/Common/DataVisualization.js +3 -3
  129. package/src/sap/fe/core/converters/controls/Common/DataVisualization.ts +2 -2
  130. package/src/sap/fe/core/converters/controls/Common/Form.js +21 -11
  131. package/src/sap/fe/core/converters/controls/Common/Form.ts +28 -6
  132. package/src/sap/fe/core/converters/controls/Common/KPI.js +69 -4
  133. package/src/sap/fe/core/converters/controls/Common/KPI.ts +75 -2
  134. package/src/sap/fe/core/converters/controls/Common/Table.js +507 -408
  135. package/src/sap/fe/core/converters/controls/Common/Table.ts +618 -500
  136. package/src/sap/fe/core/converters/controls/Common/table/StandardActions.js +592 -0
  137. package/src/sap/fe/core/converters/controls/Common/table/StandardActions.ts +718 -0
  138. package/src/sap/fe/core/converters/controls/ListReport/FilterBar.js +465 -59
  139. package/src/sap/fe/core/converters/controls/ListReport/FilterBar.ts +462 -72
  140. package/src/sap/fe/core/converters/controls/ListReport/VisualFilters.js +2 -2
  141. package/src/sap/fe/core/converters/controls/ListReport/VisualFilters.ts +1 -1
  142. package/src/sap/fe/core/converters/controls/ObjectPage/SubSection.js +17 -9
  143. package/src/sap/fe/core/converters/controls/ObjectPage/SubSection.ts +24 -9
  144. package/src/sap/fe/core/converters/helpers/Aggregation.js +118 -121
  145. package/src/sap/fe/core/converters/helpers/Aggregation.ts +28 -5
  146. package/src/sap/fe/core/converters/helpers/BindingHelper.js +20 -6
  147. package/src/sap/fe/core/converters/helpers/BindingHelper.ts +16 -4
  148. package/src/sap/fe/core/converters/helpers/ConfigurableObject.js +12 -1
  149. package/src/sap/fe/core/converters/helpers/ConfigurableObject.ts +11 -0
  150. package/src/sap/fe/core/converters/helpers/IssueManager.js +7 -1
  151. package/src/sap/fe/core/converters/helpers/IssueManager.ts +6 -0
  152. package/src/sap/fe/core/converters/helpers/Key.js +42 -57
  153. package/src/sap/fe/core/converters/helpers/Key.ts +1 -1
  154. package/src/sap/fe/core/converters/objectPage/HeaderAndFooterAction.js +28 -7
  155. package/src/sap/fe/core/converters/objectPage/HeaderAndFooterAction.ts +23 -6
  156. package/src/sap/fe/core/converters/templates/ListReportConverter.js +20 -7
  157. package/src/sap/fe/core/converters/templates/ListReportConverter.ts +36 -14
  158. package/src/sap/fe/core/converters/templates/ObjectPageConverter.js +7 -5
  159. package/src/sap/fe/core/converters/templates/ObjectPageConverter.ts +5 -1
  160. package/src/sap/fe/core/designtime/AppComponent.designtime.js +93 -90
  161. package/src/sap/fe/core/designtime/AppComponent.designtime.ts +91 -0
  162. package/src/sap/fe/core/formatters/CollaborationFormatter.js +104 -0
  163. package/src/sap/fe/core/formatters/CollaborationFormatter.ts +60 -0
  164. package/src/sap/fe/core/formatters/CriticalityFormatter.js +1 -1
  165. package/src/sap/fe/core/formatters/CriticalityFormatter.ts +1 -1
  166. package/src/sap/fe/core/formatters/FPMFormatter.js +1 -1
  167. package/src/sap/fe/core/formatters/FPMFormatter.ts +4 -10
  168. package/src/sap/fe/core/formatters/KPIFormatter.js +1 -1
  169. package/src/sap/fe/core/formatters/KPIFormatter.ts +3 -1
  170. package/src/sap/fe/core/formatters/TableFormatter.js +91 -29
  171. package/src/sap/fe/core/formatters/TableFormatter.ts +94 -28
  172. package/src/sap/fe/core/formatters/ValueFormatter.js +30 -5
  173. package/src/sap/fe/core/formatters/ValueFormatter.ts +30 -7
  174. package/src/sap/fe/core/fpm/Component.js +51 -54
  175. package/src/sap/fe/core/fpm/Component.ts +48 -0
  176. package/src/sap/fe/core/helpers/AppStartupHelper.js +373 -0
  177. package/src/sap/fe/core/helpers/AppStartupHelper.ts +417 -0
  178. package/src/sap/fe/core/helpers/BindingExpression.js +489 -442
  179. package/src/sap/fe/core/helpers/BindingExpression.ts +486 -469
  180. package/src/sap/fe/core/helpers/ClassSupport.js +212 -76
  181. package/src/sap/fe/core/helpers/ClassSupport.ts +198 -71
  182. package/src/sap/fe/core/helpers/DynamicAnnotationPathHelper.js +64 -59
  183. package/src/sap/fe/core/helpers/DynamicAnnotationPathHelper.ts +52 -0
  184. package/src/sap/fe/core/helpers/EditState.js +81 -84
  185. package/src/sap/fe/core/helpers/EditState.ts +81 -0
  186. package/src/sap/fe/core/helpers/ExcelFormatHelper.js +62 -48
  187. package/src/sap/fe/core/helpers/ExcelFormatHelper.ts +49 -0
  188. package/src/sap/fe/core/helpers/FPMHelper.js +52 -56
  189. package/src/sap/fe/core/helpers/FPMHelper.ts +62 -0
  190. package/src/sap/fe/core/helpers/KeepAliveHelper.js +4 -5
  191. package/src/sap/fe/core/helpers/KeepAliveHelper.ts +10 -10
  192. package/src/sap/fe/core/helpers/MassEditHelper.js +604 -0
  193. package/src/sap/fe/core/helpers/MassEditHelper.ts +699 -0
  194. package/src/sap/fe/core/helpers/ModelHelper.js +253 -225
  195. package/src/sap/fe/core/helpers/ModelHelper.ts +250 -0
  196. package/src/sap/fe/core/helpers/PasteHelper.js +210 -132
  197. package/src/sap/fe/core/helpers/PasteHelper.ts +196 -0
  198. package/src/sap/fe/core/helpers/SemanticDateOperators.js +336 -313
  199. package/src/sap/fe/core/helpers/SemanticDateOperators.ts +334 -0
  200. package/src/sap/fe/core/helpers/SemanticKeyHelper.js +66 -67
  201. package/src/sap/fe/core/helpers/SemanticKeyHelper.ts +73 -0
  202. package/src/sap/fe/core/helpers/StableIdHelper.js +4 -7
  203. package/src/sap/fe/core/helpers/StableIdHelper.ts +2 -6
  204. package/src/sap/fe/core/jsx-runtime/jsx.js +1 -1
  205. package/src/sap/fe/core/jsx-runtime/jsx.ts +1 -1
  206. package/src/sap/fe/core/library.js +427 -425
  207. package/src/sap/fe/core/library.support.js +23 -27
  208. package/src/sap/fe/core/library.support.ts +23 -0
  209. package/src/sap/fe/core/library.ts +420 -0
  210. package/src/sap/fe/core/manifestMerger/ChangePageConfiguration.js +64 -0
  211. package/src/sap/fe/core/manifestMerger/ChangePageConfiguration.ts +69 -0
  212. package/src/sap/fe/core/messagebundle.properties +78 -13
  213. package/src/sap/fe/core/messagebundle_ar.properties +58 -7
  214. package/src/sap/fe/core/messagebundle_bg.properties +58 -7
  215. package/src/sap/fe/core/messagebundle_ca.properties +58 -7
  216. package/src/sap/fe/core/messagebundle_cs.properties +59 -8
  217. package/src/sap/fe/core/messagebundle_cy.properties +58 -7
  218. package/src/sap/fe/core/messagebundle_da.properties +58 -7
  219. package/src/sap/fe/core/messagebundle_de.properties +58 -7
  220. package/src/sap/fe/core/messagebundle_el.properties +58 -7
  221. package/src/sap/fe/core/messagebundle_en.properties +57 -6
  222. package/src/sap/fe/core/messagebundle_en_GB.properties +57 -6
  223. package/src/sap/fe/core/messagebundle_en_US_sappsd.properties +61 -6
  224. package/src/sap/fe/core/messagebundle_en_US_saprigi.properties +58 -7
  225. package/src/sap/fe/core/messagebundle_en_US_saptrc.properties +58 -7
  226. package/src/sap/fe/core/messagebundle_es.properties +58 -7
  227. package/src/sap/fe/core/messagebundle_es_MX.properties +58 -7
  228. package/src/sap/fe/core/messagebundle_et.properties +58 -7
  229. package/src/sap/fe/core/messagebundle_fi.properties +60 -9
  230. package/src/sap/fe/core/messagebundle_fr.properties +64 -13
  231. package/src/sap/fe/core/messagebundle_fr_CA.properties +59 -8
  232. package/src/sap/fe/core/messagebundle_hi.properties +58 -7
  233. package/src/sap/fe/core/messagebundle_hr.properties +58 -7
  234. package/src/sap/fe/core/messagebundle_hu.properties +59 -8
  235. package/src/sap/fe/core/messagebundle_id.properties +61 -10
  236. package/src/sap/fe/core/messagebundle_it.properties +58 -7
  237. package/src/sap/fe/core/messagebundle_iw.properties +58 -7
  238. package/src/sap/fe/core/messagebundle_ja.properties +58 -7
  239. package/src/sap/fe/core/messagebundle_kk.properties +58 -7
  240. package/src/sap/fe/core/messagebundle_ko.properties +58 -7
  241. package/src/sap/fe/core/messagebundle_lt.properties +58 -7
  242. package/src/sap/fe/core/messagebundle_lv.properties +59 -8
  243. package/src/sap/fe/core/messagebundle_ms.properties +58 -7
  244. package/src/sap/fe/core/messagebundle_nl.properties +58 -7
  245. package/src/sap/fe/core/messagebundle_no.properties +58 -7
  246. package/src/sap/fe/core/messagebundle_pl.properties +58 -7
  247. package/src/sap/fe/core/messagebundle_pt.properties +59 -8
  248. package/src/sap/fe/core/messagebundle_pt_PT.properties +58 -7
  249. package/src/sap/fe/core/messagebundle_ro.properties +58 -7
  250. package/src/sap/fe/core/messagebundle_ru.properties +58 -7
  251. package/src/sap/fe/core/messagebundle_sh.properties +58 -7
  252. package/src/sap/fe/core/messagebundle_sk.properties +58 -7
  253. package/src/sap/fe/core/messagebundle_sl.properties +58 -7
  254. package/src/sap/fe/core/messagebundle_sv.properties +59 -8
  255. package/src/sap/fe/core/messagebundle_th.properties +58 -7
  256. package/src/sap/fe/core/messagebundle_tr.properties +60 -9
  257. package/src/sap/fe/core/messagebundle_uk.properties +58 -7
  258. package/src/sap/fe/core/messagebundle_vi.properties +58 -7
  259. package/src/sap/fe/core/messagebundle_zh_CN.properties +58 -7
  260. package/src/sap/fe/core/messagebundle_zh_TW.properties +58 -7
  261. package/src/sap/fe/core/services/AsyncComponentServiceFactory.js +45 -71
  262. package/src/sap/fe/core/services/AsyncComponentServiceFactory.ts +3 -1
  263. package/src/sap/fe/core/services/CacheHandlerServiceFactory.js +231 -202
  264. package/src/sap/fe/core/services/CacheHandlerServiceFactory.ts +212 -0
  265. package/src/sap/fe/core/services/EnvironmentServiceFactory.js +67 -92
  266. package/src/sap/fe/core/services/EnvironmentServiceFactory.ts +10 -6
  267. package/src/sap/fe/core/services/NavigationServiceFactory.js +351 -300
  268. package/src/sap/fe/core/services/NavigationServiceFactory.ts +313 -0
  269. package/src/sap/fe/core/services/ResourceModelServiceFactory.js +114 -81
  270. package/src/sap/fe/core/services/ResourceModelServiceFactory.ts +83 -0
  271. package/src/sap/fe/core/services/RoutingServiceFactory.js +927 -1152
  272. package/src/sap/fe/core/services/RoutingServiceFactory.ts +898 -0
  273. package/src/sap/fe/core/services/ShellServicesFactory.js +649 -707
  274. package/src/sap/fe/core/services/ShellServicesFactory.ts +52 -15
  275. package/src/sap/fe/core/services/SideEffectsServiceFactory.js +569 -637
  276. package/src/sap/fe/core/services/SideEffectsServiceFactory.ts +78 -102
  277. package/src/sap/fe/core/services/TemplatedViewServiceFactory.js +429 -478
  278. package/src/sap/fe/core/services/TemplatedViewServiceFactory.ts +460 -0
  279. package/src/sap/fe/core/services/view/TemplatingErrorPage.controller.js +10 -8
  280. package/src/sap/fe/core/services/view/TemplatingErrorPage.controller.ts +8 -0
  281. package/src/sap/fe/core/support/AnnotationIssue.support.js +15 -3
  282. package/src/sap/fe/core/support/AnnotationIssue.support.ts +16 -2
  283. package/src/sap/fe/core/support/CollectionFacetUnsupportedLevel.support.js +2 -2
  284. package/src/sap/fe/core/support/CollectionFacetUnsupportedLevel.support.ts +1 -1
  285. package/src/sap/fe/core/support/CommonHelper.js +1 -1
  286. package/src/sap/fe/core/support/CommonHelper.ts +1 -1
  287. package/src/sap/fe/core/support/Diagnostics.js +36 -48
  288. package/src/sap/fe/core/support/InvalidAnnotationColumnKey.support.js +38 -0
  289. package/src/sap/fe/core/support/InvalidAnnotationColumnKey.support.ts +18 -0
  290. package/src/sap/fe/core/templating/DataModelPathHelper.js +97 -127
  291. package/src/sap/fe/core/templating/DataModelPathHelper.ts +112 -135
  292. package/src/sap/fe/core/templating/DisplayModeFormatter.js +114 -0
  293. package/src/sap/fe/core/templating/DisplayModeFormatter.ts +86 -0
  294. package/src/sap/fe/core/templating/FieldControlHelper.js +8 -8
  295. package/src/sap/fe/core/templating/FieldControlHelper.ts +25 -7
  296. package/src/sap/fe/core/templating/FilterHelper.js +140 -78
  297. package/src/sap/fe/core/templating/FilterHelper.ts +149 -78
  298. package/src/sap/fe/core/templating/PropertyHelper.js +3 -3
  299. package/src/sap/fe/core/templating/PropertyHelper.ts +2 -2
  300. package/src/sap/fe/core/templating/UIFormatters.js +76 -135
  301. package/src/sap/fe/core/templating/UIFormatters.ts +76 -99
  302. package/src/sap/fe/core/type/Email.js +1 -1
  303. package/src/sap/fe/core/type/Email.ts +4 -6
  304. package/ui5.yaml +0 -3
  305. package/src/sap/fe/core/controls/filterbar.d.js +0 -8
  306. package/src/sap/fe/core/controls/filterbar.d.ts +0 -0
@@ -0,0 +1,245 @@
1
+ import VBox from "sap/m/VBox";
2
+ import Utils from "sap/ui/fl/Utils";
3
+ import { CommonHelper } from "sap/fe/macros";
4
+ import VisualFilterUtils from "sap/fe/core/controls/filterbar/utils/VisualFilterUtils";
5
+ import { FilterUtils } from "sap/fe/macros/filter";
6
+ import ResourceBundle from "sap/base/i18n/ResourceBundle";
7
+ import { getFiltersConditionsFromSelectionVariant } from "../../templating/FilterHelper";
8
+ /**
9
+ * Constructor for a new filterBar/aligned/FilterItemLayout.
10
+ *
11
+ * @param {string} [sId] ID for the new control, generated automatically if no ID is given
12
+ * @param {object} [mSettings] Initial settings for the new control
13
+ * @class Represents a filter item on the UI.
14
+ * @extends sap.m.VBox
15
+ * @implements {sap.ui.core.IFormContent}
16
+ * @class
17
+ * @private
18
+ * @since 1.61.0
19
+ * @alias control sap.fe.core.controls.filterbar.VisualFilter
20
+ */
21
+ const VisualFilter = VBox.extend(
22
+ "sap.fe.core.controls.filterbar.VisualFilter",
23
+ /** @lends sap.ui.mdc.filterbar.aligned.FilterItemLayout.prototype */ {
24
+ renderer: {
25
+ apiVersion: 2
26
+ },
27
+ metadata: {
28
+ properties: {
29
+ showValueHelp: {
30
+ type: "boolean"
31
+ },
32
+ valueHelpIconSrc: {
33
+ type: "string"
34
+ }
35
+ },
36
+ events: {
37
+ valueHelpRequest: {}
38
+ },
39
+ interfaces: ["sap.ui.core.IFormContent"]
40
+ }
41
+ }
42
+ );
43
+ VisualFilter.prototype.onAfterRendering = function() {
44
+ let sLabel;
45
+ const oInteractiveChart = this.getItems()[1].getItems()[0];
46
+ const sInternalContextPath = this.data("infoPath");
47
+ const oInteractiveChartListBinding =
48
+ oInteractiveChart.getBinding("segments") || oInteractiveChart.getBinding("bars") || oInteractiveChart.getBinding("points");
49
+ const oInternalModelContext = oInteractiveChart.getBindingContext("internal");
50
+ const oResourceBundle = sap.ui.getCore().getLibraryResourceBundle("sap.fe.macros") as ResourceBundle;
51
+ const bShowOverLayInitially = oInteractiveChart.data("showOverlayInitially");
52
+ const oSelectionVariantAnnotation: any = oInteractiveChart.data("selectionVariantAnnotation")
53
+ ? CommonHelper.parseCustomData(oInteractiveChart.data("selectionVariantAnnotation"))
54
+ : { SelectOptions: [] };
55
+ const aRequiredProperties: any[] = oInteractiveChart.data("requiredProperties")
56
+ ? (CommonHelper.parseCustomData(oInteractiveChart.data("requiredProperties")) as any[])
57
+ : [];
58
+ const oMetaModel = oInteractiveChart.getModel().getMetaModel();
59
+ const sEntitySetPath = oInteractiveChartListBinding ? oInteractiveChartListBinding.getPath() : "";
60
+ let oFilterBar = this.getParent().getParent();
61
+ // TODO: Remove this part once 2170204347 is fixed
62
+ if (oFilterBar.getMetadata().getElementName() === "sap.ui.mdc.filterbar.p13n.AdaptationFilterBar") {
63
+ oFilterBar = oFilterBar.getParent().getParent();
64
+ }
65
+ let oFilterBarConditions: any = {};
66
+ let aPropertyInfoSet = [];
67
+ let sFilterEntityName;
68
+ if (oFilterBar.getMetadata().getElementName() === "sap.fe.core.controls.FilterBar") {
69
+ oFilterBarConditions = oFilterBar.getConditions();
70
+ aPropertyInfoSet = oFilterBar.getPropertyInfoSet();
71
+ sFilterEntityName = oFilterBar.data("entityType").split("/")[1];
72
+ }
73
+ const aParameters = oInteractiveChart.data("parameters") ? oInteractiveChart.data("parameters").customData : [];
74
+ const filterConditions = getFiltersConditionsFromSelectionVariant(
75
+ sEntitySetPath,
76
+ oMetaModel,
77
+ oSelectionVariantAnnotation,
78
+ VisualFilterUtils.getCustomConditions.bind(VisualFilterUtils)
79
+ );
80
+ const oSelectionVariantConditions = VisualFilterUtils.convertFilterCondions(filterConditions);
81
+ const mConditions: any = {};
82
+
83
+ Object.keys(oFilterBarConditions).forEach(function(sKey: string) {
84
+ if (oFilterBarConditions[sKey].length) {
85
+ mConditions[sKey] = oFilterBarConditions[sKey];
86
+ }
87
+ });
88
+
89
+ Object.keys(oSelectionVariantConditions).forEach(function(sKey: string) {
90
+ if (!mConditions[sKey]) {
91
+ mConditions[sKey] = oSelectionVariantConditions[sKey];
92
+ }
93
+ });
94
+ if (bShowOverLayInitially === "true") {
95
+ if (!Object.keys(oSelectionVariantAnnotation).length) {
96
+ if (aRequiredProperties.length > 1) {
97
+ oInternalModelContext.setProperty(sInternalContextPath, {
98
+ "showError": true,
99
+ "errorMessageTitle": oResourceBundle.getText("M_VISUAL_FILTERS_ERROR_MESSAGE_TITLE"),
100
+ "errorMessage": oResourceBundle.getText("M_VISUAL_FILTERS_PROVIDE_FILTER_VAL_MULTIPLEVF")
101
+ });
102
+ } else {
103
+ sLabel =
104
+ oMetaModel.getObject(sEntitySetPath + "/" + aRequiredProperties[0] + "@com.sap.vocabularies.Common.v1.Label") ||
105
+ aRequiredProperties[0];
106
+ oInternalModelContext.setProperty(sInternalContextPath, {
107
+ "showError": true,
108
+ "errorMessageTitle": oResourceBundle.getText("M_VISUAL_FILTERS_ERROR_MESSAGE_TITLE"),
109
+ "errorMessage": oResourceBundle.getText("M_VISUAL_FILTERS_PROVIDE_FILTER_VAL_SINGLEVF", sLabel)
110
+ });
111
+ }
112
+ } else {
113
+ const aSelectOptions: any[] = [];
114
+ const aNotMatchedConditions: any[] = [];
115
+ if (oSelectionVariantAnnotation.SelectOptions) {
116
+ oSelectionVariantAnnotation.SelectOptions.forEach(function(oSelectOption: any) {
117
+ aSelectOptions.push(oSelectOption.PropertyName.$PropertyPath);
118
+ });
119
+ }
120
+ if (oSelectionVariantAnnotation.Parameters) {
121
+ oSelectionVariantAnnotation.Parameters.forEach(function(oParameter: any) {
122
+ aSelectOptions.push(oParameter.PropertyName.$PropertyPath);
123
+ });
124
+ }
125
+ aRequiredProperties.forEach(function(sPath: any) {
126
+ if (aSelectOptions.indexOf(sPath) === -1) {
127
+ aNotMatchedConditions.push(sPath);
128
+ }
129
+ });
130
+ if (aNotMatchedConditions.length > 1) {
131
+ oInternalModelContext.setProperty(sInternalContextPath, {
132
+ "showError": true,
133
+ "errorMessageTitle": oResourceBundle.getText("M_VISUAL_FILTERS_ERROR_MESSAGE_TITLE"),
134
+ "errorMessage": oResourceBundle.getText("M_VISUAL_FILTERS_PROVIDE_FILTER_VAL_MULTIPLEVF")
135
+ });
136
+ } else {
137
+ sLabel =
138
+ oMetaModel.getObject(sEntitySetPath + "/" + aNotMatchedConditions[0] + "@com.sap.vocabularies.Common.v1.Label") ||
139
+ aNotMatchedConditions[0];
140
+ oInternalModelContext.setProperty(sInternalContextPath, {
141
+ "showError": true,
142
+ "errorMessageTitle": oResourceBundle.getText("M_VISUAL_FILTERS_ERROR_MESSAGE_TITLE"),
143
+ "errorMessage": oResourceBundle.getText("M_VISUAL_FILTERS_PROVIDE_FILTER_VAL_SINGLEVF", sLabel)
144
+ });
145
+ }
146
+ aNotMatchedConditions.length > 1
147
+ ? oInternalModelContext.setProperty(sInternalContextPath, {
148
+ "showError": true,
149
+ "errorMessageTitle": oResourceBundle.getText("M_VISUAL_FILTERS_ERROR_MESSAGE_TITLE"),
150
+ "errorMessage": oResourceBundle.getText("M_VISUAL_FILTERS_PROVIDE_FILTER_VAL_MULTIPLEVF")
151
+ })
152
+ : oInternalModelContext.setProperty(sInternalContextPath, {
153
+ "showError": true,
154
+ "errorMessageTitle": oResourceBundle.getText("M_VISUAL_FILTERS_ERROR_MESSAGE_TITLE"),
155
+ "errorMessage": oResourceBundle.getText("M_VISUAL_FILTERS_PROVIDE_FILTER_VAL_SINGLEVF", aNotMatchedConditions[0])
156
+ });
157
+ }
158
+ }
159
+
160
+ if (!this._oChartBinding || this._oChartBinding !== oInteractiveChartListBinding) {
161
+ if (this._oChartBinding) {
162
+ this.detachDataRecivedHandler(this._oChartBinding);
163
+ }
164
+ this.attachDataRecivedHandler(oInteractiveChartListBinding);
165
+ this._oChartBinding = oInteractiveChartListBinding;
166
+ }
167
+ const bShowOverlay =
168
+ oInternalModelContext.getProperty(sInternalContextPath) && oInternalModelContext.getProperty(sInternalContextPath).showError;
169
+ const sChartEntityName = sEntitySetPath !== "" ? sEntitySetPath.split("/")[1].split("(")[0] : "";
170
+ if (aParameters && aParameters.length && sFilterEntityName === sChartEntityName) {
171
+ const sBindingPath = FilterUtils.getBindingPathForParameters(oFilterBar, mConditions, aPropertyInfoSet, aParameters);
172
+ if (sBindingPath) {
173
+ oInteractiveChartListBinding.sPath = sBindingPath;
174
+ }
175
+ }
176
+ // resume binding for only those visual filters that do not have a in parameter attached.
177
+ // Bindings of visual filters with inParameters will be resumed later after considering in parameters.
178
+ if (oInteractiveChartListBinding && oInteractiveChartListBinding.isSuspended() && !bShowOverlay) {
179
+ oInteractiveChartListBinding.resume();
180
+ }
181
+ };
182
+ VisualFilter.prototype.attachDataRecivedHandler = function(oInteractiveChartListBinding: any) {
183
+ if (oInteractiveChartListBinding) {
184
+ oInteractiveChartListBinding.attachEvent("dataReceived", this.onInternalDataReceived, this);
185
+ this._oChartBinding = oInteractiveChartListBinding;
186
+ }
187
+ };
188
+ VisualFilter.prototype.detachDataRecivedHandler = function(oInteractiveChartListBinding: any) {
189
+ if (oInteractiveChartListBinding) {
190
+ oInteractiveChartListBinding.detachEvent("dataReceived", this.onInternalDataReceived, this);
191
+ this._oChartBinding = null;
192
+ }
193
+ };
194
+ VisualFilter.prototype.setShowValueHelp = function(bShowValueHelp: any) {
195
+ if (this.getItems().length > 0) {
196
+ const oVisualFilterControl = this.getItems()[0].getItems()[0];
197
+ oVisualFilterControl.getContent().some(function(oInnerControl: any) {
198
+ if (oInnerControl.isA("sap.m.Button")) {
199
+ oInnerControl.setVisible(bShowValueHelp);
200
+ }
201
+ });
202
+ this.setProperty("showValueHelp", bShowValueHelp);
203
+ }
204
+ };
205
+ VisualFilter.prototype.setValueHelpIconSrc = function(sIconSrc: any) {
206
+ if (this.getItems().length > 0) {
207
+ const oVisualFilterControl = this.getItems()[0].getItems()[0];
208
+ oVisualFilterControl.getContent().some(function(oInnerControl: any) {
209
+ if (oInnerControl.isA("sap.m.Button")) {
210
+ oInnerControl.setIcon(sIconSrc);
211
+ }
212
+ });
213
+ this.setProperty("valueHelpIconSrc", sIconSrc);
214
+ }
215
+ };
216
+ VisualFilter.prototype.onInternalDataReceived = function(oEvent: any) {
217
+ const sId = this.getId();
218
+ const oView = Utils.getViewForControl(this);
219
+ const oInteractiveChart = this.getItems()[1].getItems()[0];
220
+ const sInternalContextPath = this.data("infoPath");
221
+ const oInternalModelContext = oInteractiveChart.getBindingContext("internal");
222
+ const oResourceBundle = sap.ui.getCore().getLibraryResourceBundle("sap.fe.macros") as ResourceBundle;
223
+ const vUOM = oInteractiveChart.data("uom");
224
+ VisualFilterUtils.updateChartScaleFactorTitle(oInteractiveChart, oView, sId, sInternalContextPath);
225
+ if (oEvent.getParameter("error")) {
226
+ const s18nMessageTitle = oResourceBundle.getText("M_VISUAL_FILTERS_ERROR_MESSAGE_TITLE");
227
+ const s18nMessage = oResourceBundle.getText("M_VISUAL_FILTERS_ERROR_DATA_TEXT");
228
+ VisualFilterUtils.applyErrorMessageAndTitle(s18nMessageTitle, s18nMessage, sInternalContextPath, oView);
229
+ } else if (oEvent.getParameter("data")) {
230
+ const oData = oEvent.getSource().getCurrentContexts();
231
+ if (oData && oData.length === 0) {
232
+ VisualFilterUtils.setNoDataMessage(sInternalContextPath, oResourceBundle, oView);
233
+ } else {
234
+ oInternalModelContext.setProperty(sInternalContextPath, {});
235
+ }
236
+ VisualFilterUtils.setMultiUOMMessage(oData, oInteractiveChart, sInternalContextPath, oResourceBundle, oView);
237
+ }
238
+ if (vUOM && ((vUOM["ISOCurrency"] && vUOM["ISOCurrency"].$Path) || (vUOM["Unit"] && vUOM["Unit"].$Path))) {
239
+ const oContexts = oEvent.getSource().getContexts();
240
+ const oContextData = oContexts && oContexts[0].getObject();
241
+ VisualFilterUtils.applyUOMToTitle(oInteractiveChart, oContextData, oView, sInternalContextPath);
242
+ }
243
+ };
244
+
245
+ export default VisualFilter;
@@ -1,143 +1,153 @@
1
1
  /*!
2
- * SAPUI5
3
- * (c) Copyright 2009-2021 SAP SE. All rights reserved.
2
+ * SAP UI development toolkit for HTML5 (SAPUI5)
3
+ * (c) Copyright 2009-2021 SAP SE. All rights reserved
4
4
  */
5
-
6
- // Provides control sap.fe.core.controls.filterbar.VisualFilterContainer.
7
- sap.ui.define(
8
- ["sap/ui/mdc/filterbar/IFilterContainer", "sap/m/HeaderContainer", "sap/m/FlexBox", "sap/ui/Device", "sap/ui/core/library"],
9
- function(IFilterContainer, HeaderContainer, FlexBox, Device, coreLibrabry) {
10
- "use strict";
11
-
12
- /**
13
- * Constructor for a new Visual Filter Container.
14
- * Used for visual filters
15
- * @param {string} [sId] ID for the new control, generated automatically if no ID is given
16
- * @extends sap.ui.mdc.filterbar.IFilterContainer
17
- * @class
18
- * @private
19
- * @alias sap.fe.core.controls.filterbar.VisualFilterContainer
20
- */
21
- var VisualFilterContainer = IFilterContainer.extend("sap.fe.core.controls.filterbar.VisualFilterContainer", {
22
- metadata: {
23
- aggregations: {
24
- /**
25
- * Internal hidden aggregation to hold the inner layout.
26
- */
27
- _layout: {
28
- type: "sap.ui.core.Control",
29
- multiple: false,
30
- visibility: "hidden"
31
- }
32
- }
33
- }
34
- });
35
-
36
- VisualFilterContainer.prototype.init = function() {
37
- IFilterContainer.prototype.init.apply(this, arguments);
38
- //var oRB = sap.ui.getCore().getLibraryResourceBundle("sap.ui.mdc");
39
- var sDeviceSystem = Device.system,
40
- Orientation = coreLibrabry.Orientation,
41
- sOrientation = sDeviceSystem.phone ? Orientation.Vertical : undefined,
42
- sDirection = sDeviceSystem.phone ? "ColumnReverse" : "Column";
43
-
44
- this.oHeaderContainer = new HeaderContainer({
45
- orientation: sOrientation
46
- });
47
- this.oButtonFlexBox = new FlexBox({
48
- alignItems: "End",
49
- justifyContent: "End"
50
- });
51
-
52
- this.oLayout = new FlexBox({
53
- direction: sDirection, // Direction is Column Reverse for Phone
54
- items: [this.oHeaderContainer, this.oButtonFlexBox]
55
- });
56
-
57
- this.aAllFilterFields = [];
58
- this.aVisualFilterFields = {};
59
- };
60
-
61
- VisualFilterContainer.prototype.exit = function() {
62
- // destroy layout
63
- IFilterContainer.prototype.exit.apply(this, arguments);
64
- // destroy all filter fields which are not in the layout
65
- var aAllFilterFields = this.getAllFilterFields();
66
- aAllFilterFields.forEach(function(oFilterField) {
67
- oFilterField.destroy();
68
- });
69
- this.oHeaderContainer = null;
70
- this.oButtonFlexBox = null;
71
- this.aAllFilterFields = [];
72
- };
73
-
74
- VisualFilterContainer.prototype.insertFilterField = function(oControl, iIndex) {
75
- var oFilterItemLayoutEventDelegate = {
76
- onBeforeRendering: function() {
77
- // visual filter does not need to render a label
78
- // hence override the getContent of the FilterItemLayout
79
- // and store the original getContent for later usage in the compact filters
80
- if (!oControl._fnGetContentCopy) {
81
- oControl._fnGetContentCopy = oControl.getContent;
82
- }
83
- // override getContent of FilterItemLayout
84
- // to add only filterField and not label
85
- oControl.getContent = function() {
86
- var aContent = [];
87
- aContent.push(oControl._oFilterField);
88
- return aContent;
89
- };
90
- oControl.removeEventDelegate(oFilterItemLayoutEventDelegate);
91
- }
92
- };
93
- oControl.addEventDelegate(oFilterItemLayoutEventDelegate);
94
-
95
- // Setting VF control for the Filterfield.
96
- var that = this,
97
- oVisualFilters = that.aVisualFilterFields;
98
- oControl.getContent().some(function(oInnerControl) {
99
- var sFFId = oInnerControl.getId();
100
- if (oVisualFilters[sFFId] && oInnerControl.isA("sap.ui.mdc.FilterField")) {
101
- oInnerControl.setContent(oVisualFilters[sFFId]);
102
- that.oHeaderContainer.insertContent(oControl, iIndex);
103
- }
104
- });
105
- };
106
-
107
- VisualFilterContainer.prototype.removeFilterField = function(oControl) {
108
- this.oHeaderContainer.removeContent(oControl);
109
- };
110
-
111
- VisualFilterContainer.prototype.removeAllFilterFields = function() {
112
- this.aAllFilterFields = [];
113
- this.aVisualFilterFields = {};
114
- this.oHeaderContainer.removeAllContent();
115
- };
116
-
117
- VisualFilterContainer.prototype.getFilterFields = function() {
118
- return this.oHeaderContainer.getContent();
119
- };
120
-
121
- VisualFilterContainer.prototype.addButton = function(oControl) {
122
- this.oButtonFlexBox.insertItem(oControl);
123
- };
124
-
125
- VisualFilterContainer.prototype.getAllButtons = function() {
126
- return this.oButtonFlexBox.getItems().reverse();
127
- };
128
-
129
- VisualFilterContainer.prototype.removeButton = function(oControl) {
130
- this.oButtonFlexBox.removeItem(oControl);
131
- };
132
-
133
- VisualFilterContainer.prototype.getAllFilterFields = function() {
134
- return this.aAllFilterFields.slice();
135
- };
136
- VisualFilterContainer.prototype.setAllFilterFields = function(aFilterFields, aVisualFilterFields) {
137
- this.aAllFilterFields = aFilterFields;
138
- this.aVisualFilterFields = aVisualFilterFields;
139
- };
140
-
141
- return VisualFilterContainer;
142
- }
143
- );
5
+ sap.ui.define(["sap/ui/mdc/filterbar/IFilterContainer", "sap/m/HeaderContainer", "sap/m/FlexBox", "sap/ui/Device", "sap/ui/core/library"], function (IFilterContainer, HeaderContainer, FlexBox, Device, coreLibrabry) {
6
+ "use strict";
7
+
8
+ var system = Device.system;
9
+
10
+ /**
11
+ * Constructor for a new Visual Filter Container.
12
+ * Used for visual filters
13
+ *
14
+ * @param {string} [sId] ID for the new control, generated automatically if no ID is given
15
+ * @extends sap.ui.mdc.filterbar.IFilterContainer
16
+ * @class
17
+ * @private
18
+ * @alias sap.fe.core.controls.filterbar.VisualFilterContainer
19
+ */
20
+ var VisualFilterContainer = IFilterContainer.extend("sap.fe.core.controls.filterbar.VisualFilterContainer", {
21
+ metadata: {
22
+ aggregations: {
23
+ /**
24
+ * Internal hidden aggregation to hold the inner layout.
25
+ */
26
+ _layout: {
27
+ type: "sap.ui.core.Control",
28
+ multiple: false,
29
+ visibility: "hidden"
30
+ }
31
+ }
32
+ }
33
+ });
34
+
35
+ VisualFilterContainer.prototype.init = function () {
36
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
37
+ args[_key] = arguments[_key];
38
+ }
39
+
40
+ IFilterContainer.prototype.init.apply(this, args); //var oRB = sap.ui.getCore().getLibraryResourceBundle("sap.ui.mdc");
41
+
42
+ var sDeviceSystem = system,
43
+ Orientation = coreLibrabry.Orientation,
44
+ sOrientation = sDeviceSystem.phone ? Orientation.Vertical : undefined,
45
+ sDirection = sDeviceSystem.phone ? "ColumnReverse" : "Column";
46
+ this.oHeaderContainer = new HeaderContainer({
47
+ orientation: sOrientation
48
+ });
49
+ this.oButtonFlexBox = new FlexBox({
50
+ alignItems: "End",
51
+ justifyContent: "End"
52
+ });
53
+ this.oLayout = new FlexBox({
54
+ direction: sDirection,
55
+ // Direction is Column Reverse for Phone
56
+ items: [this.oHeaderContainer, this.oButtonFlexBox]
57
+ });
58
+ this.aAllFilterFields = [];
59
+ this.aVisualFilterFields = {};
60
+ };
61
+
62
+ VisualFilterContainer.prototype.exit = function () {
63
+ for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
64
+ args[_key2] = arguments[_key2];
65
+ }
66
+
67
+ // destroy layout
68
+ IFilterContainer.prototype.exit.apply(this, args); // destroy all filter fields which are not in the layout
69
+
70
+ var aAllFilterFields = this.getAllFilterFields();
71
+ aAllFilterFields.forEach(function (oFilterField) {
72
+ oFilterField.destroy();
73
+ });
74
+ this.oHeaderContainer = null;
75
+ this.oButtonFlexBox = null;
76
+ this.aAllFilterFields = [];
77
+ };
78
+
79
+ VisualFilterContainer.prototype.insertFilterField = function (oControl, iIndex) {
80
+ var _this = this;
81
+
82
+ var oFilterItemLayoutEventDelegate = {
83
+ onBeforeRendering: function () {
84
+ // visual filter does not need to render a label
85
+ // hence override the getContent of the FilterItemLayout
86
+ // and store the original getContent for later usage in the compact filters
87
+ if (!oControl._fnGetContentCopy) {
88
+ oControl._fnGetContentCopy = oControl.getContent;
89
+ } // override getContent of FilterItemLayout
90
+ // to add only filterField and not label
91
+
92
+
93
+ oControl.getContent = function () {
94
+ var aContent = [];
95
+ aContent.push(oControl._oFilterField);
96
+ return aContent;
97
+ };
98
+
99
+ oControl.removeEventDelegate(oFilterItemLayoutEventDelegate);
100
+ }
101
+ };
102
+ oControl.addEventDelegate(oFilterItemLayoutEventDelegate); // Setting VF control for the Filterfield.
103
+
104
+ var oVisualFilters = this.aVisualFilterFields;
105
+ oControl.getContent().some(function (oInnerControl) {
106
+ var sFFId = oInnerControl.getId();
107
+
108
+ if (oVisualFilters[sFFId] && oInnerControl.isA("sap.ui.mdc.FilterField")) {
109
+ oInnerControl.setContent(oVisualFilters[sFFId]);
110
+
111
+ _this.oHeaderContainer.insertContent(oControl, iIndex);
112
+ }
113
+ });
114
+ };
115
+
116
+ VisualFilterContainer.prototype.removeFilterField = function (oControl) {
117
+ this.oHeaderContainer.removeContent(oControl);
118
+ };
119
+
120
+ VisualFilterContainer.prototype.removeAllFilterFields = function () {
121
+ this.aAllFilterFields = [];
122
+ this.aVisualFilterFields = {};
123
+ this.oHeaderContainer.removeAllContent();
124
+ };
125
+
126
+ VisualFilterContainer.prototype.getFilterFields = function () {
127
+ return this.oHeaderContainer.getContent();
128
+ };
129
+
130
+ VisualFilterContainer.prototype.addButton = function (oControl) {
131
+ this.oButtonFlexBox.insertItem(oControl);
132
+ };
133
+
134
+ VisualFilterContainer.prototype.getAllButtons = function () {
135
+ return this.oButtonFlexBox.getItems().reverse();
136
+ };
137
+
138
+ VisualFilterContainer.prototype.removeButton = function (oControl) {
139
+ this.oButtonFlexBox.removeItem(oControl);
140
+ };
141
+
142
+ VisualFilterContainer.prototype.getAllFilterFields = function () {
143
+ return this.aAllFilterFields.slice();
144
+ };
145
+
146
+ VisualFilterContainer.prototype.setAllFilterFields = function (aFilterFields, aVisualFilterFields) {
147
+ this.aAllFilterFields = aFilterFields;
148
+ this.aVisualFilterFields = aVisualFilterFields;
149
+ };
150
+
151
+ return VisualFilterContainer;
152
+ }, false);
153
+ //# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlZpc3VhbEZpbHRlckNvbnRhaW5lci50cyJdLCJuYW1lcyI6WyJWaXN1YWxGaWx0ZXJDb250YWluZXIiLCJJRmlsdGVyQ29udGFpbmVyIiwiZXh0ZW5kIiwibWV0YWRhdGEiLCJhZ2dyZWdhdGlvbnMiLCJfbGF5b3V0IiwidHlwZSIsIm11bHRpcGxlIiwidmlzaWJpbGl0eSIsInByb3RvdHlwZSIsImluaXQiLCJhcmdzIiwiYXBwbHkiLCJzRGV2aWNlU3lzdGVtIiwic3lzdGVtIiwiT3JpZW50YXRpb24iLCJjb3JlTGlicmFicnkiLCJzT3JpZW50YXRpb24iLCJwaG9uZSIsIlZlcnRpY2FsIiwidW5kZWZpbmVkIiwic0RpcmVjdGlvbiIsIm9IZWFkZXJDb250YWluZXIiLCJIZWFkZXJDb250YWluZXIiLCJvcmllbnRhdGlvbiIsIm9CdXR0b25GbGV4Qm94IiwiRmxleEJveCIsImFsaWduSXRlbXMiLCJqdXN0aWZ5Q29udGVudCIsIm9MYXlvdXQiLCJkaXJlY3Rpb24iLCJpdGVtcyIsImFBbGxGaWx0ZXJGaWVsZHMiLCJhVmlzdWFsRmlsdGVyRmllbGRz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