@openui5/sap.ui.mdc 1.108.2 → 1.110.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.
- package/.reuse/dep5 +16 -16
- package/THIRDPARTY.txt +2 -2
- package/package.json +4 -4
- package/src/sap/ui/mdc/.library +2 -2
- package/src/sap/ui/mdc/ActionToolbar.js +5 -5
- package/src/sap/ui/mdc/AggregationBaseDelegate.js +1 -1
- package/src/sap/ui/mdc/BaseDelegate.js +1 -1
- package/src/sap/ui/mdc/Chart.js +32 -34
- package/src/sap/ui/mdc/ChartDelegate.js +23 -19
- package/src/sap/ui/mdc/ChartRenderer.js +1 -1
- package/src/sap/ui/mdc/Control.js +2 -2
- package/src/sap/ui/mdc/Delegate.js +1 -1
- package/src/sap/ui/mdc/Element.js +2 -2
- package/src/sap/ui/mdc/Field.js +30 -20
- package/src/sap/ui/mdc/FilterBar.js +13 -8
- package/src/sap/ui/mdc/FilterBarDelegate.js +14 -10
- package/src/sap/ui/mdc/FilterField.js +8 -15
- package/src/sap/ui/mdc/Link.js +2 -2
- package/src/sap/ui/mdc/LinkDelegate.js +4 -2
- package/src/sap/ui/mdc/MultiValueField.js +2 -2
- package/src/sap/ui/mdc/Table.js +375 -632
- package/src/sap/ui/mdc/TableDelegate.js +34 -7
- package/src/sap/ui/mdc/ValueHelp.js +38 -21
- package/src/sap/ui/mdc/ValueHelpDelegate.js +86 -52
- package/src/sap/ui/mdc/actiontoolbar/ActionToolbarAction.js +86 -65
- package/src/sap/ui/mdc/actiontoolbar/ActionToolbarActionRenderer.js +7 -12
- package/src/sap/ui/mdc/chart/ChartImplementationContainer.js +6 -6
- package/src/sap/ui/mdc/chart/ChartImplementationContainerRenderer.js +1 -1
- package/src/sap/ui/mdc/chart/ChartSelectionDetails.js +3 -3
- package/src/sap/ui/mdc/chart/ChartSettings.js +1 -1
- package/src/sap/ui/mdc/chart/ChartToolbar.js +22 -9
- package/src/sap/ui/mdc/chart/ChartTypeButton.js +22 -20
- package/src/sap/ui/mdc/chart/DrillBreadcrumbs.js +1 -1
- package/src/sap/ui/mdc/chart/DrillStackHandler.js +4 -6
- package/src/sap/ui/mdc/chart/Item.js +1 -1
- package/src/sap/ui/mdc/chart/PropertyHelper.js +2 -2
- package/src/sap/ui/mdc/chart/SelectionDetailsActions.js +1 -1
- package/src/sap/ui/mdc/condition/Condition.js +4 -5
- package/src/sap/ui/mdc/condition/ConditionConverter.js +2 -2
- package/src/sap/ui/mdc/condition/ConditionModel.js +2 -2
- package/src/sap/ui/mdc/condition/ConditionModelPropertyBinding.js +1 -1
- package/src/sap/ui/mdc/condition/ConditionValidateException.js +62 -0
- package/src/sap/ui/mdc/condition/FilterConverter.js +8 -4
- package/src/sap/ui/mdc/condition/FilterOperatorUtil.js +4 -16
- package/src/sap/ui/mdc/condition/Operator.js +2 -2
- package/src/sap/ui/mdc/condition/OperatorDynamicDateOption.js +4 -2
- package/src/sap/ui/mdc/condition/RangeOperator.js +2 -2
- package/src/sap/ui/mdc/designtime/Util.js +1 -1
- package/src/sap/ui/mdc/designtime/actiontoolbar/ActionToolbar.designtime.js +2 -2
- package/src/sap/ui/mdc/designtime/actiontoolbar/ActionToolbarAction.designtime.js +1 -1
- package/src/sap/ui/mdc/designtime/chart/Chart.designtime.js +2 -2
- package/src/sap/ui/mdc/designtime/field/Field.designtime.js +3 -4
- package/src/sap/ui/mdc/designtime/field/FieldBase.designtime.js +1 -1
- package/src/sap/ui/mdc/designtime/field/FilterField.designtime.js +1 -1
- package/src/sap/ui/mdc/designtime/field/MultiValueField.designtime.js +1 -1
- package/src/sap/ui/mdc/designtime/filterbar/FilterBar.designtime.js +2 -2
- package/src/sap/ui/mdc/designtime/filterbar/FilterBarBase.designtime.js +1 -1
- package/src/sap/ui/mdc/designtime/library.designtime.js +1 -1
- package/src/sap/ui/mdc/designtime/link/Panel.designtime.js +1 -1
- package/src/sap/ui/mdc/designtime/link/PanelItem.designtime.js +7 -6
- package/src/sap/ui/mdc/designtime/p13n/PersistenceProvider.designtime.js +1 -1
- package/src/sap/ui/mdc/designtime/table/Table.designtime.js +2 -2
- package/src/sap/ui/mdc/enum/ActionToolbarActionAlignment.js +1 -1
- package/src/sap/ui/mdc/enum/BaseType.js +1 -1
- package/src/sap/ui/mdc/enum/ConditionValidated.js +1 -1
- package/src/sap/ui/mdc/enum/ContentMode.js +1 -1
- package/src/sap/ui/mdc/enum/EditMode.js +1 -1
- package/src/sap/ui/mdc/enum/FieldDisplay.js +1 -1
- package/src/sap/ui/mdc/enum/OutParameterMode.js +1 -1
- package/src/sap/ui/mdc/enum/PersistenceMode.js +1 -1
- package/src/sap/ui/mdc/enum/ProcessingStrategy.js +1 -1
- package/src/sap/ui/mdc/enum/PropagationReason.js +1 -1
- package/src/sap/ui/mdc/enum/SelectType.js +1 -1
- package/src/sap/ui/mdc/field/BoolFieldHelp.js +3 -2
- package/src/sap/ui/mdc/field/ConditionFieldHelp.js +3 -2
- package/src/sap/ui/mdc/field/ConditionType.js +31 -15
- package/src/sap/ui/mdc/field/ConditionsType.js +98 -23
- package/src/sap/ui/mdc/field/CustomFieldHelp.js +3 -2
- package/src/sap/ui/mdc/field/CustomFieldInfo.js +2 -2
- package/src/sap/ui/mdc/field/DefineConditionPanel.js +42 -7
- package/src/sap/ui/mdc/field/DynamicDateRangeConditionsType.js +2 -2
- package/src/sap/ui/mdc/field/FieldBase.js +131 -236
- package/src/sap/ui/mdc/field/FieldBaseDelegate.js +2 -35
- package/src/sap/ui/mdc/field/FieldBaseRenderer.js +1 -1
- package/src/sap/ui/mdc/field/FieldHelpBase.js +9 -7
- package/src/sap/ui/mdc/field/FieldHelpBaseDelegate.js +2 -1
- package/src/sap/ui/mdc/field/FieldInfoBase.js +2 -2
- package/src/sap/ui/mdc/field/FieldInput.js +2 -2
- package/src/sap/ui/mdc/field/FieldInputRenderUtil.js +2 -2
- package/src/sap/ui/mdc/field/FieldInputRenderer.js +1 -1
- package/src/sap/ui/mdc/field/FieldMultiInput.js +2 -2
- package/src/sap/ui/mdc/field/FieldMultiInputRenderer.js +1 -1
- package/src/sap/ui/mdc/field/FieldValueHelp.js +3 -2
- package/src/sap/ui/mdc/field/FieldValueHelpContentWrapperBase.js +3 -2
- package/src/sap/ui/mdc/field/FieldValueHelpDelegate.js +2 -1
- package/src/sap/ui/mdc/field/FieldValueHelpMTableWrapper.js +8 -7
- package/src/sap/ui/mdc/field/FieldValueHelpMdcTableWrapper.js +10 -9
- package/src/sap/ui/mdc/field/FieldValueHelpTableWrapperBase.js +3 -2
- package/src/sap/ui/mdc/field/FieldValueHelpUITableWrapper.js +8 -7
- package/src/sap/ui/mdc/field/InParameter.js +3 -2
- package/src/sap/ui/mdc/field/ListFieldHelp.js +3 -2
- package/src/sap/ui/mdc/field/ListFieldHelpItem.js +2 -2
- package/src/sap/ui/mdc/field/MultiValueFieldDelegate.js +1 -1
- package/src/sap/ui/mdc/field/MultiValueFieldItem.js +2 -2
- package/src/sap/ui/mdc/field/OutParameter.js +3 -2
- package/src/sap/ui/mdc/field/TokenDisplay.js +2 -2
- package/src/sap/ui/mdc/field/TokenDisplayRenderer.js +1 -1
- package/src/sap/ui/mdc/field/TokenizerDisplay.js +2 -2
- package/src/sap/ui/mdc/field/TokenizerDisplayRenderer.js +1 -1
- package/src/sap/ui/mdc/field/ValueHelpPanel.js +3 -2
- package/src/sap/ui/mdc/field/content/BooleanContent.js +1 -1
- package/src/sap/ui/mdc/field/content/ContentFactory.js +12 -13
- package/src/sap/ui/mdc/field/content/DateContent.js +4 -4
- package/src/sap/ui/mdc/field/content/DateTimeContent.js +1 -1
- package/src/sap/ui/mdc/field/content/DefaultContent.js +15 -5
- package/src/sap/ui/mdc/field/content/LinkContent.js +1 -2
- package/src/sap/ui/mdc/field/content/SearchContent.js +47 -5
- package/src/sap/ui/mdc/field/content/TimeContent.js +1 -1
- package/src/sap/ui/mdc/field/content/UnitContent.js +8 -19
- package/src/sap/ui/mdc/filterbar/FilterBarBase.js +60 -29
- package/src/sap/ui/mdc/filterbar/FilterBarBaseRenderer.js +1 -1
- package/src/sap/ui/mdc/filterbar/IFilterContainer.js +1 -1
- package/src/sap/ui/mdc/filterbar/PropertyHelper.js +2 -2
- package/src/sap/ui/mdc/filterbar/aligned/FilterContainer.js +1 -1
- package/src/sap/ui/mdc/filterbar/aligned/FilterItemLayout.js +1 -1
- package/src/sap/ui/mdc/filterbar/p13n/AdaptationFilterBar.js +27 -4
- package/src/sap/ui/mdc/filterbar/p13n/FilterColumnLayout.js +1 -1
- package/src/sap/ui/mdc/filterbar/p13n/FilterGroupLayout.js +5 -1
- package/src/sap/ui/mdc/filterbar/p13n/GroupContainer.js +6 -2
- package/src/sap/ui/mdc/filterbar/p13n/TableContainer.js +5 -1
- package/src/sap/ui/mdc/filterbar/vh/CollectiveSearchSelect.js +16 -3
- package/src/sap/ui/mdc/filterbar/vh/FilterBar.js +35 -2
- package/src/sap/ui/mdc/filterbar/vh/FilterBarDelegate.js +24 -0
- package/src/sap/ui/mdc/filterbar/vh/FilterContainer.js +2 -2
- package/src/sap/ui/mdc/flexibility/ActionToolbar.flexibility.js +1 -1
- package/src/sap/ui/mdc/flexibility/ActionToolbarAction.flexibility.js +1 -1
- package/src/sap/ui/mdc/flexibility/AggregateFlex.js +2 -2
- package/src/sap/ui/mdc/flexibility/Chart.flexibility.js +2 -2
- package/src/sap/ui/mdc/flexibility/ChartItemFlex.js +1 -1
- package/src/sap/ui/mdc/flexibility/ChartTypeFlex.js +1 -1
- package/src/sap/ui/mdc/flexibility/ColumnFlex.js +2 -2
- package/src/sap/ui/mdc/flexibility/ConditionFlex.js +1 -1
- package/src/sap/ui/mdc/flexibility/FilterBar.flexibility.js +2 -2
- package/src/sap/ui/mdc/flexibility/FilterItemFlex.js +2 -2
- package/src/sap/ui/mdc/flexibility/GroupFlex.js +2 -2
- package/src/sap/ui/mdc/flexibility/ItemBaseFlex.js +2 -2
- package/src/sap/ui/mdc/flexibility/Panel.flexibility.js +1 -1
- package/src/sap/ui/mdc/flexibility/PanelItem.flexibility.js +1 -1
- package/src/sap/ui/mdc/flexibility/PropertyInfoFlex.js +1 -1
- package/src/sap/ui/mdc/flexibility/SortFlex.js +3 -3
- package/src/sap/ui/mdc/flexibility/Table.flexibility.js +1 -1
- package/src/sap/ui/mdc/flexibility/Util.js +2 -2
- package/src/sap/ui/mdc/flexibility/xConfigFlex.js +6 -6
- package/src/sap/ui/mdc/flp/FlpLinkDelegate.js +1 -1
- package/src/sap/ui/mdc/library.js +61 -30
- package/src/sap/ui/mdc/link/ContactDetails.js +2 -2
- package/src/sap/ui/mdc/link/ContactDetailsAddressItem.js +2 -2
- package/src/sap/ui/mdc/link/ContactDetailsEmailItem.js +2 -2
- package/src/sap/ui/mdc/link/ContactDetailsItem.js +2 -2
- package/src/sap/ui/mdc/link/ContactDetailsPhoneItem.js +2 -2
- package/src/sap/ui/mdc/link/ContactDetailsRenderer.js +1 -1
- package/src/sap/ui/mdc/link/Factory.js +2 -2
- package/src/sap/ui/mdc/link/FakeFlpConnector.js +2 -2
- package/src/sap/ui/mdc/link/LinkItem.js +3 -2
- package/src/sap/ui/mdc/link/Log.js +1 -1
- package/src/sap/ui/mdc/link/Panel.js +25 -13
- package/src/sap/ui/mdc/link/PanelItem.js +2 -2
- package/src/sap/ui/mdc/link/PanelRenderer.js +1 -1
- package/src/sap/ui/mdc/link/SemanticObjectMapping.js +2 -2
- package/src/sap/ui/mdc/link/SemanticObjectMappingItem.js +2 -2
- package/src/sap/ui/mdc/link/SemanticObjectUnavailableAction.js +2 -2
- package/src/sap/ui/mdc/messagebundle.properties +7 -3
- package/src/sap/ui/mdc/messagebundle_ar.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_bg.properties +33 -30
- package/src/sap/ui/mdc/messagebundle_ca.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_cs.properties +7 -4
- package/src/sap/ui/mdc/messagebundle_cy.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_da.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_de.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_el.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_en.properties +5 -3
- package/src/sap/ui/mdc/messagebundle_en_GB.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_en_US_sappsd.properties +4 -1
- package/src/sap/ui/mdc/messagebundle_en_US_saprigi.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_en_US_saptrc.properties +0 -1
- package/src/sap/ui/mdc/messagebundle_es.properties +9 -6
- package/src/sap/ui/mdc/messagebundle_es_MX.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_et.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_fi.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_fr.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_fr_CA.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_hi.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_hr.properties +11 -8
- package/src/sap/ui/mdc/messagebundle_hu.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_id.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_it.properties +6 -3
- package/src/sap/ui/mdc/messagebundle_iw.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_ja.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_kk.properties +11 -8
- package/src/sap/ui/mdc/messagebundle_ko.properties +4 -1
- package/src/sap/ui/mdc/messagebundle_lt.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_lv.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_ms.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_nl.properties +7 -4
- package/src/sap/ui/mdc/messagebundle_no.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_pl.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_pt.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_pt_PT.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_ro.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_ru.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_sh.properties +6 -3
- package/src/sap/ui/mdc/messagebundle_sk.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_sl.properties +10 -7
- package/src/sap/ui/mdc/messagebundle_sv.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_th.properties +7 -4
- package/src/sap/ui/mdc/messagebundle_tr.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_uk.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_vi.properties +5 -2
- package/src/sap/ui/mdc/messagebundle_zh_CN.properties +6 -3
- package/src/sap/ui/mdc/messagebundle_zh_TW.properties +5 -2
- package/src/sap/ui/mdc/mixin/AdaptationMixin.js +10 -5
- package/src/sap/ui/mdc/mixin/DelegateMixin.js +4 -4
- package/src/sap/ui/mdc/mixin/FilterIntegrationMixin.js +3 -3
- package/src/sap/ui/mdc/mixin/PromiseMixin.js +10 -10
- package/src/sap/ui/mdc/mixin/PropertyHelperMixin.js +7 -3
- package/src/sap/ui/mdc/odata/TypeUtil.js +4 -4
- package/src/sap/ui/mdc/odata/v4/ChartDelegate.js +1 -1
- package/src/sap/ui/mdc/odata/v4/FieldBaseDelegate.js +1 -7
- package/src/sap/ui/mdc/odata/v4/FieldValueHelpDelegate.js +1 -1
- package/src/sap/ui/mdc/odata/v4/ODataMetaModelUtil.js +2 -2
- package/src/sap/ui/mdc/odata/v4/TableDelegate.js +3 -3
- package/src/sap/ui/mdc/odata/v4/TypeUtil.js +9 -1
- package/src/sap/ui/mdc/odata/v4/ValueHelpDelegate.js +34 -65
- package/src/sap/ui/mdc/odata/v4/util/DelegateUtil.js +1 -1
- package/src/sap/ui/mdc/odata/v4/vizChart/ChartDelegate.js +53 -53
- package/src/sap/ui/mdc/p13n/Engine.js +4 -4
- package/src/sap/ui/mdc/p13n/FlexUtil.js +1 -1
- package/src/sap/ui/mdc/p13n/P13nBuilder.js +1 -1
- package/src/sap/ui/mdc/p13n/PersistenceProvider.js +4 -154
- package/src/sap/ui/mdc/p13n/PropertyHelper.js +2 -2
- package/src/sap/ui/mdc/p13n/StateUtil.js +16 -2
- package/src/sap/ui/mdc/p13n/UIManager.js +3 -4
- package/src/sap/ui/mdc/p13n/panels/ActionToolbarPanel.js +1 -1
- package/src/sap/ui/mdc/p13n/panels/AdaptFiltersPanel.js +3 -2
- package/src/sap/ui/mdc/p13n/panels/ChartItemPanel.js +4 -2
- package/src/sap/ui/mdc/p13n/panels/FilterPanel.js +23 -12
- package/src/sap/ui/mdc/p13n/panels/GroupView.js +15 -7
- package/src/sap/ui/mdc/p13n/panels/LinkSelectionPanel.js +3 -2
- package/src/sap/ui/mdc/p13n/subcontroller/ActionToolbarController.js +7 -11
- package/src/sap/ui/mdc/p13n/subcontroller/AdaptFiltersController.js +21 -9
- package/src/sap/ui/mdc/p13n/subcontroller/AggregateController.js +13 -8
- package/src/sap/ui/mdc/p13n/subcontroller/BaseController.js +2 -2
- package/src/sap/ui/mdc/p13n/subcontroller/ChartItemController.js +12 -28
- package/src/sap/ui/mdc/p13n/subcontroller/ChartTypeController.js +8 -4
- package/src/sap/ui/mdc/p13n/subcontroller/ColumnController.js +7 -15
- package/src/sap/ui/mdc/p13n/subcontroller/ColumnWidthController.js +7 -7
- package/src/sap/ui/mdc/p13n/subcontroller/FilterController.js +18 -9
- package/src/sap/ui/mdc/p13n/subcontroller/GroupController.js +5 -5
- package/src/sap/ui/mdc/p13n/subcontroller/LinkPanelController.js +6 -5
- package/src/sap/ui/mdc/p13n/subcontroller/SelectionController.js +76 -0
- package/src/sap/ui/mdc/p13n/subcontroller/SortController.js +5 -5
- package/src/sap/ui/mdc/table/Column.js +101 -22
- package/src/sap/ui/mdc/table/ColumnSettings.js +41 -0
- package/src/sap/ui/mdc/table/CreationRow.js +11 -12
- package/src/sap/ui/mdc/table/GridTableType.js +331 -107
- package/src/sap/ui/mdc/table/PropertyHelper.js +14 -8
- package/src/sap/ui/mdc/table/ResponsiveColumnSettings.js +76 -0
- package/src/sap/ui/mdc/table/ResponsiveTableType.js +312 -97
- package/src/sap/ui/mdc/table/RowActionItem.js +9 -3
- package/src/sap/ui/mdc/table/RowSettings.js +3 -3
- package/src/sap/ui/mdc/table/TableSettings.js +12 -13
- package/src/sap/ui/mdc/table/TableTypeBase.js +124 -41
- package/src/sap/ui/mdc/table/TreeTableType.js +106 -0
- package/src/sap/ui/mdc/table/V4AnalyticsPropertyHelper.js +3 -3
- package/src/sap/ui/mdc/table/menu/Item.js +4 -7
- package/src/sap/ui/mdc/table/menu/ItemContainer.js +1 -1
- package/src/sap/ui/mdc/table/menu/QuickActionContainer.js +3 -4
- package/src/sap/ui/mdc/themes/base/AdaptFiltersPanel.less +1 -5
- package/src/sap/ui/mdc/themes/base/Chart.less +1 -0
- package/src/sap/ui/mdc/themes/base/FieldBase.less +8 -2
- package/src/sap/ui/mdc/themes/base/PersonalizationDialog.less +7 -7
- package/src/sap/ui/mdc/themes/base/library.source.less +1 -1
- package/src/sap/ui/mdc/util/Common.js +1 -1
- package/src/sap/ui/mdc/util/DateUtil.js +3 -2
- package/src/sap/ui/mdc/util/FilterUtil.js +1 -1
- package/src/sap/ui/mdc/util/FormatUtil.js +1 -1
- package/src/sap/ui/mdc/util/IdentifierUtil.js +1 -1
- package/src/sap/ui/mdc/util/PromiseCache.js +10 -10
- package/src/sap/ui/mdc/util/PropertyHelper.js +3 -3
- package/src/sap/ui/mdc/util/TypeUtil.js +33 -2
- package/src/sap/ui/mdc/util/loadModules.js +1 -1
- package/src/sap/ui/mdc/valuehelp/Dialog.js +39 -9
- package/src/sap/ui/mdc/valuehelp/Popover.js +30 -5
- package/src/sap/ui/mdc/valuehelp/base/Container.js +8 -6
- package/src/sap/ui/mdc/valuehelp/base/Content.js +28 -5
- package/src/sap/ui/mdc/valuehelp/base/DialogTab.js +2 -2
- package/src/sap/ui/mdc/valuehelp/base/FilterableListContent.js +33 -32
- package/src/sap/ui/mdc/valuehelp/base/ListContent.js +5 -4
- package/src/sap/ui/mdc/valuehelp/content/Bool.js +8 -2
- package/src/sap/ui/mdc/valuehelp/content/Conditions.js +7 -3
- package/src/sap/ui/mdc/valuehelp/content/FixedList.js +11 -4
- package/src/sap/ui/mdc/valuehelp/content/MDCTable.js +16 -14
- package/src/sap/ui/mdc/valuehelp/content/MTable.js +56 -73
- package/test/sap/ui/mdc/testutils/opa/field/Actions.js +4 -2
- package/test/sap/ui/mdc/testutils/opa/filterbar/Actions.js +1 -1
- package/test/sap/ui/mdc/testutils/opa/filterfield/Actions.js +8 -0
- package/test/sap/ui/mdc/testutils/opa/p13n/Actions.js +16 -25
- package/test/sap/ui/mdc/testutils/opa/p13n/Assertions.js +2 -1
- package/test/sap/ui/mdc/testutils/opa/p13n/waitForPanelInP13n.js +1 -1
- package/test/sap/ui/mdc/testutils/opa/table/Actions.js +291 -67
- package/test/sap/ui/mdc/testutils/opa/table/Assertions.js +4 -81
- package/test/sap/ui/mdc/testutils/opa/table/JSDoc.md +0 -50
- package/test/sap/ui/mdc/testutils/opa/table/TestObjects.js +7 -51
- package/test/sap/ui/mdc/testutils/opa/table/Util.js +0 -1
- package/test/sap/ui/mdc/testutils/opa/table/waitForTable.js +30 -5
- package/src/sap/ui/mdc/p13n/AdaptationProvider.js +0 -67
- package/src/sap/ui/mdc/p13n/modification/FlexModificationHandler.js +0 -76
- package/src/sap/ui/mdc/p13n/modification/ModificationHandler.js +0 -87
- package/src/sap/ui/mdc/p13n/modules/DefaultProviderRegistry.js +0 -149
- package/src/sap/ui/mdc/p13n/modules/StateHandlerRegistry.js +0 -86
- package/src/sap/ui/mdc/p13n/modules/xConfigAPI.js +0 -219
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* OpenUI5
|
|
3
|
-
* (c) Copyright 2009-
|
|
3
|
+
* (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
|
|
4
4
|
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
|
|
5
5
|
*/
|
|
6
6
|
sap.ui.define([
|
|
@@ -11,6 +11,7 @@ sap.ui.define([
|
|
|
11
11
|
'sap/ui/mdc/field/FieldBaseRenderer',
|
|
12
12
|
'sap/ui/mdc/condition/FilterOperatorUtil',
|
|
13
13
|
'sap/ui/mdc/condition/Condition',
|
|
14
|
+
'sap/ui/mdc/condition/ConditionValidateException',
|
|
14
15
|
'sap/ui/mdc/field/ConditionType',
|
|
15
16
|
'sap/ui/mdc/field/ConditionsType',
|
|
16
17
|
'sap/ui/mdc/enum/BaseType',
|
|
@@ -41,6 +42,7 @@ sap.ui.define([
|
|
|
41
42
|
FieldBaseRenderer,
|
|
42
43
|
FilterOperatorUtil,
|
|
43
44
|
Condition,
|
|
45
|
+
ConditionValidateException,
|
|
44
46
|
ConditionType,
|
|
45
47
|
ConditionsType,
|
|
46
48
|
BaseType,
|
|
@@ -84,7 +86,7 @@ sap.ui.define([
|
|
|
84
86
|
* @implements sap.ui.core.IFormContent, sap.ui.core.ISemanticFormContent
|
|
85
87
|
*
|
|
86
88
|
* @author SAP SE
|
|
87
|
-
* @version 1.
|
|
89
|
+
* @version 1.110.0
|
|
88
90
|
*
|
|
89
91
|
* @constructor
|
|
90
92
|
* @alias sap.ui.mdc.field.FieldBase
|
|
@@ -97,7 +99,7 @@ sap.ui.define([
|
|
|
97
99
|
*/
|
|
98
100
|
var FieldBase = Control.extend("sap.ui.mdc.field.FieldBase", /* @lends sap.ui.mdc.field.FieldBase.prototype */ {
|
|
99
101
|
metadata: {
|
|
100
|
-
interfaces: ["sap.ui.core.IFormContent", "sap.ui.core.ISemanticFormContent"],
|
|
102
|
+
interfaces: ["sap.ui.core.IFormContent", "sap.ui.core.ISemanticFormContent", "sap.m.IOverflowToolbarContent"],
|
|
101
103
|
designtime: "sap/ui/mdc/designtime/field/FieldBase.designtime",
|
|
102
104
|
library: "sap.ui.mdc",
|
|
103
105
|
properties: {
|
|
@@ -988,22 +990,25 @@ sap.ui.define([
|
|
|
988
990
|
// do not destroy if used in Field binding
|
|
989
991
|
this._getContentFactory().getUnitOriginalType().destroy();
|
|
990
992
|
}
|
|
991
|
-
this._getContentFactory().
|
|
993
|
+
this._getContentFactory().setUnitOriginalType(undefined);
|
|
992
994
|
}
|
|
995
|
+
|
|
996
|
+
this._getContentFactory().setIsMeasure(false);
|
|
993
997
|
};
|
|
994
998
|
|
|
995
999
|
function _getDataTypeName() {
|
|
996
|
-
|
|
997
|
-
|
|
1000
|
+
var oDataType = this._getContentFactory().getDateOriginalType() || this._getContentFactory().getUnitOriginalType() || this._getContentFactory().getDataType(); // use original data type
|
|
1001
|
+
if (oDataType && typeof oDataType === "object") {
|
|
1002
|
+
return oDataType.getMetadata().getName();
|
|
998
1003
|
} else if (this.bDelegateInitialized) {
|
|
999
|
-
return this.
|
|
1004
|
+
return this.getTypeUtil().getDataTypeClassName(this.getDataType());
|
|
1000
1005
|
} else {
|
|
1001
1006
|
return this.getDataType();
|
|
1002
1007
|
}
|
|
1003
1008
|
}
|
|
1004
1009
|
|
|
1005
1010
|
function _getDataTypeConstraints() {
|
|
1006
|
-
var oDataType = this._getContentFactory().getDataType();
|
|
1011
|
+
var oDataType = this._getContentFactory().getDateOriginalType() || this._getContentFactory().getUnitOriginalType() || this._getContentFactory().getDataType(); // use original data type
|
|
1007
1012
|
if (oDataType && typeof oDataType === "object" && oDataType.getConstraints()) {
|
|
1008
1013
|
return oDataType.getConstraints();
|
|
1009
1014
|
} else {
|
|
@@ -1012,7 +1017,7 @@ sap.ui.define([
|
|
|
1012
1017
|
}
|
|
1013
1018
|
|
|
1014
1019
|
function _getDataTypeFormatOptions() {
|
|
1015
|
-
var oDataType = this._getContentFactory().getDataType();
|
|
1020
|
+
var oDataType = this._getContentFactory().getDateOriginalType() || this._getContentFactory().getUnitOriginalType() || this._getContentFactory().getDataType(); // use original data type
|
|
1016
1021
|
if (oDataType && typeof oDataType === "object" && oDataType.getFormatOptions()) {
|
|
1017
1022
|
return oDataType.getFormatOptions();
|
|
1018
1023
|
} else {
|
|
@@ -1066,12 +1071,12 @@ sap.ui.define([
|
|
|
1066
1071
|
|
|
1067
1072
|
};
|
|
1068
1073
|
|
|
1069
|
-
function _setUIMessage(sMsg) {
|
|
1074
|
+
// function _setUIMessage(sMsg) {
|
|
1070
1075
|
|
|
1071
|
-
|
|
1072
|
-
|
|
1076
|
+
// this.setValueState(ValueState.Error);
|
|
1077
|
+
// this.setValueStateText(sMsg);
|
|
1073
1078
|
|
|
1074
|
-
}
|
|
1079
|
+
// }
|
|
1075
1080
|
|
|
1076
1081
|
FieldBase.prototype._removeUIMessage = function() {
|
|
1077
1082
|
|
|
@@ -1316,7 +1321,14 @@ sap.ui.define([
|
|
|
1316
1321
|
return this._getContentFactory().getDateOriginalType().formatValue(vValue, "string");
|
|
1317
1322
|
} else {
|
|
1318
1323
|
var oConditionsType = this._getContentFactory().getConditionsType();
|
|
1319
|
-
|
|
1324
|
+
var oFormatOptions = oConditionsType.getFormatOptions();
|
|
1325
|
+
var bNoFormatting = oFormatOptions.noFormatting;
|
|
1326
|
+
oFormatOptions.noFormatting = false; // for display text always format
|
|
1327
|
+
oConditionsType.setFormatOptions(oFormatOptions);
|
|
1328
|
+
var sResult = oConditionsType.formatValue(aConditions);
|
|
1329
|
+
oFormatOptions.noFormatting = bNoFormatting; // turn back
|
|
1330
|
+
oConditionsType.setFormatOptions(oFormatOptions);
|
|
1331
|
+
return sResult;
|
|
1320
1332
|
}
|
|
1321
1333
|
|
|
1322
1334
|
};
|
|
@@ -1330,6 +1342,21 @@ sap.ui.define([
|
|
|
1330
1342
|
|
|
1331
1343
|
};
|
|
1332
1344
|
|
|
1345
|
+
/**
|
|
1346
|
+
* Required by the {@link sap.m.IOverflowToolbarContent} interface.
|
|
1347
|
+
* Registers invalidations event which is fired when width of the control is changed.
|
|
1348
|
+
*
|
|
1349
|
+
* @protected
|
|
1350
|
+
* @returns {object} Configuration information for the <code>sap.m.IOverflowToolbarContent</code> interface.
|
|
1351
|
+
*/
|
|
1352
|
+
FieldBase.prototype.getOverflowToolbarConfig = function() {
|
|
1353
|
+
return {
|
|
1354
|
+
canOverflow: true,
|
|
1355
|
+
invalidationEvents: [],
|
|
1356
|
+
propsUnrelatedToSize: ["conditions", "editMode", "display", "valueState", "valueStateText"] // only add properties that are normally changed during livetime
|
|
1357
|
+
};
|
|
1358
|
+
};
|
|
1359
|
+
|
|
1333
1360
|
/*
|
|
1334
1361
|
* If Field is inside of a Form use Forms aria logic for label
|
|
1335
1362
|
*/
|
|
@@ -1408,13 +1435,15 @@ sap.ui.define([
|
|
|
1408
1435
|
oAttributes.aria["haspopup"] = oAriaAttributes.ariaHasPopup;
|
|
1409
1436
|
oAttributes["autocomplete"] = "off";
|
|
1410
1437
|
if (bOpen) {
|
|
1411
|
-
|
|
1438
|
+
if (oAriaAttributes.role) {
|
|
1439
|
+
oAttributes.aria["expanded"] = "true"; // only allowed for combobox, listbox...
|
|
1440
|
+
}
|
|
1412
1441
|
oAttributes.aria["controls"] = oAriaAttributes.contentId;
|
|
1413
1442
|
if (sItemId) {
|
|
1414
1443
|
oAttributes.aria["activedescendant"] = sItemId;
|
|
1415
1444
|
}
|
|
1416
|
-
} else {
|
|
1417
|
-
oAttributes.aria["expanded"] = "false";
|
|
1445
|
+
} else if (oAriaAttributes.role) {
|
|
1446
|
+
oAttributes.aria["expanded"] = "false"; // only allowed for combobox, listbox...
|
|
1418
1447
|
}
|
|
1419
1448
|
oAttributes["valueHelpEnabled"] = oAriaAttributes.valueHelpEnabled;
|
|
1420
1449
|
}
|
|
@@ -1495,6 +1524,7 @@ sap.ui.define([
|
|
|
1495
1524
|
if (!this._getContentFactory().getContentConditionTypes()[sName]) {
|
|
1496
1525
|
this._getContentFactory().getContentConditionTypes()[sName] = {};
|
|
1497
1526
|
}
|
|
1527
|
+
this._getContentFactory().setNoFormatting(false); // initialize
|
|
1498
1528
|
this.awaitControlDelegate().then(function() {
|
|
1499
1529
|
if (!this.bIsDestroyed) {
|
|
1500
1530
|
this._oContentFactory.setHideOperator(_isOnlyOneSingleValue.call(this, this._getOperators())); // in single value eq Field hide operator
|
|
@@ -1505,13 +1535,14 @@ sap.ui.define([
|
|
|
1505
1535
|
// find out what is bound to conditions
|
|
1506
1536
|
var oBindingInfo;
|
|
1507
1537
|
var sProperty;
|
|
1538
|
+
var bPropertyBound = false;
|
|
1508
1539
|
for (sProperty in oContent.getMetadata().getAllProperties()) {
|
|
1509
1540
|
if (oContent.getBindingPath(sProperty) === "/conditions") {
|
|
1510
1541
|
oBindingInfo = oContent.getBindingInfo(sProperty);
|
|
1511
1542
|
if (oBindingInfo && oBindingInfo.type && oBindingInfo.type instanceof ConditionsType) {
|
|
1512
1543
|
this._getContentFactory().getContentConditionTypes()[sName].oConditionsType = oBindingInfo.type;
|
|
1513
1544
|
}
|
|
1514
|
-
|
|
1545
|
+
bPropertyBound = true;
|
|
1515
1546
|
}
|
|
1516
1547
|
if (sProperty === "editable" && !oContent.getBindingPath(sProperty) && oContent.isPropertyInitial(sProperty)) {
|
|
1517
1548
|
oContent.bindProperty(sProperty, { path: "$field>/editMode", formatter: ContentFactory._getEditable });
|
|
@@ -1556,6 +1587,9 @@ sap.ui.define([
|
|
|
1556
1587
|
var oTemplateBindingInfo = oBindingInfo.template.getBindingInfo(sProperty);
|
|
1557
1588
|
if (oTemplateBindingInfo && oTemplateBindingInfo.type && oTemplateBindingInfo.type instanceof ConditionType) {
|
|
1558
1589
|
this._getContentFactory().getContentConditionTypes()[sName].oConditionType = oTemplateBindingInfo.type;
|
|
1590
|
+
if (bPropertyBound) { // both value and tokens are bound -> don't format Value, only parse it
|
|
1591
|
+
this._getContentFactory().setNoFormatting(true);
|
|
1592
|
+
}
|
|
1559
1593
|
break;
|
|
1560
1594
|
}
|
|
1561
1595
|
}
|
|
@@ -2042,20 +2076,10 @@ sap.ui.define([
|
|
|
2042
2076
|
|
|
2043
2077
|
// try to find the corresponding async. change and reject it
|
|
2044
2078
|
var vValue = oEvent.getParameter("newValue");
|
|
2079
|
+
var oException = oEvent.getParameter("exception");
|
|
2080
|
+
var aWrongConditions = oException && oException instanceof ConditionValidateException && oException.getConditions(); // we store the conditions in the ConditionValidationException
|
|
2045
2081
|
var bFound = false;
|
|
2046
2082
|
var i = 0;
|
|
2047
|
-
var bIsMeasure = this._oContentFactory.isMeasure();
|
|
2048
|
-
var iPart = 0;
|
|
2049
|
-
|
|
2050
|
-
if (bIsMeasure) { // check on what part the error occurs and compare only this value
|
|
2051
|
-
var oControl = oEvent.getParameter("element");
|
|
2052
|
-
var aContent = this._getContent();
|
|
2053
|
-
for (i = 0; i < aContent.length; i++) {
|
|
2054
|
-
if (oControl === aContent[i]) {
|
|
2055
|
-
iPart = i;
|
|
2056
|
-
}
|
|
2057
|
-
}
|
|
2058
|
-
}
|
|
2059
2083
|
|
|
2060
2084
|
for (i = 0; i < this._aAsyncChanges.length; i++) {
|
|
2061
2085
|
var oChange = this._aAsyncChanges[i];
|
|
@@ -2064,23 +2088,10 @@ sap.ui.define([
|
|
|
2064
2088
|
// for empty string no condition is created
|
|
2065
2089
|
oChange.reject(oEvent.getParameter("exception"));
|
|
2066
2090
|
bFound = true;
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
var vCompareBT = oCondition.operator === "BT" && oCondition.values[1];
|
|
2072
|
-
if (bIsMeasure) {
|
|
2073
|
-
vCompare = vCompare[iPart];
|
|
2074
|
-
vCompareBT = oCondition.operator === "BT" && vCompareBT[iPart];
|
|
2075
|
-
}
|
|
2076
|
-
if (deepEqual(vCompare, vValue) || (oCondition.operator === "BT" && deepEqual(vCompareBT, vValue))) {
|
|
2077
|
-
oChange.reject(oEvent.getParameter("exception"));
|
|
2078
|
-
bFound = true;
|
|
2079
|
-
break;
|
|
2080
|
-
}
|
|
2081
|
-
}
|
|
2082
|
-
}
|
|
2083
|
-
if (bFound) {
|
|
2091
|
+
break;
|
|
2092
|
+
} else if (deepEqual(oChange.result, aWrongConditions)) { // compare parsing result with conditions used for validation -> must be the same
|
|
2093
|
+
oChange.reject(oException);
|
|
2094
|
+
bFound = true;
|
|
2084
2095
|
break;
|
|
2085
2096
|
}
|
|
2086
2097
|
}
|
|
@@ -2120,113 +2131,19 @@ sap.ui.define([
|
|
|
2120
2131
|
function _performContentChange(oChange) {
|
|
2121
2132
|
|
|
2122
2133
|
var aConditions = this.getConditions();
|
|
2123
|
-
var vValue;
|
|
2124
2134
|
var bValid = true;
|
|
2125
2135
|
var vWrongValue;
|
|
2126
|
-
var oCondition;
|
|
2127
2136
|
var oSource = oChange.changeEvent.source;
|
|
2128
|
-
var bAsync = false;
|
|
2129
|
-
var bChanged = true; // normally only called on real change. But in SearchField called on every ENTER
|
|
2130
|
-
var bChangeIfNotChanged = false; // in SearchField case fire change even if value not changed. TODO: other event for this
|
|
2131
2137
|
|
|
2132
2138
|
if (oChange.changeEvent.parameters.hasOwnProperty("valid")) {
|
|
2133
2139
|
bValid = oChange.changeEvent.parameters["valid"];
|
|
2134
|
-
|
|
2135
|
-
vWrongValue = oChange.changeEvent.parameters["value"];
|
|
2136
|
-
}
|
|
2137
|
-
}
|
|
2138
|
-
|
|
2139
|
-
// use parsed value of the condition, if possible
|
|
2140
|
-
var bUpdateConditions = false;
|
|
2141
|
-
var sBoundProperty = this._getContentFactory().getBoundProperty();
|
|
2142
|
-
var oBinding = sBoundProperty && oSource.getBinding(sBoundProperty);
|
|
2143
|
-
if (oBinding && oBinding.getBindingMode() !== BindingMode.OneWay && oBinding.getPath() === "/conditions" && bValid) {
|
|
2144
|
-
oCondition = aConditions[0];
|
|
2145
|
-
vValue = aConditions[0] && aConditions[0].values[0];
|
|
2146
|
-
} else if (oChange.changeEvent.parameters.hasOwnProperty("value")) {
|
|
2147
|
-
vValue = oChange.changeEvent.parameters["value"];
|
|
2148
|
-
if (bValid) {
|
|
2149
|
-
bUpdateConditions = true;
|
|
2150
|
-
}
|
|
2151
|
-
} else {
|
|
2152
|
-
oCondition = aConditions[0];
|
|
2153
|
-
vValue = aConditions[0] && aConditions[0].values[0];
|
|
2154
|
-
}
|
|
2155
|
-
|
|
2156
|
-
if (bUpdateConditions) {
|
|
2157
|
-
// text typed in MultiInput
|
|
2158
|
-
this._removeUIMessage();
|
|
2159
|
-
var oConditionType;
|
|
2160
|
-
var oMyChange;
|
|
2161
|
-
|
|
2162
|
-
if (this._bIgnoreInputValue) {
|
|
2163
|
-
// remove filter value from input and don't use it as input
|
|
2164
|
-
this._bIgnoreInputValue = false;
|
|
2165
|
-
oSource.setDOMValue("");
|
|
2166
|
-
if (oSource.getMetadata().hasProperty("value")) {
|
|
2167
|
-
// clear "value" property of MultiInput as there might be an old value from a invalid input before
|
|
2168
|
-
oSource.setValue();
|
|
2169
|
-
}
|
|
2170
|
-
return;
|
|
2171
|
-
}
|
|
2172
|
-
|
|
2173
|
-
oCondition = SyncPromise.resolve().then(function() {
|
|
2174
|
-
var iMaxConditions = this.getMaxConditions();
|
|
2175
|
-
|
|
2176
|
-
if (this._oNavigateCondition) {
|
|
2177
|
-
// text entered via navigation -> use this data, no parsing is needed
|
|
2178
|
-
bValid = true;
|
|
2179
|
-
return this._oNavigateCondition;
|
|
2180
|
-
} else if (vValue === "" && iMaxConditions !== 1) {
|
|
2181
|
-
// in multivalue case an empty input don't changes the conditions and must not be validated with the data type
|
|
2182
|
-
// this happens after an invalid input was just cleared
|
|
2183
|
-
return null;
|
|
2184
|
-
} else {
|
|
2185
|
-
oConditionType = this._getContentFactory().getConditionType();
|
|
2186
|
-
var vResult = oConditionType.parseValue(vValue);
|
|
2187
|
-
var iLength = this._aAsyncChanges.length;
|
|
2188
|
-
|
|
2189
|
-
if (iLength > 0 && !this._aAsyncChanges[iLength - 1].changeFired) {
|
|
2190
|
-
oMyChange = this._aAsyncChanges[iLength - 1];
|
|
2191
|
-
oMyChange.changeFired = true;
|
|
2192
|
-
oMyChange.changeEvent = oChange.changeEvent;
|
|
2193
|
-
_triggerChange.call(this, undefined, undefined, undefined, oMyChange.promise);
|
|
2194
|
-
}
|
|
2195
|
-
return vResult;
|
|
2196
|
-
}
|
|
2197
|
-
}.bind(this)).then(function(oCondition) {
|
|
2198
|
-
bChanged = _updateConditionsFromChange.call(this, oCondition, aConditions, oConditionType, bValid, vValue, oSource, oMyChange || oChange);
|
|
2199
|
-
bChanged = bChanged || bChangeIfNotChanged; // in SearchField fire change if value not changed
|
|
2200
|
-
return oCondition;
|
|
2201
|
-
}.bind(this)).catch(function(oException) {
|
|
2202
|
-
if (oException && !(oException instanceof ParseException) && !(oException instanceof FormatException) && !(oException instanceof ValidateException)) {// FormatException could also occur
|
|
2203
|
-
// unknown error -> just raise it
|
|
2204
|
-
throw oException;
|
|
2205
|
-
}
|
|
2206
|
-
bValid = false;
|
|
2207
|
-
vWrongValue = vValue;
|
|
2208
|
-
this._bParseError = true;
|
|
2209
|
-
this._sFilterValue = "";
|
|
2210
|
-
_setUIMessage.call(this, oException.message);
|
|
2211
|
-
|
|
2212
|
-
if (oMyChange && oMyChange.reject) {
|
|
2213
|
-
if (_removeAsyncChange.call(this, oMyChange)) { // only if still valid (might be alredy rejected)
|
|
2214
|
-
oMyChange.reject(oException);
|
|
2215
|
-
}
|
|
2216
|
-
} else if (bAsync) {
|
|
2217
|
-
_triggerChange.call(this, aConditions, bValid, vWrongValue);
|
|
2218
|
-
}
|
|
2219
|
-
}.bind(this)).unwrap();
|
|
2220
|
-
|
|
2221
|
-
if (oCondition instanceof Promise) {
|
|
2222
|
-
// will be parsed async
|
|
2223
|
-
bAsync = true;
|
|
2224
|
-
}
|
|
2225
|
-
} else if (!oChange.changeEvent.parameters.hasOwnProperty("valid") && this._bParseError) {
|
|
2140
|
+
} else if (this._bParseError) {
|
|
2226
2141
|
// this might be result of a value that cannot be parsed
|
|
2227
|
-
vWrongValue = oChange.changeEvent.parameters["value"];
|
|
2228
2142
|
bValid = false;
|
|
2229
2143
|
}
|
|
2144
|
+
if (!bValid && oChange.changeEvent.parameters.hasOwnProperty("value")) {
|
|
2145
|
+
vWrongValue = oChange.changeEvent.parameters["value"];
|
|
2146
|
+
}
|
|
2230
2147
|
|
|
2231
2148
|
var oFieldHelp = _getFieldHelp.call(this);
|
|
2232
2149
|
if (oFieldHelp && this._bConnected) {
|
|
@@ -2234,7 +2151,7 @@ sap.ui.define([
|
|
|
2234
2151
|
oFieldHelp.close(); // if focus is not in field, Field help closes automatically
|
|
2235
2152
|
}
|
|
2236
2153
|
this._sFilterValue = "";
|
|
2237
|
-
if (
|
|
2154
|
+
if (bValid) {
|
|
2238
2155
|
_setConditionsOnFieldHelp.call(this, aConditions, oFieldHelp);
|
|
2239
2156
|
oFieldHelp.onControlChange();
|
|
2240
2157
|
}
|
|
@@ -2250,75 +2167,12 @@ sap.ui.define([
|
|
|
2250
2167
|
if (oChange.resolve) {
|
|
2251
2168
|
// async promise needs to be resolved
|
|
2252
2169
|
_resolveAsyncChange.call(this, oChange);
|
|
2253
|
-
} else
|
|
2170
|
+
} else {
|
|
2254
2171
|
_triggerChange.call(this, aConditions, bValid, vWrongValue);
|
|
2255
2172
|
}
|
|
2256
2173
|
|
|
2257
2174
|
}
|
|
2258
2175
|
|
|
2259
|
-
// Please note: This method may update aConditions!
|
|
2260
|
-
function _updateConditionsFromChange(oCondition, aConditions, oConditionType, bValid, vValue, oSource, oChange) {
|
|
2261
|
-
|
|
2262
|
-
var iMaxConditions = this.getMaxConditions();
|
|
2263
|
-
var bChanged = false;
|
|
2264
|
-
|
|
2265
|
-
if (oCondition === null && iMaxConditions !== 1) {
|
|
2266
|
-
// in multi value case no new condition means no condition-change
|
|
2267
|
-
// but fire change event as before a change event with invalid value was fired
|
|
2268
|
-
return true;
|
|
2269
|
-
}
|
|
2270
|
-
|
|
2271
|
-
if (oConditionType) {
|
|
2272
|
-
// in navigation no validation needed
|
|
2273
|
-
oConditionType.validateValue(oCondition);
|
|
2274
|
-
}
|
|
2275
|
-
|
|
2276
|
-
if (bValid) {
|
|
2277
|
-
if (oCondition) {
|
|
2278
|
-
if (this._getContentFactory().isMeasure() && aConditions.length === 1 && aConditions[0].values[0][0] === undefined) {
|
|
2279
|
-
// remove empty condition
|
|
2280
|
-
aConditions.length = 0;
|
|
2281
|
-
}
|
|
2282
|
-
if (iMaxConditions !== 1 && FilterOperatorUtil.indexOfCondition(oCondition, aConditions) >= 0) {
|
|
2283
|
-
// condition already exist (only error if tokens, in SearchField it is OK)
|
|
2284
|
-
throw new ParseException(this._oResourceBundle.getText("field.CONDITION_ALREADY_EXIST", [vValue]));
|
|
2285
|
-
} else {
|
|
2286
|
-
if (iMaxConditions > 0 && iMaxConditions <= aConditions.length) {
|
|
2287
|
-
// remove first conditions to meet maxConditions
|
|
2288
|
-
aConditions.splice(0, aConditions.length - iMaxConditions + 1);
|
|
2289
|
-
}
|
|
2290
|
-
aConditions.push(oCondition);
|
|
2291
|
-
}
|
|
2292
|
-
} else if (iMaxConditions === 1) {
|
|
2293
|
-
aConditions.length = 0;
|
|
2294
|
-
}
|
|
2295
|
-
|
|
2296
|
-
if (!deepEqual(aConditions, this.getConditions())) {
|
|
2297
|
-
this.setProperty("conditions", aConditions, true); // do not invalidate whole field
|
|
2298
|
-
bChanged = true;
|
|
2299
|
-
}
|
|
2300
|
-
|
|
2301
|
-
if (iMaxConditions !== 1) {
|
|
2302
|
-
oSource.setValue(""); // remove typed value of MultiInput
|
|
2303
|
-
}
|
|
2304
|
-
|
|
2305
|
-
}
|
|
2306
|
-
|
|
2307
|
-
if (oChange.resolve) {
|
|
2308
|
-
var oFieldHelp = _getFieldHelp.call(this);
|
|
2309
|
-
if (oFieldHelp && this._bConnected) {
|
|
2310
|
-
_setConditionsOnFieldHelp.call(this, aConditions, oFieldHelp);
|
|
2311
|
-
oFieldHelp.onControlChange();
|
|
2312
|
-
}
|
|
2313
|
-
oChange.result = aConditions;
|
|
2314
|
-
_resolveAsyncChange.call(this, oChange);
|
|
2315
|
-
_removeAsyncChange.call(this, oChange);
|
|
2316
|
-
}
|
|
2317
|
-
|
|
2318
|
-
return bChanged;
|
|
2319
|
-
|
|
2320
|
-
}
|
|
2321
|
-
|
|
2322
2176
|
function _handleContentLiveChange(oEvent) {
|
|
2323
2177
|
|
|
2324
2178
|
var vValue;
|
|
@@ -2400,21 +2254,44 @@ sap.ui.define([
|
|
|
2400
2254
|
}
|
|
2401
2255
|
}
|
|
2402
2256
|
|
|
2403
|
-
var
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2257
|
+
var _handleTypeahead = function () {
|
|
2258
|
+
var oFocusedElement = document.activeElement;
|
|
2259
|
+
if (oFocusedElement && (containsOrEquals(this.getDomRef(), oFocusedElement))) { // only if still connected and focussed
|
|
2260
|
+
var bIsNew = oFieldHelp.isA("sap.ui.mdc.ValueHelp");
|
|
2261
|
+
var bIsFHOpen = oFieldHelp.isOpen();
|
|
2262
|
+
if (!bIsNew && !this._sFilterValue && bIsFHOpen) {
|
|
2263
|
+
oFieldHelp.close(); // close if no filter
|
|
2264
|
+
} else if (bIsNew || this._sFilterValue) {
|
|
2265
|
+
oFieldHelp.setFilterValue(this._sFilterValue);
|
|
2266
|
+
if (this.getMaxConditionsForHelp() === 1 && oFieldHelp.getConditions().length > 0) {
|
|
2267
|
+
// While single-suggestion no item is selected
|
|
2268
|
+
oFieldHelp.setConditions([]);
|
|
2269
|
+
}
|
|
2270
|
+
if (!bIsFHOpen) {
|
|
2271
|
+
/*
|
|
2272
|
+
sap.ui.mdc.ValueHelp can only be "asked" to open a typeahead by a connected control.
|
|
2273
|
+
It will then decide on actual opening after content initialization via ValueHelpDelegate.showTypeahead which can be customized by applications.
|
|
2274
|
+
An already open typeahead content will consult showTypeahead again on any every filtervalue update and eventually close.
|
|
2275
|
+
*/
|
|
2276
|
+
oFieldHelp.open(true);
|
|
2277
|
+
}
|
|
2278
|
+
}
|
|
2279
|
+
_setAriaAttributes.call(this, true);
|
|
2280
|
+
delete this._vLiveChangeValue;
|
|
2281
|
+
}
|
|
2282
|
+
}.bind(this);
|
|
2283
|
+
|
|
2284
|
+
if (this._bConnected && this._getContent()[0]) {
|
|
2285
|
+
if (oFieldHelp.isA("sap.ui.mdc.ValueHelp")) {
|
|
2286
|
+
oFieldHelp.isTypeaheadSupported().then(function (bTypeahead) {
|
|
2287
|
+
return !!bTypeahead && _handleTypeahead();
|
|
2288
|
+
});
|
|
2289
|
+
} else {
|
|
2290
|
+
var vOpenByTyping = this.hasOwnProperty("_bOpenByTyping") ? this._bOpenByTyping : oFieldHelp.isTypeaheadSupported();
|
|
2291
|
+
if (vOpenByTyping) {
|
|
2292
|
+
_handleTypeahead();
|
|
2414
2293
|
}
|
|
2415
|
-
oFieldHelp.open(true);
|
|
2416
2294
|
}
|
|
2417
|
-
_setAriaAttributes.call(this, true);
|
|
2418
2295
|
delete this._vLiveChangeValue;
|
|
2419
2296
|
}
|
|
2420
2297
|
}.bind(this), 300, { leading: false, trailing: true });
|
|
@@ -2599,7 +2476,6 @@ sap.ui.define([
|
|
|
2599
2476
|
var aConditions = this.getConditions();
|
|
2600
2477
|
_setConditionsOnFieldHelp.call(this, aConditions, oFieldHelp);
|
|
2601
2478
|
oFieldHelp.toggleOpen(false);
|
|
2602
|
-
_setAriaAttributes.call(this, true); // if closed it will be set again on afterclose
|
|
2603
2479
|
if (!oFieldHelp.isFocusInHelp()) {
|
|
2604
2480
|
// need to reset bValueHelpRequested in Input, otherwise on focusout no change event and navigation don't work
|
|
2605
2481
|
var oContent = oEvent.getSource();
|
|
@@ -2722,11 +2598,7 @@ sap.ui.define([
|
|
|
2722
2598
|
}
|
|
2723
2599
|
this._sFilterValue = "";
|
|
2724
2600
|
} else if (bClose) {
|
|
2725
|
-
|
|
2726
|
-
// clear "value" property of MultiInput as there might be an old value from a invalid input before
|
|
2727
|
-
oContent.setValue();
|
|
2728
|
-
}
|
|
2729
|
-
oContent.setDOMValue("");
|
|
2601
|
+
oContent.setDOMValue(""); // as value property of MultiInput control might still be empty during typing. So setValue (via Binding) doesn't updates DOM-value (as no change is recognized).
|
|
2730
2602
|
this._sFilterValue = "";
|
|
2731
2603
|
this._bIgnoreInputValue = false; // just clean up
|
|
2732
2604
|
} else {
|
|
@@ -2825,6 +2697,8 @@ sap.ui.define([
|
|
|
2825
2697
|
sNewValue = vKey;
|
|
2826
2698
|
}
|
|
2827
2699
|
|
|
2700
|
+
var bOpen = oFieldHelp.isOpen();
|
|
2701
|
+
|
|
2828
2702
|
if (oContent && oContent.setDOMValue) {
|
|
2829
2703
|
if (!sDOMValue) {
|
|
2830
2704
|
if (this._getContentFactory().isMeasure() && this._getContentFactory().getUnitConditionsType() && this._oNavigateCondition) {
|
|
@@ -2841,7 +2715,7 @@ sap.ui.define([
|
|
|
2841
2715
|
if (oContent._doSelect) {
|
|
2842
2716
|
oContent._doSelect();
|
|
2843
2717
|
}
|
|
2844
|
-
if (
|
|
2718
|
+
if (bOpen) {
|
|
2845
2719
|
oContent.removeStyleClass("sapMFocus"); // to have focus outline on navigated item only
|
|
2846
2720
|
}
|
|
2847
2721
|
}
|
|
@@ -2849,7 +2723,7 @@ sap.ui.define([
|
|
|
2849
2723
|
this._bPreventGetDescription = false; // back to default
|
|
2850
2724
|
this._getContentFactory().updateConditionType();
|
|
2851
2725
|
|
|
2852
|
-
_setAriaAttributes.call(this,
|
|
2726
|
+
_setAriaAttributes.call(this, bOpen, sItemId);
|
|
2853
2727
|
|
|
2854
2728
|
this._bIgnoreInputValue = false; // use value for input
|
|
2855
2729
|
this.fireLiveChange({ value: sNewValue });
|
|
@@ -2864,9 +2738,10 @@ sap.ui.define([
|
|
|
2864
2738
|
this._bIgnoreInputValue = false;
|
|
2865
2739
|
oContent.setDOMValue("");
|
|
2866
2740
|
this._sFilterValue = "";
|
|
2867
|
-
|
|
2741
|
+
this._getContentFactory().updateConditionType();
|
|
2742
|
+
if (this.getMaxConditions() !== 1) {
|
|
2868
2743
|
// clear "value" property of MultiInput as there might be an old value from a invalid input before
|
|
2869
|
-
|
|
2744
|
+
this._oManagedObjectModel.checkUpdate(true); // forces update of value property via binding to conditions
|
|
2870
2745
|
}
|
|
2871
2746
|
}
|
|
2872
2747
|
|
|
@@ -2879,6 +2754,12 @@ sap.ui.define([
|
|
|
2879
2754
|
|
|
2880
2755
|
}
|
|
2881
2756
|
|
|
2757
|
+
function _handleFieldHelpOpened(oEvent) {
|
|
2758
|
+
|
|
2759
|
+
_setAriaAttributes.call(this, true);
|
|
2760
|
+
|
|
2761
|
+
}
|
|
2762
|
+
|
|
2882
2763
|
function _handleFieldSwitchToValueHelp(oEvent) {
|
|
2883
2764
|
|
|
2884
2765
|
var oContent = this.getControlForSuggestion();
|
|
@@ -2925,7 +2806,12 @@ sap.ui.define([
|
|
|
2925
2806
|
oFieldHelp.detachEvent("afterClose", _handleFieldHelpAfterClose, this); // TODO: remove
|
|
2926
2807
|
oFieldHelp.detachEvent("switchToValueHelp", _handleFieldSwitchToValueHelp, this);
|
|
2927
2808
|
oFieldHelp.detachEvent("closed", _handleFieldHelpAfterClose, this);
|
|
2928
|
-
|
|
2809
|
+
if (oFieldHelp.isA("sap.ui.mdc.ValueHelp")) {
|
|
2810
|
+
oFieldHelp.detachEvent("opened", _handleFieldHelpOpened, this);
|
|
2811
|
+
} else {
|
|
2812
|
+
oFieldHelp.detachEvent("open", _handleFieldHelpOpened, this); // as old FieldHelp has no opened event use open event. But this is also fires async there
|
|
2813
|
+
}
|
|
2814
|
+
this._bConnected = false;
|
|
2929
2815
|
}
|
|
2930
2816
|
|
|
2931
2817
|
}
|
|
@@ -2969,6 +2855,11 @@ sap.ui.define([
|
|
|
2969
2855
|
oFieldHelp.attachEvent("afterClose", _handleFieldHelpAfterClose, this); // TODO: remove
|
|
2970
2856
|
oFieldHelp.attachEvent("switchToValueHelp", _handleFieldSwitchToValueHelp, this);
|
|
2971
2857
|
oFieldHelp.attachEvent("closed", _handleFieldHelpAfterClose, this);
|
|
2858
|
+
if (oFieldHelp.isA("sap.ui.mdc.ValueHelp")) {
|
|
2859
|
+
oFieldHelp.attachEvent("opened", _handleFieldHelpOpened, this);
|
|
2860
|
+
} else {
|
|
2861
|
+
oFieldHelp.attachEvent("open", _handleFieldHelpOpened, this); // as old FieldHelp has no opened event use open event. But this is also fires async there
|
|
2862
|
+
}
|
|
2972
2863
|
var aConditions = this.getConditions();
|
|
2973
2864
|
_setConditionsOnFieldHelp.call(this, aConditions, oFieldHelp);
|
|
2974
2865
|
|
|
@@ -3089,7 +2980,10 @@ sap.ui.define([
|
|
|
3089
2980
|
conditionModelName: oConditionModelInfo.name,
|
|
3090
2981
|
convertWhitespaces: this.getEditMode() === EditMode.Display || this.getMaxConditions() !== 1, // also replace whitespaces in tokens
|
|
3091
2982
|
control: this,
|
|
3092
|
-
defaultOperatorName : this.getDefaultOperator ? this.getDefaultOperator() : null
|
|
2983
|
+
defaultOperatorName : this.getDefaultOperator ? this.getDefaultOperator() : null,
|
|
2984
|
+
getConditions: this.getConditions.bind(this), // to add condition in multi-value case
|
|
2985
|
+
noFormatting: this._getContentFactory().getNoFormatting(),
|
|
2986
|
+
keepValue: this._bIgnoreInputValue ? this._sFilterValue : null
|
|
3093
2987
|
};
|
|
3094
2988
|
|
|
3095
2989
|
};
|
|
@@ -3167,7 +3061,8 @@ sap.ui.define([
|
|
|
3167
3061
|
conditionModelName : oConditionModelInfo.name,
|
|
3168
3062
|
convertWhitespaces: this.getEditMode() === EditMode.Display || this.getEditMode() === EditMode.EditableDisplay,
|
|
3169
3063
|
control: this,
|
|
3170
|
-
getConditions: this.getConditions.bind(this) // TODO: better solution to update unit in all conditions
|
|
3064
|
+
getConditions: this.getConditions.bind(this), // TODO: better solution to update unit in all conditions
|
|
3065
|
+
noFormatting: false
|
|
3171
3066
|
};
|
|
3172
3067
|
|
|
3173
3068
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* OpenUI5
|
|
3
|
-
* (c) Copyright 2009-
|
|
3
|
+
* (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
|
|
4
4
|
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
|
|
5
5
|
*/
|
|
6
6
|
|
|
@@ -258,7 +258,7 @@ sap.ui.define([
|
|
|
258
258
|
* @param {object} oConditionPayload Additional context information for this key
|
|
259
259
|
* @param {sap.ui.core.Control} [oControl] Instance if the calling control
|
|
260
260
|
* @param {sap.ui.model.Type} oType Type of the value
|
|
261
|
-
* @returns {string|
|
|
261
|
+
* @returns {string|sap.ui.mdc.valuehelp.ValueHelpItem|Promise<string|sap.ui.mdc.valuehelp.ValueHelpItem>} Description for key or object containing description, key and payload. If it is not available right away (must be requested), a <code>Promise</code> is returned.
|
|
262
262
|
* @throws {sap.ui.model.FormatException} if the description cannot be determined
|
|
263
263
|
* @since: 1.78.0
|
|
264
264
|
* @private
|
|
@@ -288,39 +288,6 @@ sap.ui.define([
|
|
|
288
288
|
|
|
289
289
|
};
|
|
290
290
|
|
|
291
|
-
/**
|
|
292
|
-
* This function returns which <code>FieldHelpBaseDelegate</code> is used
|
|
293
|
-
* if a default field help (for example, for Boolean values) is created.
|
|
294
|
-
*
|
|
295
|
-
* @param {object} oPayload Payload for delegate
|
|
296
|
-
* @returns {object} Delegate object with <code>name</code and <code>payload</code>
|
|
297
|
-
* @private
|
|
298
|
-
* @ui5-restricted sap.ui.mdc.field.FieldBase
|
|
299
|
-
* @since 1.78.0
|
|
300
|
-
*/
|
|
301
|
-
FieldBaseDelegate.getDefaultFieldHelpBaseDelegate = function(oPayload) {
|
|
302
|
-
|
|
303
|
-
return {name: "sap/ui/mdc/field/FieldHelpBaseDelegate", payload: {}};
|
|
304
|
-
|
|
305
|
-
};
|
|
306
|
-
|
|
307
|
-
/**
|
|
308
|
-
* This function returns which <code>FieldValueHelpDelegate</code> is used
|
|
309
|
-
* if a default field help (for example, for defining conditions in </code>FilterField</code>)
|
|
310
|
-
* is created.
|
|
311
|
-
*
|
|
312
|
-
* @param {object} oPayload Payload for delegate
|
|
313
|
-
* @returns {object} Delegate object with <code>name</code and <code>payload</code>
|
|
314
|
-
* @private
|
|
315
|
-
* @ui5-restricted sap.ui.mdc.field.FieldBase
|
|
316
|
-
* @since 1.78.0
|
|
317
|
-
*/
|
|
318
|
-
FieldBaseDelegate.getDefaultFieldValueHelpDelegate = function(oPayload) {
|
|
319
|
-
|
|
320
|
-
return {name: "sap/ui/mdc/field/FieldValueHelpDelegate", payload: {}};
|
|
321
|
-
|
|
322
|
-
};
|
|
323
|
-
|
|
324
291
|
/**
|
|
325
292
|
* This function returns which <code>ValueHelpDelegate</code> is used
|
|
326
293
|
* if a default field help (for example, for defining conditions in </code>FilterField</code>)
|