@openui5/sap.ui.core 1.105.1 → 1.107.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 +20 -17
- package/THIRDPARTY.txt +31 -21
- package/package.json +1 -1
- package/src/jquery.sap.dom.js +10 -10
- package/src/jquery.sap.global.js +24 -216
- package/src/jquery.sap.history.js +1 -1
- package/src/jquery.sap.properties.js +2 -2
- package/src/jquery.sap.resources.js +1 -1
- package/src/jquery.sap.script.js +1 -1
- package/src/jquery.sap.storage.js +4 -4
- package/src/jquery.sap.ui.js +5 -7
- package/src/sap/base/i18n/ResourceBundle.js +7 -11
- package/src/sap/base/util/LoaderExtensions.js +6 -6
- package/src/sap/base/util/ObjectPath.js +1 -1
- package/src/sap/base/util/Properties.js +1 -1
- package/src/sap/base/util/fetch.js +8 -10
- package/src/sap/base/util/mixedFetch.js +1 -1
- package/src/sap/base/util/restricted/_CancelablePromise.js +1 -1
- package/src/sap/base/util/restricted/_castArray.js +1 -1
- package/src/sap/base/util/restricted/_compact.js +1 -1
- package/src/sap/base/util/restricted/_curry.js +1 -1
- package/src/sap/base/util/restricted/_debounce.js +1 -1
- package/src/sap/base/util/restricted/_difference.js +1 -1
- package/src/sap/base/util/restricted/_differenceBy.js +1 -1
- package/src/sap/base/util/restricted/_differenceWith.js +1 -1
- package/src/sap/base/util/restricted/_flatMap.js +1 -1
- package/src/sap/base/util/restricted/_flatMapDeep.js +1 -1
- package/src/sap/base/util/restricted/_flatMapDepth.js +1 -1
- package/src/sap/base/util/restricted/_flatten.js +1 -1
- package/src/sap/base/util/restricted/_flattenDeep.js +1 -1
- package/src/sap/base/util/restricted/_flattenDepth.js +1 -1
- package/src/sap/base/util/restricted/_intersection.js +1 -1
- package/src/sap/base/util/restricted/_intersectionBy.js +1 -1
- package/src/sap/base/util/restricted/_intersectionWith.js +1 -1
- package/src/sap/base/util/restricted/_isEqual.js +1 -1
- package/src/sap/base/util/restricted/_isEqualWith.js +1 -1
- package/src/sap/base/util/restricted/_isNil.js +1 -1
- package/src/sap/base/util/restricted/_max.js +1 -1
- package/src/sap/base/util/restricted/_merge.js +1 -1
- package/src/sap/base/util/restricted/_mergeWith.js +1 -1
- package/src/sap/base/util/restricted/_min.js +1 -1
- package/src/sap/base/util/restricted/_omit.js +1 -1
- package/src/sap/base/util/restricted/_pick.js +1 -1
- package/src/sap/base/util/restricted/_pickBy.js +1 -1
- package/src/sap/base/util/restricted/_throttle.js +1 -1
- package/src/sap/base/util/restricted/_toArray.js +1 -1
- package/src/sap/base/util/restricted/_union.js +1 -1
- package/src/sap/base/util/restricted/_unionBy.js +1 -1
- package/src/sap/base/util/restricted/_unionWith.js +1 -1
- package/src/sap/base/util/restricted/_uniq.js +1 -1
- package/src/sap/base/util/restricted/_uniqBy.js +1 -1
- package/src/sap/base/util/restricted/_uniqWith.js +1 -1
- package/src/sap/base/util/restricted/_without.js +1 -1
- package/src/sap/base/util/restricted/_xor.js +1 -1
- package/src/sap/base/util/restricted/_xorBy.js +1 -1
- package/src/sap/base/util/restricted/_xorWith.js +1 -1
- package/src/sap/base/util/restricted/_zipObject.js +1 -1
- package/src/sap/base/util/restricted/_zipObjectDeep.js +1 -1
- package/src/sap/base/util/syncFetch.js +9 -16
- package/src/sap/ui/Device.js +3 -3
- package/src/sap/ui/Global.js +7 -14
- package/src/sap/ui/VersionInfo.js +57 -54
- package/src/sap/ui/base/BindingInfo.js +198 -0
- package/src/sap/ui/base/DataType.js +5 -5
- package/src/sap/ui/base/Event.js +2 -2
- package/src/sap/ui/base/EventProvider.js +2 -2
- package/src/sap/ui/base/Interface.js +1 -1
- package/src/sap/ui/base/ManagedObject.js +209 -979
- package/src/sap/ui/base/ManagedObjectMetadata.js +6 -6
- package/src/sap/ui/base/ManagedObjectRegistry.js +4 -3
- package/src/sap/ui/base/Metadata.js +1 -1
- package/src/sap/ui/base/Object.js +1 -1
- package/src/sap/ui/base/ObjectPool.js +1 -1
- package/src/sap/ui/core/.library +13 -9
- package/src/sap/ui/core/AppCacheBuster.js +3 -4
- package/src/sap/ui/core/BusyIndicator.js +1 -1
- package/src/sap/ui/core/BusyIndicatorUtils.js +5 -6
- package/src/sap/ui/core/CalendarType.js +0 -1
- package/src/sap/ui/core/Component.js +16 -14
- package/src/sap/ui/core/ComponentContainer.js +6 -5
- package/src/sap/ui/core/ComponentMetadata.js +5 -12
- package/src/sap/ui/core/ComponentSupport.js +1 -1
- package/src/sap/ui/core/Configuration.js +525 -336
- package/src/sap/ui/core/Control.js +7 -7
- package/src/sap/ui/core/Core.js +102 -422
- package/src/sap/ui/core/CustomData.js +1 -1
- package/src/sap/ui/core/DeclarativeSupport.js +1 -1
- package/src/sap/ui/core/Element.js +65 -9
- package/src/sap/ui/core/ElementMetadata.js +1 -1
- package/src/sap/ui/core/EnabledPropagator.js +1 -1
- package/src/sap/ui/core/EventBus.js +1 -1
- package/src/sap/ui/core/FocusHandler.js +79 -9
- package/src/sap/ui/core/Fragment.js +1 -1
- package/src/sap/ui/core/HTML.js +1 -2
- package/src/sap/ui/core/History.js +1 -1
- package/src/sap/ui/core/Icon.js +1 -2
- package/src/sap/ui/core/IconPool.js +8 -8
- package/src/sap/ui/core/IndicationColorSupport.js +2 -2
- package/src/sap/ui/core/IntervalTrigger.js +1 -1
- package/src/sap/ui/core/InvisibleMessage.js +1 -2
- package/src/sap/ui/core/InvisibleRenderer.js +1 -1
- package/src/sap/ui/core/InvisibleText.js +5 -5
- package/src/sap/ui/core/Item.js +1 -2
- package/src/sap/ui/core/LabelEnablement.js +1 -1
- package/src/sap/ui/core/LayoutData.js +1 -2
- package/src/sap/ui/core/ListItem.js +1 -2
- package/src/sap/ui/core/LocalBusyIndicator.js +1 -2
- package/src/sap/ui/core/Locale.js +1 -1
- package/src/sap/ui/core/LocaleData.js +15 -13
- package/src/sap/ui/core/Manifest.js +8 -6
- package/src/sap/ui/core/Message.js +4 -6
- package/src/sap/ui/core/Popup.js +63 -6
- package/src/sap/ui/core/RenderManager.js +13 -5
- package/src/sap/ui/core/Renderer.js +5 -4
- package/src/sap/ui/core/Rendering.js +251 -0
- package/src/sap/ui/core/ResizeHandler.js +7 -7
- package/src/sap/ui/core/ScrollBar.js +6 -9
- package/src/sap/ui/core/ScrollBarRenderer.js +3 -3
- package/src/sap/ui/core/SeparatorItem.js +1 -2
- package/src/sap/ui/core/Title.js +1 -2
- package/src/sap/ui/core/TooltipBase.js +12 -14
- package/src/sap/ui/core/UIArea.js +396 -129
- package/src/sap/ui/core/UIComponent.js +3 -4
- package/src/sap/ui/core/UIComponentMetadata.js +1 -1
- package/src/sap/ui/core/ValueStateSupport.js +2 -2
- package/src/sap/ui/core/VariantLayoutData.js +1 -2
- package/src/sap/ui/core/XMLComposite.js +2 -2
- package/src/sap/ui/core/XMLCompositeMetadata.js +1 -1
- package/src/sap/ui/core/XMLTemplateProcessor.js +12 -10
- package/src/sap/ui/core/_ConfigurationProvider.js +187 -0
- package/src/sap/ui/core/cache/CacheManager.js +9 -8
- package/src/sap/ui/core/cache/LRUPersistentCache.js +4 -4
- package/src/sap/ui/core/cldr/es_BO.json +3 -3
- package/src/sap/ui/core/cldr/es_CL.json +3 -3
- package/src/sap/ui/core/cldr/es_MX.json +3 -3
- package/src/sap/ui/core/cldr/es_PE.json +3 -3
- package/src/sap/ui/core/cldr/es_UY.json +3 -3
- package/src/sap/ui/core/cldr/es_VE.json +2 -2
- package/src/sap/ui/core/date/Islamic.js +4 -4
- package/src/sap/ui/core/date/UniversalDate.js +8 -8
- package/src/sap/ui/core/date/UniversalDateUtils.js +3 -3
- package/src/sap/ui/core/delegate/ItemNavigation.js +5 -5
- package/src/sap/ui/core/delegate/ScrollEnablement.js +7 -6
- package/src/sap/ui/core/dnd/DragAndDrop.js +14 -9
- package/src/sap/ui/core/dnd/DragDropBase.js +1 -2
- package/src/sap/ui/core/dnd/DragDropInfo.js +1 -2
- package/src/sap/ui/core/dnd/DragInfo.js +1 -2
- package/src/sap/ui/core/dnd/DropInfo.js +1 -2
- package/src/sap/ui/core/format/DateFormat.js +14 -7
- package/src/sap/ui/core/format/DateFormatTimezoneDisplay.js +0 -1
- package/src/sap/ui/core/format/FileSizeFormat.js +4 -3
- package/src/sap/ui/core/format/ListFormat.js +4 -3
- package/src/sap/ui/core/format/NumberFormat.js +7 -6
- package/src/sap/ui/core/format/TimezoneUtil.js +1 -1
- package/src/sap/ui/core/hyphenation/Hyphenation.js +7 -6
- package/src/sap/ui/core/library.js +3 -55
- package/src/sap/ui/core/message/ControlMessageProcessor.js +1 -1
- package/src/sap/ui/core/message/Message.js +1 -1
- package/src/sap/ui/core/message/MessageManager.js +13 -23
- package/src/sap/ui/core/message/MessageParser.js +1 -1
- package/src/sap/ui/core/message/MessageProcessor.js +1 -1
- package/src/sap/ui/core/messagebundle_fr.properties +1 -1
- package/src/sap/ui/core/mvc/Controller.js +8 -3
- package/src/sap/ui/core/mvc/EventHandlerResolver.js +5 -3
- package/src/sap/ui/core/mvc/HTMLView.js +1 -2
- package/src/sap/ui/core/mvc/JSONView.js +1 -2
- package/src/sap/ui/core/mvc/JSView.js +2 -3
- package/src/sap/ui/core/mvc/TemplateView.js +1 -2
- package/src/sap/ui/core/mvc/View.js +21 -20
- package/src/sap/ui/core/mvc/ViewType.js +0 -1
- package/src/sap/ui/core/mvc/XMLView.js +18 -18
- package/src/sap/ui/core/plugin/DeclarativeSupport.js +1 -1
- package/src/sap/ui/core/plugin/LessSupport.js +1 -1
- package/src/sap/ui/core/plugin/TemplatingSupport.js +1 -1
- package/src/sap/ui/core/postmessage/Bus.js +1 -1
- package/src/sap/ui/core/postmessage/confirmationDialog.js +1 -1
- package/src/sap/ui/core/routing/Router.js +1 -1
- package/src/sap/ui/core/routing/async/Target.js +4 -3
- package/src/sap/ui/core/rules/App.support.js +11 -13
- package/src/sap/ui/core/rules/Config.support.js +19 -17
- package/src/sap/ui/core/rules/CoreHelper.support.js +4 -4
- package/src/sap/ui/core/rules/Model.support.js +8 -8
- package/src/sap/ui/core/rules/Rendering.support.js +1 -1
- package/src/sap/ui/core/rules/Theming.support.js +8 -8
- package/src/sap/ui/core/rules/View.support.js +9 -9
- package/src/sap/ui/core/search/OpenSearchProvider.js +1 -2
- package/src/sap/ui/core/search/SearchProvider.js +1 -3
- package/src/sap/ui/core/service/Service.js +1 -1
- package/src/sap/ui/core/service/ServiceFactory.js +1 -1
- package/src/sap/ui/core/service/ServiceFactoryRegistry.js +1 -1
- package/src/sap/ui/core/support/Hotkeys.js +2 -3
- package/src/sap/ui/core/support/Plugin.js +1 -1
- package/src/sap/ui/core/support/Support.js +1 -1
- package/src/sap/ui/core/support/ToolsAPI.js +11 -13
- package/src/sap/ui/core/support/plugins/ControlTree.js +4 -4
- package/src/sap/ui/core/support/plugins/Debugging.js +3 -3
- package/src/sap/ui/core/support/plugins/Interaction.js +1 -1
- package/src/sap/ui/core/support/plugins/LocalStorage.js +1 -1
- package/src/sap/ui/core/support/plugins/Performance.js +1 -1
- package/src/sap/ui/core/support/plugins/Selector.js +1 -1
- package/src/sap/ui/core/support/plugins/TechInfo.js +1 -1
- package/src/sap/ui/core/support/plugins/Trace.js +1 -1
- package/src/sap/ui/core/support/plugins/ViewInfo.js +2 -2
- package/src/sap/ui/core/support/support.html +1 -1
- package/src/sap/ui/core/support/techinfo/TechnicalInfo.js +10 -8
- package/src/sap/ui/core/theming/Parameters.js +8 -15
- package/src/sap/ui/core/tmpl/DOMAttribute.js +1 -2
- package/src/sap/ui/core/tmpl/DOMElement.js +1 -4
- package/src/sap/ui/core/tmpl/HandlebarsTemplate.js +1 -1
- package/src/sap/ui/core/tmpl/Template.js +6 -5
- package/src/sap/ui/core/tmpl/TemplateControl.js +1 -2
- package/src/sap/ui/core/util/AsyncHintsHelper.js +1 -1
- package/src/sap/ui/core/util/Export.js +1 -1
- package/src/sap/ui/core/util/ExportCell.js +1 -1
- package/src/sap/ui/core/util/ExportColumn.js +1 -1
- package/src/sap/ui/core/util/ExportRow.js +1 -1
- package/src/sap/ui/core/util/ExportType.js +1 -1
- package/src/sap/ui/core/util/ExportTypeCSV.js +1 -1
- package/src/sap/ui/core/util/File.js +1 -1
- package/src/sap/ui/core/util/LibraryInfo.js +1 -1
- package/src/sap/ui/core/util/MockServer.js +48 -72
- package/src/sap/ui/core/util/PasteHelper.js +1 -1
- package/src/sap/ui/core/util/ResponsivePaddingsEnablement.js +4 -3
- package/src/sap/ui/core/util/XMLPreprocessor.js +2 -2
- package/src/sap/ui/core/util/reflection/BaseTreeModifier.js +1 -1
- package/src/sap/ui/core/util/serializer/HTMLViewSerializer.js +1 -1
- package/src/sap/ui/core/util/serializer/Serializer.js +1 -1
- package/src/sap/ui/core/util/serializer/ViewSerializer.js +4 -4
- package/src/sap/ui/core/util/serializer/XMLViewSerializer.js +1 -1
- package/src/sap/ui/core/util/serializer/delegate/Delegate.js +1 -1
- package/src/sap/ui/core/util/serializer/delegate/HTML.js +1 -1
- package/src/sap/ui/core/util/serializer/delegate/XML.js +1 -1
- package/src/sap/ui/core/ws/ReadyState.js +1 -1
- package/src/sap/ui/core/ws/SapPcpWebSocket.js +1 -1
- package/src/sap/ui/core/ws/WebSocket.js +1 -1
- package/src/sap/ui/debug/ControlTree.js +3 -3
- package/src/sap/ui/debug/DebugEnv.js +4 -4
- package/src/sap/ui/debug/PropertyList.css +1 -31
- package/src/sap/ui/debug/PropertyList.js +6 -250
- package/src/sap/ui/dom/getScrollbarSize.js +1 -1
- package/src/sap/ui/dom/jquery/control.js +1 -0
- package/src/sap/ui/events/jquery/EventSimulation.js +4 -4
- package/src/sap/ui/model/ClientModel.js +1 -1
- package/src/sap/ui/model/ClientTreeBinding.js +3 -1
- package/src/sap/ui/model/CompositeDataState.js +1 -1
- package/src/sap/ui/model/CompositeType.js +1 -1
- package/src/sap/ui/model/Context.js +3 -0
- package/src/sap/ui/model/ContextBinding.js +1 -1
- package/src/sap/ui/model/DataState.js +2 -2
- package/src/sap/ui/model/ListBinding.js +2 -2
- package/src/sap/ui/model/ManagedObjectBindingSupport.js +871 -0
- package/src/sap/ui/model/MetaModel.js +1 -1
- package/src/sap/ui/model/Model.js +16 -5
- package/src/sap/ui/model/SelectionModel.js +1 -1
- package/src/sap/ui/model/SimpleType.js +2 -2
- package/src/sap/ui/model/Sorter.js +24 -19
- package/src/sap/ui/model/TreeAutoExpandMode.js +1 -1
- package/src/sap/ui/model/TreeBindingAdapter.js +3 -7
- package/src/sap/ui/model/Type.js +1 -1
- package/src/sap/ui/model/analytics/AnalyticalBinding.js +2 -0
- package/src/sap/ui/model/analytics/AnalyticalTreeBindingAdapter.js +5 -7
- package/src/sap/ui/model/json/JSONModel.js +9 -7
- package/src/sap/ui/model/message/MessageModel.js +1 -1
- package/src/sap/ui/model/odata/AnnotationHelper.js +4 -4
- package/src/sap/ui/model/odata/ODataAnnotations.js +5 -3
- package/src/sap/ui/model/odata/ODataMessageParser.js +1 -1
- package/src/sap/ui/model/odata/ODataMetaModel.js +10 -10
- package/src/sap/ui/model/odata/ODataMetadata.js +5 -4
- package/src/sap/ui/model/odata/ODataModel.js +6 -5
- package/src/sap/ui/model/odata/ODataTreeBindingFlat.js +0 -1
- package/src/sap/ui/model/odata/type/Boolean.js +1 -1
- package/src/sap/ui/model/odata/type/Byte.js +1 -1
- package/src/sap/ui/model/odata/type/Currency.js +1 -1
- package/src/sap/ui/model/odata/type/Date.js +1 -1
- package/src/sap/ui/model/odata/type/DateTime.js +1 -1
- package/src/sap/ui/model/odata/type/DateTimeBase.js +1 -1
- package/src/sap/ui/model/odata/type/DateTimeOffset.js +1 -1
- package/src/sap/ui/model/odata/type/DateTimeWithTimezone.js +1 -1
- package/src/sap/ui/model/odata/type/Decimal.js +1 -1
- package/src/sap/ui/model/odata/type/Double.js +1 -1
- package/src/sap/ui/model/odata/type/Guid.js +1 -1
- package/src/sap/ui/model/odata/type/Int.js +1 -1
- package/src/sap/ui/model/odata/type/Int16.js +1 -1
- package/src/sap/ui/model/odata/type/Int32.js +1 -1
- package/src/sap/ui/model/odata/type/Int64.js +1 -1
- package/src/sap/ui/model/odata/type/ODataType.js +1 -1
- package/src/sap/ui/model/odata/type/Raw.js +1 -1
- package/src/sap/ui/model/odata/type/SByte.js +1 -1
- package/src/sap/ui/model/odata/type/Single.js +1 -1
- package/src/sap/ui/model/odata/type/Stream.js +1 -1
- package/src/sap/ui/model/odata/type/String.js +1 -1
- package/src/sap/ui/model/odata/type/Time.js +1 -1
- package/src/sap/ui/model/odata/type/TimeOfDay.js +1 -1
- package/src/sap/ui/model/odata/type/Unit.js +1 -1
- package/src/sap/ui/model/odata/v2/Context.js +5 -5
- package/src/sap/ui/model/odata/v2/ODataAnnotations.js +4 -3
- package/src/sap/ui/model/odata/v2/ODataContextBinding.js +25 -16
- package/src/sap/ui/model/odata/v2/ODataListBinding.js +46 -28
- package/src/sap/ui/model/odata/v2/ODataModel.js +97 -39
- package/src/sap/ui/model/odata/v2/ODataTreeBinding.js +5 -5
- package/src/sap/ui/model/odata/v4/AnnotationHelper.js +3 -3
- package/src/sap/ui/model/odata/v4/Context.js +109 -71
- package/src/sap/ui/model/odata/v4/ODataBinding.js +50 -7
- package/src/sap/ui/model/odata/v4/ODataContextBinding.js +88 -68
- package/src/sap/ui/model/odata/v4/ODataListBinding.js +116 -81
- package/src/sap/ui/model/odata/v4/ODataMetaModel.js +23 -20
- package/src/sap/ui/model/odata/v4/ODataModel.js +350 -88
- package/src/sap/ui/model/odata/v4/ODataParentBinding.js +35 -9
- package/src/sap/ui/model/odata/v4/ODataPropertyBinding.js +15 -9
- package/src/sap/ui/model/odata/v4/ODataUtils.js +8 -5
- package/src/sap/ui/model/odata/v4/lib/_AggregationCache.js +45 -33
- package/src/sap/ui/model/odata/v4/lib/_AggregationHelper.js +40 -6
- package/src/sap/ui/model/odata/v4/lib/_Cache.js +135 -81
- package/src/sap/ui/model/odata/v4/lib/_ConcatHelper.js +2 -3
- package/src/sap/ui/model/odata/v4/lib/_Helper.js +179 -36
- package/src/sap/ui/model/odata/v4/lib/_MinMaxHelper.js +2 -3
- package/src/sap/ui/model/odata/v4/lib/_Requestor.js +26 -7
- package/src/sap/ui/model/resource/ResourceModel.js +8 -7
- package/src/sap/ui/model/type/Boolean.js +1 -1
- package/src/sap/ui/model/type/Currency.js +2 -2
- package/src/sap/ui/model/type/Date.js +1 -1
- package/src/sap/ui/model/type/DateInterval.js +1 -1
- package/src/sap/ui/model/type/DateTime.js +1 -1
- package/src/sap/ui/model/type/DateTimeInterval.js +1 -1
- package/src/sap/ui/model/type/FileSize.js +1 -1
- package/src/sap/ui/model/type/Float.js +1 -1
- package/src/sap/ui/model/type/Integer.js +1 -1
- package/src/sap/ui/model/type/String.js +2 -2
- package/src/sap/ui/model/type/Time.js +1 -1
- package/src/sap/ui/model/type/TimeInterval.js +1 -1
- package/src/sap/ui/model/type/Unit.js +5 -4
- package/src/sap/ui/model/xml/XMLModel.js +8 -6
- package/src/sap/ui/performance/trace/Interaction.js +1 -1
- package/src/sap/ui/qunit/utils/ControlIterator.js +1 -1
- package/src/sap/ui/qunit/utils/MemoryLeakCheck.js +1 -1
- package/src/sap/ui/test/Opa.js +7 -5
- package/src/sap/ui/test/Opa5.js +9 -15
- package/src/sap/ui/test/OpaBuilder.js +1 -1
- package/src/sap/ui/test/RecorderHotkeyListener.js +1 -1
- package/src/sap/ui/test/TestUtils.js +83 -1
- package/src/sap/ui/test/autowaiter/_autoWaiter.js +9 -0
- package/src/sap/ui/test/autowaiter/_cssAnimationWaiter.js +114 -0
- package/src/sap/ui/test/autowaiter/_cssTransitionWaiter.js +99 -0
- package/src/sap/ui/test/autowaiter/_jsAnimationWaiter.js +70 -0
- package/src/sap/ui/test/autowaiter/_resourceWaiter.js +3 -12
- package/src/sap/ui/test/autowaiter/_utils.js +13 -1
- package/src/sap/ui/test/generic/TestBase.js +1 -1
- package/src/sap/ui/test/matchers/Ancestor.js +1 -0
- package/src/sap/ui/test/matchers/Descendant.js +1 -0
- package/src/sap/ui/test/matchers/Sibling.js +1 -0
- package/src/sap/ui/util/Storage.js +1 -1
|
@@ -54,11 +54,13 @@ sap.ui.define([
|
|
|
54
54
|
*
|
|
55
55
|
* @param {function} fnFunction The function to call when the event occurs
|
|
56
56
|
* @param {object} [oListener] Object on which to call the given function
|
|
57
|
+
* @returns {this} <code>this</code> to allow method chaining
|
|
58
|
+
*
|
|
57
59
|
* @public
|
|
58
60
|
* @since 1.59.0
|
|
59
61
|
*/
|
|
60
62
|
ODataParentBinding.prototype.attachPatchCompleted = function (fnFunction, oListener) {
|
|
61
|
-
this.attachEvent("patchCompleted", fnFunction, oListener);
|
|
63
|
+
return this.attachEvent("patchCompleted", fnFunction, oListener);
|
|
62
64
|
};
|
|
63
65
|
|
|
64
66
|
/**
|
|
@@ -66,11 +68,13 @@ sap.ui.define([
|
|
|
66
68
|
*
|
|
67
69
|
* @param {function} fnFunction The function to call when the event occurs
|
|
68
70
|
* @param {object} [oListener] Object on which to call the given function
|
|
71
|
+
* @returns {this} <code>this</code> to allow method chaining
|
|
72
|
+
*
|
|
69
73
|
* @public
|
|
70
74
|
* @since 1.59.0
|
|
71
75
|
*/
|
|
72
76
|
ODataParentBinding.prototype.detachPatchCompleted = function (fnFunction, oListener) {
|
|
73
|
-
this.detachEvent("patchCompleted", fnFunction, oListener);
|
|
77
|
+
return this.detachEvent("patchCompleted", fnFunction, oListener);
|
|
74
78
|
};
|
|
75
79
|
|
|
76
80
|
/**
|
|
@@ -138,11 +142,13 @@ sap.ui.define([
|
|
|
138
142
|
*
|
|
139
143
|
* @param {function} fnFunction The function to call when the event occurs
|
|
140
144
|
* @param {object} [oListener] Object on which to call the given function
|
|
145
|
+
* @returns {this} <code>this</code> to allow method chaining
|
|
146
|
+
*
|
|
141
147
|
* @public
|
|
142
148
|
* @since 1.59.0
|
|
143
149
|
*/
|
|
144
150
|
ODataParentBinding.prototype.attachPatchSent = function (fnFunction, oListener) {
|
|
145
|
-
this.attachEvent("patchSent", fnFunction, oListener);
|
|
151
|
+
return this.attachEvent("patchSent", fnFunction, oListener);
|
|
146
152
|
};
|
|
147
153
|
|
|
148
154
|
/**
|
|
@@ -150,11 +156,13 @@ sap.ui.define([
|
|
|
150
156
|
*
|
|
151
157
|
* @param {function} fnFunction The function to call when the event occurs
|
|
152
158
|
* @param {object} [oListener] Object on which to call the given function
|
|
159
|
+
* @returns {this} <code>this</code> to allow method chaining
|
|
160
|
+
*
|
|
153
161
|
* @public
|
|
154
162
|
* @since 1.59.0
|
|
155
163
|
*/
|
|
156
164
|
ODataParentBinding.prototype.detachPatchSent = function (fnFunction, oListener) {
|
|
157
|
-
this.detachEvent("patchSent", fnFunction, oListener);
|
|
165
|
+
return this.detachEvent("patchSent", fnFunction, oListener);
|
|
158
166
|
};
|
|
159
167
|
|
|
160
168
|
/**
|
|
@@ -332,7 +340,7 @@ sap.ui.define([
|
|
|
332
340
|
* 1.93.0, string values for "$expand" and "$select" are ignored if they are unchanged;
|
|
333
341
|
* pending changes are ignored if all parameters are unchanged. Since 1.97.0, pending changes
|
|
334
342
|
* are ignored if they relate to a
|
|
335
|
-
* {@link sap.ui.model.odata.v4.Context#
|
|
343
|
+
* {@link sap.ui.model.odata.v4.Context#isKeepAlive kept-alive} context of this binding.
|
|
336
344
|
* Since 1.98.0, {@link sap.ui.model.odata.v4.Context#isTransient transient} contexts
|
|
337
345
|
* of a {@link #getRootBinding root binding} do not count as pending changes.
|
|
338
346
|
*
|
|
@@ -416,7 +424,7 @@ sap.ui.define([
|
|
|
416
424
|
*
|
|
417
425
|
* @abstract
|
|
418
426
|
* @function
|
|
419
|
-
* @name sap.ui.model.odata.v4.
|
|
427
|
+
* @name sap.ui.model.odata.v4.ODataParentBinding#checkKeepAlive
|
|
420
428
|
* @private
|
|
421
429
|
* @see sap.ui.model.odata.v4.Context#setKeepAlive
|
|
422
430
|
*/
|
|
@@ -564,17 +572,22 @@ sap.ui.define([
|
|
|
564
572
|
/**
|
|
565
573
|
* Creates a promise for the refresh to be resolved by the binding's GET request.
|
|
566
574
|
*
|
|
567
|
-
* @
|
|
575
|
+
* @param {boolean} bPreventBubbling
|
|
576
|
+
* Whether the dataRequested and dataReceived events related to the refresh must not be
|
|
577
|
+
* bubbled up to the model
|
|
578
|
+
* @returns {Promise} The created promise
|
|
568
579
|
*
|
|
580
|
+
* @see #isRefreshWithoutBubbling
|
|
569
581
|
* @see #resolveRefreshPromise
|
|
570
582
|
* @private
|
|
571
583
|
*/
|
|
572
|
-
ODataParentBinding.prototype.createRefreshPromise = function () {
|
|
584
|
+
ODataParentBinding.prototype.createRefreshPromise = function (bPreventBubbling) {
|
|
573
585
|
var oPromise, fnResolve;
|
|
574
586
|
|
|
575
587
|
oPromise = new Promise(function (resolve) {
|
|
576
588
|
fnResolve = resolve;
|
|
577
589
|
});
|
|
590
|
+
oPromise.$preventBubbling = bPreventBubbling;
|
|
578
591
|
oPromise.$resolve = fnResolve;
|
|
579
592
|
this.oRefreshPromise = oPromise;
|
|
580
593
|
return oPromise;
|
|
@@ -1080,6 +1093,19 @@ sap.ui.define([
|
|
|
1080
1093
|
return false;
|
|
1081
1094
|
};
|
|
1082
1095
|
|
|
1096
|
+
/**
|
|
1097
|
+
* Whether the dataRequested and dataReceived events related to the refresh must not be bubbled
|
|
1098
|
+
* up to the model.
|
|
1099
|
+
*
|
|
1100
|
+
* @returns {boolean} Whether to prevent bubbling
|
|
1101
|
+
*
|
|
1102
|
+
* @private
|
|
1103
|
+
* @see #createRefreshPromise
|
|
1104
|
+
*/
|
|
1105
|
+
ODataParentBinding.prototype.isRefreshWithoutBubbling = function () {
|
|
1106
|
+
return this.oRefreshPromise && this.oRefreshPromise.$preventBubbling;
|
|
1107
|
+
};
|
|
1108
|
+
|
|
1083
1109
|
/**
|
|
1084
1110
|
* @override
|
|
1085
1111
|
* @see sap.ui.model.odata.v4.ODataBinding#onDelete
|
|
@@ -1332,7 +1358,7 @@ sap.ui.define([
|
|
|
1332
1358
|
* Suspends this binding. A suspended binding does not fire change events nor does it trigger
|
|
1333
1359
|
* data service requests. Call {@link #resume} to resume the binding. Before 1.53.0, this method
|
|
1334
1360
|
* was not supported and threw an error. Since 1.97.0, pending changes are ignored if they
|
|
1335
|
-
* relate to a {@link sap.ui.model.odata.v4.Context#
|
|
1361
|
+
* relate to a {@link sap.ui.model.odata.v4.Context#isKeepAlive kept-alive} context of this
|
|
1336
1362
|
* binding. Since 1.98.0, {@link sap.ui.model.odata.v4.Context#isTransient transient} contexts
|
|
1337
1363
|
* of a {@link #getRootBinding root binding} do not count as pending changes.
|
|
1338
1364
|
*
|
|
@@ -42,7 +42,7 @@ sap.ui.define([
|
|
|
42
42
|
* @mixes sap.ui.model.odata.v4.ODataBinding
|
|
43
43
|
* @public
|
|
44
44
|
* @since 1.37.0
|
|
45
|
-
* @version 1.
|
|
45
|
+
* @version 1.107.0
|
|
46
46
|
* @borrows sap.ui.model.odata.v4.ODataBinding#getGroupId as #getGroupId
|
|
47
47
|
* @borrows sap.ui.model.odata.v4.ODataBinding#getRootBinding as #getRootBinding
|
|
48
48
|
* @borrows sap.ui.model.odata.v4.ODataBinding#getUpdateGroupId as #getUpdateGroupId
|
|
@@ -228,6 +228,9 @@ sap.ui.define([
|
|
|
228
228
|
* The change reason for the change event
|
|
229
229
|
* @param {string} [sGroupId=getGroupId()]
|
|
230
230
|
* The group ID to be used for the read.
|
|
231
|
+
* @param {boolean} [bPreventBubbling]
|
|
232
|
+
* Whether the dataRequested and dataReceived events related to the refresh must not be
|
|
233
|
+
* bubbled up to the model
|
|
231
234
|
* @param {any} [vValue]
|
|
232
235
|
* The new value obtained from the cache, see {@link #onChange}
|
|
233
236
|
* @returns {sap.ui.base.SyncPromise}
|
|
@@ -241,7 +244,7 @@ sap.ui.define([
|
|
|
241
244
|
*/
|
|
242
245
|
// @override sap.ui.model.odata.v4.ODataBinding#checkUpdateInternal
|
|
243
246
|
ODataPropertyBinding.prototype.checkUpdateInternal = function (bForceUpdate, sChangeReason,
|
|
244
|
-
sGroupId, vValue) {
|
|
247
|
+
sGroupId, bPreventBubbling, vValue) {
|
|
245
248
|
var bDataRequested = false,
|
|
246
249
|
iHashHash = this.sPath.indexOf("##"),
|
|
247
250
|
bIsMeta = iHashHash >= 0,
|
|
@@ -278,7 +281,7 @@ sap.ui.define([
|
|
|
278
281
|
return oCache.fetchValue(that.lockGroup(sGroupId || that.getGroupId()),
|
|
279
282
|
/*sPath*/undefined, function () {
|
|
280
283
|
bDataRequested = true;
|
|
281
|
-
that.fireDataRequested();
|
|
284
|
+
that.fireDataRequested(bPreventBubbling);
|
|
282
285
|
}, that)
|
|
283
286
|
.then(function (vResult) {
|
|
284
287
|
that.assertSameCache(oCache);
|
|
@@ -352,7 +355,7 @@ sap.ui.define([
|
|
|
352
355
|
that.checkDataState();
|
|
353
356
|
}
|
|
354
357
|
if (bDataRequested) {
|
|
355
|
-
that.fireDataReceived(mParametersForDataReceived);
|
|
358
|
+
that.fireDataReceived(mParametersForDataReceived, bPreventBubbling);
|
|
356
359
|
}
|
|
357
360
|
if (mParametersForDataReceived.error) {
|
|
358
361
|
throw mParametersForDataReceived.error;
|
|
@@ -493,11 +496,13 @@ sap.ui.define([
|
|
|
493
496
|
*
|
|
494
497
|
* @param {any} vValue
|
|
495
498
|
* The new value
|
|
499
|
+
* @param {boolean} [bForceUpdate]
|
|
500
|
+
* Update the bound control even if no data have been changed.
|
|
496
501
|
*
|
|
497
502
|
* @private
|
|
498
503
|
*/
|
|
499
|
-
ODataPropertyBinding.prototype.onChange = function (vValue) {
|
|
500
|
-
this.checkUpdateInternal(
|
|
504
|
+
ODataPropertyBinding.prototype.onChange = function (vValue, bForceUpdate) {
|
|
505
|
+
this.checkUpdateInternal(bForceUpdate, undefined, undefined, false, vValue)
|
|
501
506
|
.catch(this.oModel.getReporter());
|
|
502
507
|
};
|
|
503
508
|
|
|
@@ -529,7 +534,8 @@ sap.ui.define([
|
|
|
529
534
|
}
|
|
530
535
|
|
|
531
536
|
if (bCheckUpdate) {
|
|
532
|
-
return that.checkUpdateInternal(undefined, ChangeReason.Refresh, sGroupId
|
|
537
|
+
return that.checkUpdateInternal(undefined, ChangeReason.Refresh, sGroupId,
|
|
538
|
+
/*bPreventBubbling*/bKeepCacheOnError);
|
|
533
539
|
}
|
|
534
540
|
});
|
|
535
541
|
};
|
|
@@ -537,7 +543,7 @@ sap.ui.define([
|
|
|
537
543
|
/**
|
|
538
544
|
* Requests the value of the property binding.
|
|
539
545
|
*
|
|
540
|
-
* @returns {Promise}
|
|
546
|
+
* @returns {Promise<any|undefined>}
|
|
541
547
|
* A promise resolving with the resulting value or <code>undefined</code> if it could not be
|
|
542
548
|
* determined, or rejecting in case of an error
|
|
543
549
|
*
|
|
@@ -754,7 +760,7 @@ sap.ui.define([
|
|
|
754
760
|
throw reportError(new Error("Must not specify a group ID (" + sGroupId
|
|
755
761
|
+ ") with $$noPatch"));
|
|
756
762
|
}
|
|
757
|
-
|
|
763
|
+
_Helper.checkGroupId(sGroupId);
|
|
758
764
|
if (typeof vValue === "function" || (vValue && typeof vValue === "object")) {
|
|
759
765
|
throw reportError(new Error("Not a primitive value"));
|
|
760
766
|
}
|
|
@@ -76,7 +76,7 @@ sap.ui.define([
|
|
|
76
76
|
* corresponding number of milliseconds since 1 January, 1970 UTC.
|
|
77
77
|
* Otherwise the values are compared with the JavaScript operators <code>===</code>
|
|
78
78
|
* and <code>></code>.
|
|
79
|
-
* @
|
|
79
|
+
* @returns {number}
|
|
80
80
|
* The result of the comparison: <code>0</code> if the values are equal,
|
|
81
81
|
* <code>1</code> if the first value is larger, <code>-1</code> if the second value
|
|
82
82
|
* is larger, <code>NaN</code> if they cannot be compared
|
|
@@ -139,13 +139,16 @@ sap.ui.define([
|
|
|
139
139
|
* and URLs.
|
|
140
140
|
*
|
|
141
141
|
* @param {any} vValue
|
|
142
|
-
* The value according to
|
|
143
|
-
* "
|
|
142
|
+
* The value according to <a href=
|
|
143
|
+
* "https://docs.oasis-open.org/odata/odata-json-format/v4.0/os/odata-json-format-v4.0-os.html#_Primitive_Value"
|
|
144
|
+
* >"OData JSON Format Version 4.0" section "7.1 Primitive Value"</a>
|
|
144
145
|
* @param {string} sType
|
|
145
146
|
* The OData primitive type, for example "Edm.String"
|
|
146
147
|
* @returns {string}
|
|
147
|
-
* The literal according to
|
|
148
|
-
* "
|
|
148
|
+
* The literal according to <a href=
|
|
149
|
+
* "https://docs.oasis-open.org/odata/odata/v4.0/odata-v4.0-part2-url-conventions.html"
|
|
150
|
+
* >"OData Version 4.0 Part 2: URL Conventions"</a> section
|
|
151
|
+
* "5.1.1.11.1 Primitive Literals"
|
|
149
152
|
* @throws {Error}
|
|
150
153
|
* If the value is undefined or the type is not supported
|
|
151
154
|
*
|
|
@@ -32,9 +32,8 @@ sap.ui.define([
|
|
|
32
32
|
* @param {string} sResourcePath
|
|
33
33
|
* A resource path relative to the service URL
|
|
34
34
|
* @param {object} oAggregation
|
|
35
|
-
* An object holding the information needed for data aggregation; see also
|
|
36
|
-
*
|
|
37
|
-
* Extension for Data Aggregation Version 4.0</a>; must already be normalized by
|
|
35
|
+
* An object holding the information needed for data aggregation; see also "OData Extension
|
|
36
|
+
* for Data Aggregation Version 4.0"; must already be normalized by
|
|
38
37
|
* {@link _AggregationHelper.buildApply}
|
|
39
38
|
* @param {object} mQueryOptions
|
|
40
39
|
* A map of key-value pairs representing the query string
|
|
@@ -869,9 +868,8 @@ sap.ui.define([
|
|
|
869
868
|
* @param {string} sDeepResourcePath
|
|
870
869
|
* The deep resource path to be used to build the target path for bound messages
|
|
871
870
|
* @param {object} [oAggregation]
|
|
872
|
-
* An object holding the information needed for data aggregation; see also
|
|
873
|
-
*
|
|
874
|
-
* Extension for Data Aggregation Version 4.0</a>; must already be normalized by
|
|
871
|
+
* An object holding the information needed for data aggregation; see also "OData Extension
|
|
872
|
+
* for Data Aggregation Version 4.0"; must already be normalized by
|
|
875
873
|
* {@link _AggregationHelper.buildApply}
|
|
876
874
|
* @param {object} mQueryOptions
|
|
877
875
|
* A map of key-value pairs representing the query string, the value in this pair has to
|
|
@@ -887,57 +885,71 @@ sap.ui.define([
|
|
|
887
885
|
* If this parameter is set, multiple requests for a cache using the same resource path will
|
|
888
886
|
* always return the same, shared cache. This cache is read-only, modifying calls lead to an
|
|
889
887
|
* error.
|
|
888
|
+
* @param {boolean} [bIsGrouped]
|
|
889
|
+
* Whether the list binding is grouped via its first sorter
|
|
890
890
|
* @returns {sap.ui.model.odata.v4.lib._Cache}
|
|
891
891
|
* The cache
|
|
892
892
|
* @throws {Error}
|
|
893
893
|
* If the system query option "$filter" is combined with group levels or with grand totals
|
|
894
|
-
* (unless "grandTotal like 1.84"), or if grand totals or group levels
|
|
895
|
-
* min/max, or if the system query options
|
|
896
|
-
* aggregation (no recursive hierarchy)
|
|
894
|
+
* (unless "grandTotal like 1.84"), or if grand totals or group levels or recursive hierarchy
|
|
895
|
+
* are combined with min/max or with grouping via sorter, or if the system query options
|
|
896
|
+
* "$expand" or "$select" are combined with pure data aggregation (no recursive hierarchy), or
|
|
897
|
+
* if the system query option "$search" is combined with grand totals or group levels or a
|
|
898
|
+
* recursive hierarchy
|
|
897
899
|
*
|
|
898
900
|
* @public
|
|
899
901
|
*/
|
|
900
902
|
_AggregationCache.create = function (oRequestor, sResourcePath, sDeepResourcePath, oAggregation,
|
|
901
|
-
mQueryOptions, bSortExpandSelect, bSharedRequest) {
|
|
902
|
-
var bHasGrandTotal, bHasGroupLevels
|
|
903
|
+
mQueryOptions, bSortExpandSelect, bSharedRequest, bIsGrouped) {
|
|
904
|
+
var bHasGrandTotal, bHasGroupLevels;
|
|
905
|
+
|
|
906
|
+
function checkExpandSelect() {
|
|
907
|
+
if ("$expand" in mQueryOptions) {
|
|
908
|
+
throw new Error("Unsupported system query option: $expand");
|
|
909
|
+
}
|
|
910
|
+
if ("$select" in mQueryOptions) {
|
|
911
|
+
throw new Error("Unsupported system query option: $select");
|
|
912
|
+
}
|
|
913
|
+
}
|
|
903
914
|
|
|
904
915
|
if (oAggregation) {
|
|
905
916
|
bHasGrandTotal = _AggregationHelper.hasGrandTotal(oAggregation.aggregate);
|
|
906
917
|
bHasGroupLevels = oAggregation.groupLevels && !!oAggregation.groupLevels.length;
|
|
907
|
-
bHasMinOrMax = _AggregationHelper.hasMinOrMax(oAggregation.aggregate);
|
|
908
918
|
|
|
909
|
-
if (
|
|
910
|
-
&& (bHasGrandTotal && !oAggregation["grandTotal like 1.84"]
|
|
911
|
-
|| bHasGroupLevels)) {
|
|
912
|
-
throw new Error("Unsupported system query option: $filter");
|
|
913
|
-
}
|
|
914
|
-
if (mQueryOptions.$search && (bHasGrandTotal || bHasGroupLevels)) {
|
|
915
|
-
throw new Error("Unsupported system query option: $search");
|
|
916
|
-
}
|
|
917
|
-
if (bHasMinOrMax) {
|
|
919
|
+
if (_AggregationHelper.hasMinOrMax(oAggregation.aggregate)) {
|
|
918
920
|
if (bHasGrandTotal) {
|
|
919
921
|
throw new Error("Unsupported grand totals together with min/max");
|
|
920
922
|
}
|
|
921
923
|
if (bHasGroupLevels) {
|
|
922
924
|
throw new Error("Unsupported group levels together with min/max");
|
|
923
925
|
}
|
|
926
|
+
if (oAggregation.hierarchyQualifier) {
|
|
927
|
+
throw new Error("Unsupported recursive hierarchy together with min/max");
|
|
928
|
+
}
|
|
929
|
+
checkExpandSelect();
|
|
930
|
+
|
|
931
|
+
return _MinMaxHelper.createCache(oRequestor, sResourcePath, oAggregation,
|
|
932
|
+
mQueryOptions);
|
|
924
933
|
}
|
|
925
934
|
|
|
926
|
-
if (
|
|
927
|
-
|
|
935
|
+
if (mQueryOptions.$filter
|
|
936
|
+
&& (bHasGrandTotal && !oAggregation["grandTotal like 1.84"]
|
|
937
|
+
|| bHasGroupLevels)) {
|
|
938
|
+
throw new Error("Unsupported system query option: $filter");
|
|
939
|
+
}
|
|
940
|
+
|
|
941
|
+
if (bHasGrandTotal || bHasGroupLevels || oAggregation.hierarchyQualifier) {
|
|
942
|
+
if (mQueryOptions.$search) {
|
|
943
|
+
throw new Error("Unsupported system query option: $search");
|
|
944
|
+
}
|
|
928
945
|
if (!oAggregation.hierarchyQualifier) {
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
throw new Error("Unsupported system query option: $select");
|
|
934
|
-
}
|
|
946
|
+
checkExpandSelect();
|
|
947
|
+
}
|
|
948
|
+
if (bIsGrouped) {
|
|
949
|
+
throw new Error("Unsupported grouping via sorter");
|
|
935
950
|
}
|
|
936
951
|
|
|
937
|
-
return
|
|
938
|
-
? _MinMaxHelper.createCache(oRequestor, sResourcePath, oAggregation,
|
|
939
|
-
mQueryOptions)
|
|
940
|
-
: new _AggregationCache(oRequestor, sResourcePath, oAggregation, mQueryOptions,
|
|
952
|
+
return new _AggregationCache(oRequestor, sResourcePath, oAggregation, mQueryOptions,
|
|
941
953
|
bHasGrandTotal);
|
|
942
954
|
}
|
|
943
955
|
}
|
|
@@ -43,7 +43,8 @@ sap.ui.define([
|
|
|
43
43
|
+ ")(?:" + _Parser.sWhitespace + "+(?:asc|desc))?$"),
|
|
44
44
|
mRecursiveHierarchyType = {
|
|
45
45
|
expandTo : /^[1-9]\d*$/, // a positive integer
|
|
46
|
-
hierarchyQualifier : "string"
|
|
46
|
+
hierarchyQualifier : "string",
|
|
47
|
+
search : "string"
|
|
47
48
|
},
|
|
48
49
|
/**
|
|
49
50
|
* Collection of helper methods for data aggregation.
|
|
@@ -348,9 +349,18 @@ sap.ui.define([
|
|
|
348
349
|
* @param {object} oAggregation
|
|
349
350
|
* An object holding the information needed for a recursive hierarchy; see
|
|
350
351
|
* {@link sap.ui.model.odata.v4.ODataListBinding#setAggregation}.
|
|
352
|
+
* @param {string} [oAggregation.search]
|
|
353
|
+
* Like the value for a "$search" system query option (remember ODATA-1452); it is turned
|
|
354
|
+
* into the search expression parameter of an "ancestors()" transformation
|
|
351
355
|
* @param {object} [mQueryOptions={}]
|
|
352
356
|
* A map of key-value pairs representing the query string; it is not modified
|
|
353
|
-
* @param {
|
|
357
|
+
* @param {string} [mQueryOptions.$filter]
|
|
358
|
+
* The value for a "$filter" system query option; it is removed from the returned map and
|
|
359
|
+
* turned into the filter expression parameter of an "ancestors()" transformation
|
|
360
|
+
* @param {string} [mQueryOptions.$orderby]
|
|
361
|
+
* The value for a "$orderby" system query option; it is removed from the returned map and
|
|
362
|
+
* turned into an "orderby()" transformation
|
|
363
|
+
* @param {string[]} [mQueryOptions.$select]
|
|
354
364
|
* The value for a "$select" system query option; additional technical properties are
|
|
355
365
|
* added to the returned copy
|
|
356
366
|
* @returns {object}
|
|
@@ -361,7 +371,7 @@ sap.ui.define([
|
|
|
361
371
|
* @public
|
|
362
372
|
*/
|
|
363
373
|
buildApply4Hierarchy : function (oAggregation, mQueryOptions) {
|
|
364
|
-
var sApply,
|
|
374
|
+
var sApply = "",
|
|
365
375
|
sHierarchyQualifier = oAggregation.hierarchyQualifier,
|
|
366
376
|
sPath = oAggregation.$path,
|
|
367
377
|
sNodeProperty = mQueryOptions
|
|
@@ -369,7 +379,8 @@ sap.ui.define([
|
|
|
369
379
|
+ "/@Org.OData.Aggregation.V1.RecursiveHierarchy#" + sHierarchyQualifier
|
|
370
380
|
+ "/NodeProperty/$PropertyPath").getResult()
|
|
371
381
|
: "???",
|
|
372
|
-
mRecursiveHierarchy
|
|
382
|
+
mRecursiveHierarchy,
|
|
383
|
+
sSeparator = "";
|
|
373
384
|
|
|
374
385
|
function select(sProperty) {
|
|
375
386
|
if (mQueryOptions.$select) {
|
|
@@ -388,13 +399,36 @@ sap.ui.define([
|
|
|
388
399
|
mQueryOptions.$select = mQueryOptions.$select.slice();
|
|
389
400
|
}
|
|
390
401
|
|
|
402
|
+
if (mQueryOptions.$filter || oAggregation.search) {
|
|
403
|
+
if (mQueryOptions.$filter) {
|
|
404
|
+
sApply = "filter(" + mQueryOptions.$filter;
|
|
405
|
+
sSeparator = ")/";
|
|
406
|
+
delete mQueryOptions.$filter;
|
|
407
|
+
}
|
|
408
|
+
if (oAggregation.search) {
|
|
409
|
+
sApply += sSeparator + "search(" + oAggregation.search;
|
|
410
|
+
}
|
|
411
|
+
sApply = "ancestors($root" + sPath
|
|
412
|
+
+ "," + sHierarchyQualifier
|
|
413
|
+
+ "," + sNodeProperty
|
|
414
|
+
+ "," + sApply
|
|
415
|
+
+ "),keep start)/";
|
|
416
|
+
}
|
|
391
417
|
if (mQueryOptions.$$filterBeforeAggregate) { // children of a given parent
|
|
392
|
-
sApply
|
|
418
|
+
sApply += "descendants($root" + sPath + "," + sHierarchyQualifier
|
|
393
419
|
+ "," + sNodeProperty
|
|
394
420
|
+ ",filter(" + mQueryOptions.$$filterBeforeAggregate + "),1)";
|
|
395
421
|
delete mQueryOptions.$$filterBeforeAggregate;
|
|
422
|
+
if (mQueryOptions.$orderby) {
|
|
423
|
+
sApply += "/orderby(" + mQueryOptions.$orderby + ")";
|
|
424
|
+
delete mQueryOptions.$orderby;
|
|
425
|
+
}
|
|
396
426
|
} else { // top levels of nodes
|
|
397
|
-
|
|
427
|
+
if (mQueryOptions.$orderby) {
|
|
428
|
+
sApply += "orderby(" + mQueryOptions.$orderby + ")/";
|
|
429
|
+
delete mQueryOptions.$orderby;
|
|
430
|
+
}
|
|
431
|
+
sApply += "com.sap.vocabularies.Hierarchy.v1.TopLevels(HierarchyNodes=$root" + sPath
|
|
398
432
|
+ ",HierarchyQualifier='" + sHierarchyQualifier
|
|
399
433
|
+ "',NodeProperty='" + sNodeProperty
|
|
400
434
|
+ "',Levels=" + (oAggregation.expandTo || 1)
|