@openui5/sap.ui.mdc 1.113.0 → 1.115.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 (269) hide show
  1. package/.reuse/dep5 +0 -5
  2. package/README.md +22 -9
  3. package/THIRDPARTY.txt +1 -7
  4. package/package.json +4 -4
  5. package/src/sap/ui/mdc/.library +1 -1
  6. package/src/sap/ui/mdc/ActionToolbar.js +5 -7
  7. package/src/sap/ui/mdc/AggregationBaseDelegate.js +5 -5
  8. package/src/sap/ui/mdc/BaseDelegate.js +49 -14
  9. package/src/sap/ui/mdc/Chart.js +147 -179
  10. package/src/sap/ui/mdc/ChartDelegate.js +404 -514
  11. package/src/sap/ui/mdc/ChartRenderer.js +11 -11
  12. package/src/sap/ui/mdc/Control.js +4 -4
  13. package/src/sap/ui/mdc/DefaultTypeMap.js +84 -0
  14. package/src/sap/ui/mdc/Element.js +4 -4
  15. package/src/sap/ui/mdc/Field.js +98 -96
  16. package/src/sap/ui/mdc/FilterBar.js +33 -56
  17. package/src/sap/ui/mdc/FilterBarDelegate.js +36 -69
  18. package/src/sap/ui/mdc/FilterField.js +93 -47
  19. package/src/sap/ui/mdc/Link.js +83 -82
  20. package/src/sap/ui/mdc/LinkDelegate.js +29 -48
  21. package/src/sap/ui/mdc/MultiValueField.js +34 -30
  22. package/src/sap/ui/mdc/Table.js +182 -193
  23. package/src/sap/ui/mdc/TableDelegate.js +244 -33
  24. package/src/sap/ui/mdc/ValueHelp.js +67 -50
  25. package/src/sap/ui/mdc/ValueHelpDelegate.js +57 -89
  26. package/src/sap/ui/mdc/actiontoolbar/ActionToolbarAction.js +4 -12
  27. package/src/sap/ui/mdc/chart/ChartImplementationContainer.js +192 -197
  28. package/src/sap/ui/mdc/chart/ChartSelectionDetails.js +10 -20
  29. package/src/sap/ui/mdc/chart/ChartToolbar.js +50 -50
  30. package/src/sap/ui/mdc/chart/ChartTypeButton.js +23 -27
  31. package/src/sap/ui/mdc/chart/DrillBreadcrumbs.js +10 -10
  32. package/src/sap/ui/mdc/chart/DrillStackHandler.js +14 -14
  33. package/src/sap/ui/mdc/chart/Item.js +30 -17
  34. package/src/sap/ui/mdc/chart/PropertyHelper.js +10 -10
  35. package/src/sap/ui/mdc/chart/SelectionDetailsActions.js +23 -15
  36. package/src/sap/ui/mdc/condition/Condition.js +11 -23
  37. package/src/sap/ui/mdc/condition/ConditionConverter.js +8 -8
  38. package/src/sap/ui/mdc/condition/ConditionModel.js +1 -1
  39. package/src/sap/ui/mdc/condition/FilterConverter.js +2 -2
  40. package/src/sap/ui/mdc/condition/FilterOperatorUtil.js +771 -123
  41. package/src/sap/ui/mdc/condition/Operator.js +52 -50
  42. package/src/sap/ui/mdc/condition/OperatorDynamicDateOption.js +14 -14
  43. package/src/sap/ui/mdc/condition/RangeOperator.js +3 -5
  44. package/src/sap/ui/mdc/designtime/table/Table.designtime.js +2 -2
  45. package/src/sap/ui/mdc/enum/ActionToolbarActionAlignment.js +5 -9
  46. package/src/sap/ui/mdc/enum/BaseType.js +15 -20
  47. package/src/sap/ui/mdc/enum/ConditionValidated.js +5 -9
  48. package/src/sap/ui/mdc/enum/ContentMode.js +1 -0
  49. package/src/sap/ui/mdc/enum/EditMode.js +7 -19
  50. package/src/sap/ui/mdc/enum/FieldDisplay.js +12 -18
  51. package/src/sap/ui/mdc/enum/FilterBarValidationStatus.js +3 -1
  52. package/src/sap/ui/mdc/enum/LinkType.js +40 -0
  53. package/src/sap/ui/mdc/enum/OperatorOverwrite.js +4 -2
  54. package/src/sap/ui/mdc/enum/OperatorValueType.js +47 -0
  55. package/src/sap/ui/mdc/enum/PersistenceMode.js +36 -36
  56. package/src/sap/ui/mdc/enum/ProcessingStrategy.js +3 -1
  57. package/src/sap/ui/mdc/enum/PropagationReason.js +1 -1
  58. package/src/sap/ui/mdc/enum/ReasonMode.js +1 -0
  59. package/src/sap/ui/mdc/enum/SelectType.js +1 -0
  60. package/src/sap/ui/mdc/enums/ActionToolbarActionAlignment.js +31 -0
  61. package/src/sap/ui/mdc/enums/BaseType.js +72 -0
  62. package/src/sap/ui/mdc/enums/ChartItemRoleType.js +61 -0
  63. package/src/sap/ui/mdc/enums/ChartItemType.js +31 -0
  64. package/src/sap/ui/mdc/enums/ChartP13nMode.js +48 -0
  65. package/src/sap/ui/mdc/enums/ChartToolbarActionType.js +49 -0
  66. package/src/sap/ui/mdc/enums/ConditionValidated.js +43 -0
  67. package/src/sap/ui/mdc/enums/ContentMode.js +74 -0
  68. package/src/sap/ui/mdc/enums/FieldDisplay.js +49 -0
  69. package/src/sap/ui/mdc/enums/FieldEditMode.js +55 -0
  70. package/src/sap/ui/mdc/enums/FilterBarP13nMode.js +36 -0
  71. package/src/sap/ui/mdc/enums/FilterBarValidationStatus.js +56 -0
  72. package/src/sap/ui/mdc/enums/LinkType.js +38 -0
  73. package/src/sap/ui/mdc/enums/OperatorOverwrite.js +34 -0
  74. package/src/sap/ui/mdc/enums/OperatorValueType.js +44 -0
  75. package/src/sap/ui/mdc/enums/PersistenceMode.js +44 -0
  76. package/src/sap/ui/mdc/enums/ProcessingStrategy.js +39 -0
  77. package/src/sap/ui/mdc/enums/ReasonMode.js +53 -0
  78. package/src/sap/ui/mdc/enums/TableGrowingMode.js +42 -0
  79. package/src/sap/ui/mdc/enums/TableMultiSelectMode.js +35 -0
  80. package/src/sap/ui/mdc/enums/TableP13nMode.js +54 -0
  81. package/src/sap/ui/mdc/enums/TableRowAction.js +30 -0
  82. package/src/sap/ui/mdc/enums/TableRowCountMode.js +36 -0
  83. package/src/sap/ui/mdc/enums/TableSelectionMode.js +45 -0
  84. package/src/sap/ui/mdc/enums/TableType.js +43 -0
  85. package/src/sap/ui/mdc/enums/ValueHelpPropagationReason.js +41 -0
  86. package/src/sap/ui/mdc/enums/ValueHelpSelectionType.js +46 -0
  87. package/src/sap/ui/mdc/field/ConditionType.js +120 -88
  88. package/src/sap/ui/mdc/field/ConditionsType.js +149 -44
  89. package/src/sap/ui/mdc/field/CustomFieldInfo.js +1 -1
  90. package/src/sap/ui/mdc/field/DynamicDateRangeConditionsType.js +15 -17
  91. package/src/sap/ui/mdc/field/FieldBase.js +512 -323
  92. package/src/sap/ui/mdc/field/FieldBaseDelegate.js +31 -114
  93. package/src/sap/ui/mdc/field/FieldBaseRenderer.js +4 -4
  94. package/src/sap/ui/mdc/field/FieldInfoBase.js +23 -21
  95. package/src/sap/ui/mdc/field/FieldInput.js +1 -1
  96. package/src/sap/ui/mdc/field/FieldInputRenderUtil.js +1 -1
  97. package/src/sap/ui/mdc/field/FieldMultiInput.js +1 -1
  98. package/src/sap/ui/mdc/field/ListFieldHelpItem.js +8 -29
  99. package/src/sap/ui/mdc/field/MultiValueFieldDelegate.js +2 -7
  100. package/src/sap/ui/mdc/field/MultiValueFieldItem.js +2 -6
  101. package/src/sap/ui/mdc/field/TokenDisplay.js +1 -1
  102. package/src/sap/ui/mdc/field/TokenizerDisplay.js +2 -1
  103. package/src/sap/ui/mdc/field/TokenizerDisplayRenderer.js +0 -4
  104. package/src/sap/ui/mdc/field/content/BooleanContent.js +2 -2
  105. package/src/sap/ui/mdc/field/content/ContentFactory.js +47 -35
  106. package/src/sap/ui/mdc/field/content/DateContent.js +49 -43
  107. package/src/sap/ui/mdc/field/content/DateTimeContent.js +2 -2
  108. package/src/sap/ui/mdc/field/content/DefaultContent.js +8 -8
  109. package/src/sap/ui/mdc/field/content/LinkContent.js +10 -6
  110. package/src/sap/ui/mdc/field/content/SearchContent.js +4 -4
  111. package/src/sap/ui/mdc/field/content/TimeContent.js +2 -2
  112. package/src/sap/ui/mdc/field/content/UnitContent.js +19 -11
  113. package/src/sap/ui/mdc/field/splitValue.js +45 -0
  114. package/src/sap/ui/mdc/filterbar/FilterBarBase.js +109 -218
  115. package/src/sap/ui/mdc/filterbar/IFilterContainer.js +22 -19
  116. package/src/sap/ui/mdc/filterbar/PropertyHelper.js +6 -7
  117. package/src/sap/ui/mdc/filterbar/aligned/FilterContainer.js +2 -4
  118. package/src/sap/ui/mdc/filterbar/aligned/FilterItemLayout.js +3 -7
  119. package/src/sap/ui/mdc/filterbar/p13n/AdaptationFilterBar.js +52 -41
  120. package/src/sap/ui/mdc/filterbar/p13n/FilterColumnLayout.js +2 -4
  121. package/src/sap/ui/mdc/filterbar/p13n/FilterGroupLayout.js +1 -3
  122. package/src/sap/ui/mdc/filterbar/p13n/TableContainer.js +4 -2
  123. package/src/sap/ui/mdc/filterbar/vh/FilterBar.js +14 -21
  124. package/src/sap/ui/mdc/filterbar/vh/FilterBarDelegate.js +1 -1
  125. package/src/sap/ui/mdc/flexibility/Chart.flexibility.js +1 -1
  126. package/src/sap/ui/mdc/flexibility/ChartItemFlex.js +2 -38
  127. package/src/sap/ui/mdc/flexibility/ColumnFlex.js +3 -3
  128. package/src/sap/ui/mdc/flexibility/ConditionFlex.js +11 -6
  129. package/src/sap/ui/mdc/flexibility/FilterBar.flexibility.js +1 -1
  130. package/src/sap/ui/mdc/flexibility/FilterItemFlex.js +2 -2
  131. package/src/sap/ui/mdc/flexibility/GroupFlex.js +11 -2
  132. package/src/sap/ui/mdc/flexibility/ItemBaseFlex.js +25 -9
  133. package/src/sap/ui/mdc/flexibility/SortFlex.js +11 -1
  134. package/src/sap/ui/mdc/flexibility/Util.js +2 -2
  135. package/src/sap/ui/mdc/flp/FlpLinkDelegate.js +7 -4
  136. package/src/sap/ui/mdc/library.js +178 -84
  137. package/src/sap/ui/mdc/link/ContactDetails.js +1 -1
  138. package/src/sap/ui/mdc/link/ContactDetailsAddressItem.js +1 -1
  139. package/src/sap/ui/mdc/link/ContactDetailsEmailItem.js +1 -1
  140. package/src/sap/ui/mdc/link/ContactDetailsItem.js +1 -1
  141. package/src/sap/ui/mdc/link/ContactDetailsPhoneItem.js +1 -1
  142. package/src/sap/ui/mdc/link/Factory.js +1 -1
  143. package/src/sap/ui/mdc/link/FakeFlpConnector.js +1 -1
  144. package/src/sap/ui/mdc/link/LinkItem.js +26 -5
  145. package/src/sap/ui/mdc/link/Panel.js +1 -1
  146. package/src/sap/ui/mdc/link/PanelItem.js +1 -1
  147. package/src/sap/ui/mdc/link/SemanticObjectMapping.js +1 -1
  148. package/src/sap/ui/mdc/link/SemanticObjectMappingItem.js +1 -1
  149. package/src/sap/ui/mdc/link/SemanticObjectUnavailableAction.js +1 -1
  150. package/src/sap/ui/mdc/messagebundle.properties +9 -0
  151. package/src/sap/ui/mdc/messagebundle_ar.properties +7 -1
  152. package/src/sap/ui/mdc/messagebundle_bg.properties +19 -13
  153. package/src/sap/ui/mdc/messagebundle_ca.properties +6 -0
  154. package/src/sap/ui/mdc/messagebundle_cs.properties +6 -0
  155. package/src/sap/ui/mdc/messagebundle_cy.properties +6 -0
  156. package/src/sap/ui/mdc/messagebundle_da.properties +6 -0
  157. package/src/sap/ui/mdc/messagebundle_de.properties +6 -0
  158. package/src/sap/ui/mdc/messagebundle_el.properties +13 -7
  159. package/src/sap/ui/mdc/messagebundle_en.properties +6 -0
  160. package/src/sap/ui/mdc/messagebundle_en_GB.properties +6 -0
  161. package/src/sap/ui/mdc/messagebundle_en_US_sappsd.properties +6 -0
  162. package/src/sap/ui/mdc/messagebundle_en_US_saprigi.properties +6 -0
  163. package/src/sap/ui/mdc/messagebundle_en_US_saptrc.properties +6 -0
  164. package/src/sap/ui/mdc/messagebundle_es.properties +6 -0
  165. package/src/sap/ui/mdc/messagebundle_es_MX.properties +6 -0
  166. package/src/sap/ui/mdc/messagebundle_et.properties +6 -0
  167. package/src/sap/ui/mdc/messagebundle_fi.properties +7 -1
  168. package/src/sap/ui/mdc/messagebundle_fr.properties +6 -0
  169. package/src/sap/ui/mdc/messagebundle_fr_CA.properties +10 -4
  170. package/src/sap/ui/mdc/messagebundle_hi.properties +6 -0
  171. package/src/sap/ui/mdc/messagebundle_hr.properties +15 -9
  172. package/src/sap/ui/mdc/messagebundle_hu.properties +8 -2
  173. package/src/sap/ui/mdc/messagebundle_id.properties +6 -0
  174. package/src/sap/ui/mdc/messagebundle_it.properties +10 -4
  175. package/src/sap/ui/mdc/messagebundle_iw.properties +6 -0
  176. package/src/sap/ui/mdc/messagebundle_ja.properties +14 -8
  177. package/src/sap/ui/mdc/messagebundle_kk.properties +16 -10
  178. package/src/sap/ui/mdc/messagebundle_ko.properties +9 -3
  179. package/src/sap/ui/mdc/messagebundle_lt.properties +6 -0
  180. package/src/sap/ui/mdc/messagebundle_lv.properties +6 -0
  181. package/src/sap/ui/mdc/messagebundle_ms.properties +9 -3
  182. package/src/sap/ui/mdc/messagebundle_nl.properties +7 -1
  183. package/src/sap/ui/mdc/messagebundle_no.properties +6 -0
  184. package/src/sap/ui/mdc/messagebundle_pl.properties +8 -2
  185. package/src/sap/ui/mdc/messagebundle_pt.properties +6 -0
  186. package/src/sap/ui/mdc/messagebundle_pt_PT.properties +6 -0
  187. package/src/sap/ui/mdc/messagebundle_ro.properties +6 -0
  188. package/src/sap/ui/mdc/messagebundle_ru.properties +6 -0
  189. package/src/sap/ui/mdc/messagebundle_sh.properties +6 -0
  190. package/src/sap/ui/mdc/messagebundle_sk.properties +8 -2
  191. package/src/sap/ui/mdc/messagebundle_sl.properties +6 -0
  192. package/src/sap/ui/mdc/messagebundle_sv.properties +6 -0
  193. package/src/sap/ui/mdc/messagebundle_th.properties +19 -13
  194. package/src/sap/ui/mdc/messagebundle_tr.properties +6 -0
  195. package/src/sap/ui/mdc/messagebundle_uk.properties +7 -1
  196. package/src/sap/ui/mdc/messagebundle_vi.properties +6 -0
  197. package/src/sap/ui/mdc/messagebundle_zh_CN.properties +7 -1
  198. package/src/sap/ui/mdc/messagebundle_zh_TW.properties +6 -0
  199. package/src/sap/ui/mdc/mixin/AdaptationMixin.js +1 -1
  200. package/src/sap/ui/mdc/mixin/DelegateMixin.js +33 -14
  201. package/src/sap/ui/mdc/mixin/FilterIntegrationMixin.js +3 -5
  202. package/src/sap/ui/mdc/mixin/PromiseMixin.js +1 -1
  203. package/src/sap/ui/mdc/mixin/PropertyHelperMixin.js +1 -1
  204. package/src/sap/ui/mdc/odata/TypeMap.js +155 -0
  205. package/src/sap/ui/mdc/odata/TypeUtil.js +42 -1
  206. package/src/sap/ui/mdc/odata/v4/ChartDelegate.js +17 -11
  207. package/src/sap/ui/mdc/odata/v4/FieldBaseDelegate.js +5 -50
  208. package/src/sap/ui/mdc/odata/v4/ODataMetaModelUtil.js +1 -1
  209. package/src/sap/ui/mdc/odata/v4/TableDelegate.js +156 -44
  210. package/src/sap/ui/mdc/odata/v4/TypeMap.js +70 -0
  211. package/src/sap/ui/mdc/odata/v4/TypeUtil.js +2 -1
  212. package/src/sap/ui/mdc/odata/v4/ValueHelpDelegate.js +8 -9
  213. package/src/sap/ui/mdc/odata/v4/vizChart/ChartDelegate.js +380 -390
  214. package/src/sap/ui/mdc/p13n/PropertyHelper.js +1 -1
  215. package/src/sap/ui/mdc/p13n/StateUtil.js +6 -19
  216. package/src/sap/ui/mdc/p13n/UIManager.js +1 -1
  217. package/src/sap/ui/mdc/p13n/panels/ChartItemPanel.js +43 -34
  218. package/src/sap/ui/mdc/p13n/panels/FilterPanel.js +3 -4
  219. package/src/sap/ui/mdc/p13n/subcontroller/FilterController.js +1 -1
  220. package/src/sap/ui/mdc/p13n/subcontroller/LinkPanelController.js +4 -6
  221. package/src/sap/ui/mdc/table/Column.js +45 -17
  222. package/src/sap/ui/mdc/table/ColumnSettings.js +2 -5
  223. package/src/sap/ui/mdc/table/CreationRow.js +4 -6
  224. package/src/sap/ui/mdc/table/GridTableType.js +31 -115
  225. package/src/sap/ui/mdc/table/PropertyHelper.js +56 -11
  226. package/src/sap/ui/mdc/table/ResponsiveColumnSettings.js +2 -5
  227. package/src/sap/ui/mdc/table/ResponsiveTableType.js +13 -84
  228. package/src/sap/ui/mdc/table/RowActionItem.js +9 -14
  229. package/src/sap/ui/mdc/table/RowSettings.js +2 -5
  230. package/src/sap/ui/mdc/table/TableSettings.js +23 -19
  231. package/src/sap/ui/mdc/table/TableTypeBase.js +43 -15
  232. package/src/sap/ui/mdc/table/TreeTableType.js +12 -32
  233. package/src/sap/ui/mdc/table/V4AnalyticsPropertyHelper.js +2 -5
  234. package/src/sap/ui/mdc/table/menu/Item.js +1 -1
  235. package/src/sap/ui/mdc/table/menu/QuickActionContainer.js +3 -3
  236. package/src/sap/ui/mdc/table/utils/Personalization.js +4 -4
  237. package/src/sap/ui/mdc/themes/base/ValueHelpDialog.less +6 -6
  238. package/src/sap/ui/mdc/util/DateUtil.js +15 -11
  239. package/src/sap/ui/mdc/util/FilterUtil.js +44 -19
  240. package/src/sap/ui/mdc/util/IdentifierUtil.js +0 -1
  241. package/src/sap/ui/mdc/util/InfoBar.js +1 -2
  242. package/src/sap/ui/mdc/util/PromiseCache.js +1 -1
  243. package/src/sap/ui/mdc/util/PropertyHelper.js +15 -8
  244. package/src/sap/ui/mdc/util/TypeMap.js +377 -0
  245. package/src/sap/ui/mdc/util/TypeUtil.js +35 -2
  246. package/src/sap/ui/mdc/util/mapVersions.js +225 -0
  247. package/src/sap/ui/mdc/valuehelp/Dialog.js +52 -33
  248. package/src/sap/ui/mdc/valuehelp/Popover.js +33 -35
  249. package/src/sap/ui/mdc/valuehelp/base/Container.js +193 -62
  250. package/src/sap/ui/mdc/valuehelp/base/Content.js +134 -57
  251. package/src/sap/ui/mdc/{field → valuehelp/base}/DefineConditionPanel.js +426 -197
  252. package/src/sap/ui/mdc/valuehelp/base/DialogTab.js +2 -2
  253. package/src/sap/ui/mdc/valuehelp/base/FilterableListContent.js +140 -47
  254. package/src/sap/ui/mdc/valuehelp/base/ListContent.js +11 -9
  255. package/src/sap/ui/mdc/valuehelp/content/Bool.js +11 -20
  256. package/src/sap/ui/mdc/valuehelp/content/Conditions.js +26 -32
  257. package/src/sap/ui/mdc/valuehelp/content/FixedList.js +14 -17
  258. package/src/sap/ui/mdc/valuehelp/content/FixedListItem.js +60 -0
  259. package/src/sap/ui/mdc/valuehelp/content/MDCTable.js +194 -199
  260. package/src/sap/ui/mdc/valuehelp/content/MTable.js +48 -51
  261. package/test/sap/ui/mdc/testutils/opa/chart/AssertionsViz.js +4 -4
  262. package/test/sap/ui/mdc/testutils/opa/field/Actions.js +1 -1
  263. package/test/sap/ui/mdc/testutils/opa/field/Assertions.js +3 -3
  264. package/test/sap/ui/mdc/testutils/opa/filterfield/Actions.js +4 -2
  265. package/test/sap/ui/mdc/testutils/opa/filterfield/Assertions.js +1 -1
  266. package/test/sap/ui/mdc/testutils/opa/table/Actions.js +41 -70
  267. package/test/sap/ui/mdc/testutils/opa/valueHelp/doWait.js +1 -1
  268. package/src/sap/ui/mdc/designtime/p13n/PersistenceProvider.designtime.js +0 -21
  269. package/src/sap/ui/mdc/util/FormatUtil.js +0 -82
@@ -0,0 +1,36 @@
1
+ /*!
2
+ * OpenUI5
3
+ * (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
4
+ * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
+ */
6
+
7
+ sap.ui.define(function() {
8
+ "use strict";
9
+
10
+ /**
11
+ *
12
+ * Defines the row count mode of the GridTable.
13
+ *
14
+ * @enum {string}
15
+ * @alias sap.ui.mdc.enums.TableRowCountMode
16
+ * @since 1.115
17
+ * @public
18
+ */
19
+ var TableRowCountMode = {
20
+ /**
21
+ * The table automatically fills the height of the surrounding container.
22
+ *
23
+ * @public
24
+ */
25
+ Auto: "Auto",
26
+ /**
27
+ * The table always has as many rows as defined in the <code>rowCount</code> property of <code>GridTableType</code>.
28
+ *
29
+ * @public
30
+ */
31
+ Fixed: "Fixed"
32
+ };
33
+
34
+ return TableRowCountMode;
35
+
36
+ }, /* bExport= */ true);
@@ -0,0 +1,45 @@
1
+ /*!
2
+ * OpenUI5
3
+ * (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
4
+ * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
+ */
6
+
7
+ sap.ui.define(function() {
8
+ "use strict";
9
+
10
+ /**
11
+ *
12
+ * Defines the mode of the table.
13
+ *
14
+ * @enum {string}
15
+ * @alias sap.ui.mdc.enums.TableSelectionMode
16
+ * @since 1.115
17
+ * @public
18
+ */
19
+ var TableSelectionMode = {
20
+ /**
21
+ * No rows/items can be selected (default).
22
+ * @public
23
+ */
24
+ None: "None",
25
+ /**
26
+ * Only one row/item can be selected at a time.
27
+ * @public
28
+ */
29
+ Single: "Single",
30
+ /**
31
+ * Only one row/item can be selected at a time. Should be used for navigation scenarios to indicate the navigated row/item. If this selection
32
+ * mode is used, no <code>rowPress</code> event is fired.
33
+ * @public
34
+ */
35
+ SingleMaster: "SingleMaster",
36
+ /**
37
+ * Multiple rows/items can be selected at a time.
38
+ * @public
39
+ */
40
+ Multi: "Multi"
41
+ };
42
+
43
+ return TableSelectionMode;
44
+
45
+ }, /* bExport= */ true);
@@ -0,0 +1,43 @@
1
+ /*!
2
+ * OpenUI5
3
+ * (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
4
+ * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
+ */
6
+
7
+ sap.ui.define(function() {
8
+ "use strict";
9
+
10
+ /**
11
+ *
12
+ * Defines the type of table used in the MDC table.
13
+ *
14
+ * @enum {string}
15
+ * @alias sap.ui.mdc.enums.TableType
16
+ * @since 1.115
17
+ * @public
18
+ */
19
+ var TableType = {
20
+ /**
21
+ * Grid table ({@link sap.ui.table.Table} control) is used (default)
22
+ *
23
+ * @public
24
+ */
25
+ Table: "Table",
26
+ /**
27
+ * Tree table ({@link sap.ui.table.TreeTable} control) is used.
28
+ *
29
+ * @private
30
+ * @experimental
31
+ */
32
+ TreeTable: "TreeTable",
33
+ /**
34
+ * Responsive table ({@link sap.m.Table} control) is used.
35
+ *
36
+ * @public
37
+ */
38
+ ResponsiveTable: "ResponsiveTable"
39
+ };
40
+
41
+ return TableType;
42
+
43
+ }, /* bExport= */ true);
@@ -0,0 +1,41 @@
1
+ /*
2
+ * OpenUI5
3
+ * (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
4
+ * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
+ */
6
+ sap.ui.define(function () {
7
+ "use strict";
8
+ /**
9
+ * Enumeration of the propagation reason in the condition propagation callback of the {@link sap.ui.mdc.ValueHelp ValueHelp}
10
+ *
11
+ * @enum {string}
12
+ * @public
13
+ * @since 1.115
14
+ * @alias sap.ui.mdc.enums.ValueHelpPropagationReason
15
+ */
16
+ var ValueHelpPropagationReason = {
17
+ /**
18
+ * Triggered by connected control after processing valuehelp output
19
+ *
20
+ * @private
21
+ * @ui5-restricted sap.fe
22
+ */
23
+ ControlChange: "ControlChange",
24
+ /**
25
+ * Triggered by <code>ValueHelp</code> itself on selection
26
+ *
27
+ * @private
28
+ * @ui5-restricted sap.fe
29
+ */
30
+ Select: "Select",
31
+ /**
32
+ * Triggered by <code>ValueHelp</code> itself on <code>getItemForValue</code>
33
+ *
34
+ * @private
35
+ * @ui5-restricted sap.fe
36
+ */
37
+ Info: "Info"
38
+ };
39
+
40
+ return ValueHelpPropagationReason;
41
+ }, /* bExport= */ true);
@@ -0,0 +1,46 @@
1
+ /*!
2
+ * OpenUI5
3
+ * (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
4
+ * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
5
+ */
6
+
7
+ // Provides enumeration sap.ui.mdc.enums.ValueHelpSelectionType
8
+ sap.ui.define(function() {
9
+ "use strict";
10
+
11
+
12
+ /**
13
+ * Enumeration of the possible selection types
14
+ *
15
+ * @enum {string}
16
+ * @private
17
+ * @ui5-restricted sap.ui.mdc
18
+ * @since 1.115
19
+ * @alias sap.ui.mdc.enums.ValueHelpSelectionType
20
+ */
21
+ var ValueHelpSelectionType = {
22
+ /**
23
+ * The given conditions are set and replace the existing ones.
24
+ * @private
25
+ * @ui5-restricted sap.ui.mdc
26
+ */
27
+ Set: "Set",
28
+
29
+ /**
30
+ * The given conditions are just added to the existing ones, if they don't already exist.
31
+ * @private
32
+ * @ui5-restricted sap.ui.mdc
33
+ */
34
+ Add: "Add",
35
+
36
+ /**
37
+ * The given conditions are removed.
38
+ * @private
39
+ * @ui5-restricted sap.ui.mdc
40
+ */
41
+ Remove: "Remove"
42
+ };
43
+
44
+ return ValueHelpSelectionType;
45
+
46
+ }, /* bExport= */ true);
@@ -11,13 +11,13 @@ sap.ui.define([
11
11
  'sap/ui/model/ParseException',
12
12
  'sap/ui/model/ValidateException',
13
13
  'sap/ui/model/type/String',
14
- 'sap/ui/mdc/enum/FieldDisplay',
14
+ 'sap/ui/mdc/enums/FieldDisplay',
15
+ 'sap/ui/mdc/enums/OperatorValueType',
15
16
  'sap/ui/mdc/condition/FilterOperatorUtil',
16
- 'sap/ui/mdc/condition/Operator',
17
17
  'sap/ui/mdc/condition/Condition',
18
18
  'sap/ui/mdc/condition/ConditionValidateException',
19
- 'sap/ui/mdc/enum/BaseType',
20
- 'sap/ui/mdc/enum/ConditionValidated',
19
+ 'sap/ui/mdc/enums/BaseType',
20
+ 'sap/ui/mdc/enums/ConditionValidated',
21
21
  'sap/base/util/merge',
22
22
  'sap/base/strings/whitespaceReplacer',
23
23
  'sap/ui/base/SyncPromise'
@@ -29,8 +29,8 @@ sap.ui.define([
29
29
  ValidateException,
30
30
  StringType,
31
31
  FieldDisplay,
32
+ OperatorValueType,
32
33
  FilterOperatorUtil,
33
- Operator,
34
34
  Condition,
35
35
  ConditionValidateException,
36
36
  BaseType,
@@ -48,30 +48,28 @@ sap.ui.define([
48
48
  * Constructor for a Condition type.
49
49
  *
50
50
  * @class
51
- * This class represents a type that is used to map a single condition to a single-value control
51
+ * This class represents a type that is used to map a single condition to a single-value control.
52
52
  *
53
53
  * @extends sap.ui.model.SimpleType
54
54
  *
55
55
  * @author SAP SE
56
- * @version 1.113.0
56
+ * @version 1.115.0
57
57
  *
58
58
  * @since 1.62.0
59
- * @private
60
- * @ui5-restricted sap.ui.mdc.field.FieldBase, sap.fe
61
- * @MDC_PUBLIC_CANDIDATE
59
+ * @public
62
60
  *
63
61
  * @param {object} [oFormatOptions] Formatting options
64
62
  * @param {sap.ui.model.Type} [oFormatOptions.valueType] Type of the value of the condition (used for formatting, parsing and validating)
65
63
  * @param {string[]} [oFormatOptions.operators] Possible operators to be used in the condition
66
- * @param {sap.ui.mdc.enum.FieldDisplay} [oFormatOptions.display] DisplayFormat used to visualize a value
67
- * @param {string} [oFormatOptions.fieldHelpID] ID of the field help to determine the key and description
64
+ * @param {sap.ui.mdc.enums.FieldDisplay} [oFormatOptions.display] DisplayFormat used to visualize a value
65
+ * @param {string} [oFormatOptions.valueHelpID] ID of the value help to determine the key and description
68
66
  * @param {boolean} [oFormatOptions.hideOperator] If set, only the value of the condition is shown, but no operator. (Use it only if just one operator is supported.)
69
67
  * @param {int} [oFormatOptions.maxConditions] Maximum number of allowed conditions
70
68
  * @param {sap.ui.model.Context} [oFormatOptions.bindingContext] <code>BindingContext</code> of field. Used to get a key or description from the value help using in/out parameters. (In a table, the value help might be connected to a different row)
71
69
  * @param {sap.ui.model.Type} [oFormatOptions.originalDateType] Type used on field, for example, for date types; a different type is used internally to have different <code>formatOptions</code>
72
- * @param {sap.ui.model.Type} [oFormatOptions.additionalType] additional Type used on other part of a field. (This is the case for unit fields.)
73
- * @param {sap.ui.model.Type[]} [oFormatOptions.compositeTypes] additional Types used for parts of a <code>CompositeType</code>
74
- * @param {function} [oFormatOptions.getConditions] Function to get the existing conditions of the field. Only used if <code>isUnit</code> is set. // TODO: better solution
70
+ * @param {sap.ui.model.Type} [oFormatOptions.additionalType] additional type used on other part of a field. (For example, for unit fields.)
71
+ * @param {sap.ui.model.Type[]} [oFormatOptions.compositeTypes] additional types used for parts of a <code>CompositeType</code>
72
+ * @param {function} [oFormatOptions.getConditions] Function to get the existing conditions of the field.
75
73
  * @param {function} [oFormatOptions.asyncParsing] Callback function to tell the <code>Field</code> the parsing is asynchronous.
76
74
  * @param {sap.ui.mdc.condition.ConditionObject} [oFormatOptions.navigateCondition] Condition of keyboard navigation. If this is filled, no real parsing is needed as the condition has already been determined and is just returned
77
75
  * @param {object} [oFormatOptions.delegate] Field delegate to handle model-specific logic
@@ -79,7 +77,7 @@ sap.ui.define([
79
77
  * @param {boolean} [oFormatOptions.preventGetDescription] If set, description is not read by <code>formatValue</code> as it is known that no description exists or might be set later
80
78
  * @param {string} [oFormatOptions.defaultOperatorName] Name of the default <code>Operator</code>
81
79
  * @param {boolean} [oFormatOptions.convertWhitespaces] If set, whitespaces will be replaced by special characters to display whitespaces in HTML
82
- * @param {sap.ui.core.Control} [oFormatOptions.control] Instance if the calling control
80
+ * @param {sap.ui.core.Control} [oFormatOptions.control] Instance of the calling control
83
81
  * @param {object} [oConstraints] Value constraints
84
82
  * @alias sap.ui.mdc.field.ConditionType
85
83
  */
@@ -109,24 +107,22 @@ sap.ui.define([
109
107
 
110
108
  /**
111
109
  * Formats the given condition to an output value of the given target type.
112
- * This values are formatted using the given data type. Depending of the operator
113
- * and the configuration (set in <code>FormatOptions</code>) a description will be determined via given value help or delegate.
110
+ * These values are formatted using the given data type. Depending on the operator
111
+ * and the configuration (set in <code>FormatOptions</code>), a description will be determined by a given value help or delegate.
114
112
  *
115
113
  * @param {sap.ui.mdc.condition.ConditionObject} oCondition
116
114
  * The condition to be formatted
117
115
  * @param {string} sTargetType
118
- * The target type; see {@link topic:ac56d92162ed47ff858fdf1ce26c18c4 Allowed Property Types}
119
- * In addition to the standard target types <code>sap.ui.mdc.raw</code> can be used. In this case the value is not formatted and just
120
- * forwarded to the target. If the value is an array representing data for a <code>CompositeType</code> the index of the needed raw value can be added to the
121
- * name (For example if a unit should be forwarded as raw value <code>sap.ui.mdc.raw:1</code> can be used).
116
+ * The target type; see {@link topic:ac56d92162ed47ff858fdf1ce26c18c4 Allowed Property Types}.
117
+ * In addition to the standard target types, <code>sap.ui.mdc.raw</code> can be used. In this case the value is not formatted and just
118
+ * forwarded to the target. If the value is an array representing data for a <code>CompositeType</code>, the index of the needed raw value can be added to the
119
+ * name (For example, if a unit should be forwarded as raw value, <code>sap.ui.mdc.raw:1</code> can be used).
122
120
  * @return {any|Promise}
123
121
  * The formatted output value or a <code>Promise</code> resolving with the formatted value
124
122
  * @throws {sap.ui.model.FormatException}
125
123
  * If formatting to the target type is not possible
126
124
  *
127
- * @private
128
- * @ui5-restricted sap.ui.mdc.field.FieldBase, sap.fe
129
- * @MDC_PUBLIC_CANDIDATE
125
+ * @public
130
126
  */
131
127
  ConditionType.prototype.formatValue = function(oCondition, sTargetType) {
132
128
 
@@ -289,40 +285,70 @@ sap.ui.define([
289
285
  /**
290
286
  * Parses an external value of the given source type to a condition that holds the value in model
291
287
  * representation.
292
- * These values are parsed using the given data type. Depending of the operator
293
- * and the configuration (set in <code>FormatOptions</code>) a value will be determined via given value help or delegate.
288
+ * These values are parsed using the given data type. Depending on the operator
289
+ * and the configuration (set in <code>FormatOptions</code>), a value will be determined by a given value help or delegate.
294
290
  *
295
291
  * @param {any} vValue
296
- * The value to be parsed
292
+ * The value that is parsed
297
293
  * @param {string} sSourceType
298
294
  * The type of the given value; see
299
295
  * {@link topic:ac56d92162ed47ff858fdf1ce26c18c4 Allowed Property Types}
300
- * In addition to the standard source types <code>sap.ui.mdc.raw</code> can be used. In this case the value is not parsed and just
301
- * used in the condition. If the value of the condition is an array representing data for a <code>CompositeType</code> the index of the needed raw value can be added to the
302
- * name (For example if a unit should be forwarded as raw value <code>sap.ui.mdc.raw:1</code> can be used).
296
+ * In addition to the standard source types, <code>sap.ui.mdc.raw</code> can be used. In this case the value is not parsed and just
297
+ * used in the condition. If the value of the condition is an array representing data for a <code>CompositeType</code>, the index of the needed raw value can be added to the
298
+ * name (For example, if a unit should be forwarded as raw value <code>sap.ui.mdc.raw:1</code> can be used).
303
299
  * @return {null|sap.ui.mdc.condition.ConditionObject|Promise<null|sap.ui.mdc.condition.ConditionObject>}
304
300
  * The condition or a <code>Promise</code> resolving with the condition.
305
- * If there is no value <code>null</code> is returned.
301
+ * If there is no value, <code>null</code> is returned.
306
302
  * @throws {sap.ui.model.ParseException}
307
- * If parsing to the model type is not possible; the message of the exception is language
308
- * dependent as it may be displayed on the UI
303
+ * If parsing to the model type is not possible; the message of the exception is language-dependent as it may be displayed on the UI
309
304
  *
310
- * @private
311
- * @ui5-restricted sap.ui.mdc.field.FieldBase, sap.fe
312
- * @MDC_PUBLIC_CANDIDATE
305
+ * @public
313
306
  */
314
307
  ConditionType.prototype.parseValue = function(vValue, sSourceType) {
315
308
 
316
- if (this._bDestroyed) { // if destroyed do nothing
317
- return null;
318
- }
319
-
309
+ var bInputValidationEnabled = _isInputValidationEnabled.call(this);
320
310
  if (!sSourceType) {
321
311
  sSourceType = "string";
322
312
  } else if (sSourceType === "any" && typeof vValue === "string") {
323
313
  sSourceType = "string";
324
314
  }
325
315
 
316
+ return this._parseValue(vValue, sSourceType, bInputValidationEnabled);
317
+
318
+ };
319
+
320
+ // own function as API for parseValue cannot be extended by inherited class
321
+ /**
322
+ * Parses an external value of the given source type to a condition that holds the value in model
323
+ * representation.
324
+ * These values are parsed using the given data type. Depending on the operator
325
+ * and the configuration (set in <code>FormatOptions</code>) a value will be determined by a given value help or delegate.
326
+ *
327
+ * @param {any} vValue
328
+ * The value that is parsed
329
+ * @param {string} sSourceType
330
+ * The type of the given value; see
331
+ * {@link topic:ac56d92162ed47ff858fdf1ce26c18c4 Allowed Property Types}
332
+ * In addition to the standard source types, <code>sap.ui.mdc.raw</code> can be used. In this case the value is not parsed and just
333
+ * used in the condition. If the value of the condition is an array representing data for a <code>CompositeType</code> ,the index of the needed raw value can be added to the
334
+ * name (For example, if a unit should be forwarded as raw value <code>sap.ui.mdc.raw:1</code> can be used).
335
+ * @param {boolean} bInputValidationEnabled
336
+ * If set, input validation is enabled, otherwise disabled, even if delegate or ValueHelp allows it. (Pasting multiple values)
337
+ * @return {null|sap.ui.mdc.condition.ConditionObject|Promise<null|sap.ui.mdc.condition.ConditionObject>}
338
+ * The condition or a <code>Promise</code> resolving with the condition.
339
+ * If there is no value, <code>null</code> is returned.
340
+ * @throws {sap.ui.model.ParseException}
341
+ * If parsing to the model type is not possible; the message of the exception is language-dependent as it may be displayed on the UI
342
+ *
343
+ * @private
344
+ * @ui5-restricted sap.ui.mdc.field.ConditionsType
345
+ */
346
+ ConditionType.prototype._parseValue = function(vValue, sSourceType, bInputValidationEnabled) {
347
+
348
+ if (this._bDestroyed) { // if destroyed do nothing
349
+ return null;
350
+ }
351
+
326
352
  var oNavigateCondition = this.oFormatOptions.navigateCondition;
327
353
  if (oNavigateCondition) {
328
354
  // condition already known from navigation. Just check if it is really the same as the input.
@@ -333,14 +359,13 @@ sap.ui.define([
333
359
  }
334
360
 
335
361
  var sDisplay = _getDisplay.call(this);
336
- var bInputValidationEnabled = _isInputValidationEnabled.call(this);
337
362
  var oType = _getValueType.call(this);
338
363
  var oOriginalType = _getOriginalType.call(this);
339
364
  var aOperators = _getOperators.call(this);
340
365
  var bIsUnit = _isUnit(oType);
341
366
  var sDefaultOperator;
342
367
 
343
- if (vValue === null || vValue === undefined || (vValue === "" && !bInputValidationEnabled)) { // check if "" is a key in FieldHelp
368
+ if (vValue === null || vValue === undefined || (vValue === "" && !bInputValidationEnabled)) { // check if "" is a key in ValueHelp
344
369
  if (!_isCompositeType.call(this, oType)) {
345
370
  return null; // TODO: for all types???
346
371
  }
@@ -366,7 +391,7 @@ sap.ui.define([
366
391
  oOperator = _getDefaultOperator.call(this, aOperators, oType);
367
392
 
368
393
  if (bInputValidationEnabled && !_isCompositeType.call(this, oType)) {
369
- // try first to use EQ and find it in FieldHelp. If not found try later with default operator
394
+ // try first to use EQ and find it in ValueHelp. If not found try later with default operator
370
395
  var oEQOperator = FilterOperatorUtil.getEQOperator(aOperators);
371
396
  if (aOperators.indexOf(oEQOperator.name) >= 0) { // as EQ is returned if not in List
372
397
  bCheckForDefault = !!oOperator && oOperator.name !== oEQOperator.name; // only if default operator exists and is different
@@ -398,7 +423,7 @@ sap.ui.define([
398
423
  var iCallCount = this._oCalls.last;
399
424
 
400
425
  if ((!bCompositeType || bIsUnit) && oOperator.validateInput && bInputValidationEnabled) {
401
- // use FieldHelp to determine condition (for unit part also if composite type used)
426
+ // use ValueHelp to determine condition (for unit part also if composite type used)
402
427
  oCondition = _parseDetermineKeyAndDescription.call(this, oOperator, vValue, oType, bUseDefaultOperator, bCheckForDefault, aOperators, sDisplay, true);
403
428
  if (oCondition instanceof Promise) {
404
429
  return _fnReturnPromise.call(this, oCondition);
@@ -483,12 +508,12 @@ sap.ui.define([
483
508
  var oFormatOptions = oOriginalType.getFormatOptions();
484
509
  var oConstraints = oOriginalType.getConstraints();
485
510
  var oDelegate = this.oFormatOptions.delegate;
486
- var oPayload = this.oFormatOptions.payload;
487
- var sBaseType = oDelegate && oDelegate.getTypeUtil(oPayload).getBaseType(sName, oFormatOptions, oConstraints); // don't use _getBaseType to get "real" unit type
511
+ var oField = this.oFormatOptions.control;
512
+ var sBaseType = oDelegate && oDelegate.getTypeMap(oField).getBaseType(sName, oFormatOptions, oConstraints); // don't use _getBaseType to get "real" unit type
488
513
  if ((sBaseType === BaseType.Unit || sBaseType === BaseType.DateTime) &&
489
514
  !oCondition.values[0][1] && oType._aCurrentValue) {
490
515
  // TODO: if no unit provided use last one
491
- var sUnit = oType._aCurrentValue[1] ? oType._aCurrentValue[1] : null; // if no unit set null
516
+ var sUnit = oType._aCurrentValue[1] === undefined ? null : oType._aCurrentValue[1]; // undefined in CompositeType means "not changed" -> if no current unit it needs to be null
492
517
  oCondition.values[0][1] = sUnit;
493
518
  if (oCondition.operator === "BT") {
494
519
  oCondition.values[1][1] = sUnit;
@@ -560,7 +585,7 @@ sap.ui.define([
560
585
  var fnSuccess = function(oResult) {
561
586
  if (oResult) {
562
587
  var aValues = [oResult.key];
563
- if (oOperator.valueTypes.length > 1 && oOperator.valueTypes[1] !== Operator.ValueType.Static) {
588
+ if (oOperator.valueTypes.length > 1 && oOperator.valueTypes[1] !== OperatorValueType.Static) {
564
589
  // description is supported
565
590
  aValues.push(oResult.description);
566
591
  }
@@ -569,7 +594,7 @@ sap.ui.define([
569
594
  // no empty key -> no condition
570
595
  return null;
571
596
  } else {
572
- // FieldHelp might not fire an exception if nothing found -> but handle this as error
597
+ // ValueHelp might not fire an exception if nothing found -> but handle this as error
573
598
  return fnError.call(this, new ParseException(this._oResourceBundle.getText("valuehelp.VALUE_NOT_EXIST", [vValue])));// use original value in message
574
599
  }
575
600
  };
@@ -635,7 +660,7 @@ sap.ui.define([
635
660
  var oCondition;
636
661
 
637
662
  if (oOperator && aOperators.indexOf(oOperator.name) >= 0) {
638
- oCondition = oOperator.getCondition(vValue, oType, FieldDisplay.Value, true); // use Value as displayFormat if nothing found in FieldHelp
663
+ oCondition = oOperator.getCondition(vValue, oType, FieldDisplay.Value, true); // use Value as displayFormat if nothing found in ValueHelp
639
664
  oCondition.validated = ConditionValidated.NotValidated;
640
665
  }
641
666
 
@@ -684,16 +709,14 @@ sap.ui.define([
684
709
  * Validates a given condition. The values of the condition are validated using the given data type.
685
710
  *
686
711
  * @param {sap.ui.mdc.condition.ConditionObject} oCondition
687
- * The condition to be validated
712
+ * The condition that is validated
688
713
  * @returns {void|Promise}
689
714
  * <code>undefined</code> or a <code>Promise</code> resolving with an undefined value
690
715
  * @throws {sap.ui.mdc.condition.ConditionValidateException}
691
716
  * If at least one of the values of the condition is not valid for the given data type; the message of the exception is
692
- * language dependent as it may be displayed on the UI
717
+ * language-dependent as it may be displayed on the UI
693
718
  *
694
- * @private
695
- * @ui5-restricted sap.ui.mdc.field.FieldBase, sap.fe
696
- * @MDC_PUBLIC_CANDIDATE
719
+ * @public
697
720
  */
698
721
  ConditionType.prototype.validateValue = function(oCondition) {
699
722
 
@@ -711,16 +734,31 @@ sap.ui.define([
711
734
  // check if type allows to be null
712
735
  if (FilterOperatorUtil.onlyEQ(aOperators)) {
713
736
  // TODO: also for FilterField case?
737
+ var vCheckValue = null;
714
738
  try {
715
739
  if (oType.hasOwnProperty("_sParsedEmptyString") && oType._sParsedEmptyString !== null) { //TODO: find solution for all types
716
740
  // empty string is parsed as empty string or "0", so validate for this
717
- oType.validateValue(oType._sParsedEmptyString);
718
- } else {
719
- oType.validateValue(null);
741
+ vCheckValue = oType._sParsedEmptyString;
720
742
  }
743
+ oType.validateValue(vCheckValue);
721
744
  } catch (oException) {
722
745
  if (oException instanceof ValidateException) {
723
- throw new ConditionValidateException(oException.message, oException.violatedConstraints, null);
746
+ try {
747
+ if (oOriginalType && !bCompositeType) {
748
+ // As internal yyyy-MM-dd is used as pattern for dates (times similar) the
749
+ // ValidateException might contain this as pattern. The user should see the pattern thats shown
750
+ // So try to validate date with the original type to get ValidateException with right pattern.
751
+ // Not for CompositeTypes as here the parts might have different configuartion what leads to different messages.
752
+ oOriginalType.validateValue(vCheckValue);
753
+ }
754
+ throw oException;
755
+ } catch (oException) {
756
+ if (oException instanceof ValidateException) {
757
+ // add condition to exception to improve mapping in FieldBase handleValidationError
758
+ throw new ConditionValidateException(oException.message, oException.violatedConstraints, null);
759
+ }
760
+ throw oException;
761
+ }
724
762
  } else {
725
763
  //validation breaks with runtime error -> just ignore
726
764
  //TODO: is this the right way?
@@ -826,13 +864,13 @@ sap.ui.define([
826
864
 
827
865
  }
828
866
 
829
- function _getFieldHelp() {
867
+ function _getValueHelp() {
830
868
 
831
- var sID = this.oFormatOptions.fieldHelpID;
869
+ var sID = this.oFormatOptions.valueHelpID;
832
870
  if (sID) {
833
- var oFieldHelp = sap.ui.getCore().byId(sID);
834
- if (oFieldHelp && oFieldHelp.isValidationSupported()) {
835
- return oFieldHelp;
871
+ var oValueHelp = sap.ui.getCore().byId(sID);
872
+ if (oValueHelp && oValueHelp.isValidationSupported()) {
873
+ return oValueHelp;
836
874
  }
837
875
  }
838
876
 
@@ -937,8 +975,8 @@ sap.ui.define([
937
975
  var oFormatOptions = oType.getFormatOptions();
938
976
  var oConstraints = oType.getConstraints();
939
977
  var oDelegate = this.oFormatOptions.delegate;
940
- var oPayload = this.oFormatOptions.payload;
941
- var sBaseType = oDelegate ? oDelegate.getTypeUtil(oPayload).getBaseType(sType, oFormatOptions, oConstraints) : BaseType.String;
978
+ var oField = this.oFormatOptions.control;
979
+ var sBaseType = oDelegate ? oDelegate.getTypeMap(oField).getBaseType(sType, oFormatOptions, oConstraints) : BaseType.String;
942
980
 
943
981
  if (sBaseType === BaseType.Unit) {
944
982
  sBaseType = BaseType.Numeric;
@@ -950,28 +988,26 @@ sap.ui.define([
950
988
 
951
989
  function _isInputValidationEnabled() {
952
990
 
953
- var oFieldHelp = _getFieldHelp.call(this);
991
+ var oValueHelp = _getValueHelp.call(this);
954
992
  var oDelegate = this.oFormatOptions.delegate;
955
- var oPayload = this.oFormatOptions.payload;
956
993
 
957
994
  if (oDelegate) {
958
- return oDelegate.isInputValidationEnabled(oPayload, oFieldHelp);
995
+ return oDelegate.isInputValidationEnabled(this.oFormatOptions.control, oValueHelp);
959
996
  } else {
960
- return !!oFieldHelp;
997
+ return !!oValueHelp;
961
998
  }
962
999
 
963
1000
  }
964
1001
 
965
1002
  function _isInvalidInputAllowed() {
966
1003
 
967
- var oFieldHelp = _getFieldHelp.call(this);
1004
+ var oValueHelp = _getValueHelp.call(this);
968
1005
  var oDelegate = this.oFormatOptions.delegate;
969
- var oPayload = this.oFormatOptions.payload;
970
1006
 
971
1007
  if (oDelegate) {
972
- return oDelegate.isInvalidInputAllowed(oPayload, oFieldHelp);
973
- } else if (oFieldHelp) {
974
- return !oFieldHelp.getValidateInput();
1008
+ return oDelegate.isInvalidInputAllowed(this, oValueHelp);
1009
+ } else if (oValueHelp) {
1010
+ return !oValueHelp.getValidateInput();
975
1011
  } else {
976
1012
  return true;
977
1013
  }
@@ -980,16 +1016,13 @@ sap.ui.define([
980
1016
 
981
1017
  function _getItemForValue(vValue, vParsedValue, oType, oBindingContext, bCheckKey, bCheckDescription) {
982
1018
 
983
- var oFieldHelp = _getFieldHelp.call(this);
1019
+ var oValueHelp = _getValueHelp.call(this);
984
1020
  var oDelegate = this.oFormatOptions.delegate;
985
- var oPayload = this.oFormatOptions.payload;
986
1021
  var oControl = this.oFormatOptions.control;
987
1022
  var oConfig = {
988
1023
  value: vValue,
989
1024
  parsedValue: vParsedValue,
990
1025
  dataType: oType,
991
- inParameters: undefined, // TODO: needed?
992
- outParameters: undefined, // TODO: needed?
993
1026
  bindingContext: oBindingContext,
994
1027
  checkKey: bCheckKey,
995
1028
  checkDescription: bCheckDescription,
@@ -998,22 +1031,21 @@ sap.ui.define([
998
1031
  };
999
1032
 
1000
1033
  if (oDelegate) {
1001
- return oDelegate.getItemForValue(oPayload, oFieldHelp, oConfig);
1002
- } else if (oFieldHelp) {
1003
- return oFieldHelp.getItemForValue(oConfig);
1034
+ return oDelegate.getItemForValue(oControl, oValueHelp, oConfig);
1035
+ } else if (oValueHelp) {
1036
+ return oValueHelp.getItemForValue(oConfig);
1004
1037
  }
1005
1038
 
1006
1039
  }
1007
1040
 
1008
1041
  function _getDescription(vKey, oCondition, oType, oBindingContext) {
1009
1042
 
1010
- var oFieldHelp = _getFieldHelp.call(this);
1043
+ var oValueHelp = _getValueHelp.call(this);
1011
1044
  var oDelegate = this.oFormatOptions.delegate;
1012
- var oPayload = this.oFormatOptions.payload;
1013
1045
  var oControl = this.oFormatOptions.control;
1014
1046
  if (oDelegate) {
1015
- return oDelegate.getDescription(oPayload, oFieldHelp, vKey, oCondition.inParameters, oCondition.outParameters, oBindingContext, undefined, undefined, oCondition.payload, oControl, oType);
1016
- } else if (oFieldHelp) {
1047
+ return oDelegate.getDescription(oControl, oValueHelp, vKey, oCondition.inParameters, oCondition.outParameters, oBindingContext, undefined, undefined, oCondition.payload, oControl, oType);
1048
+ } else if (oValueHelp) {
1017
1049
  var oConfig = {
1018
1050
  value: vKey,
1019
1051
  parsedValue: vKey,
@@ -1026,7 +1058,7 @@ sap.ui.define([
1026
1058
  exception: FormatException,
1027
1059
  control: oControl
1028
1060
  };
1029
- return oFieldHelp.getItemForValue(oConfig);
1061
+ return oValueHelp.getItemForValue(oConfig);
1030
1062
  }
1031
1063
 
1032
1064
  }