@openui5/sap.ui.core 1.111.1 → 1.112.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/.dtsgenrc +38 -0
- package/package.json +1 -1
- package/src/jquery.sap.global.js +4 -1
- package/src/jquery.sap.properties.js +1 -1
- package/src/jquery.sap.resources.js +1 -1
- package/src/jquery.sap.script.js +1 -1
- package/src/jquery.sap.storage.js +3 -3
- package/src/sap/base/util/deepClone.js +4 -0
- 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/ui/Device.js +3 -3
- package/src/sap/ui/Global.js +4 -4
- package/src/sap/ui/VersionInfo.js +14 -0
- package/src/sap/ui/base/Event.js +1 -1
- package/src/sap/ui/base/EventProvider.js +1 -1
- package/src/sap/ui/base/Interface.js +1 -1
- package/src/sap/ui/base/ManagedObject.js +1 -1
- package/src/sap/ui/base/ManagedObjectMetadata.js +1 -1
- 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 +4 -4
- package/src/sap/ui/core/BusyIndicator.js +1 -1
- package/src/sap/ui/core/Component.js +3 -3
- package/src/sap/ui/core/ComponentContainer.js +1 -1
- package/src/sap/ui/core/ComponentMetadata.js +1 -1
- package/src/sap/ui/core/ComponentSupport.js +1 -1
- package/src/sap/ui/core/Configuration.js +14 -2
- package/src/sap/ui/core/Control.js +1 -1
- package/src/sap/ui/core/Core.js +17 -8
- 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 +1 -1
- 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/Fragment.js +1 -1
- package/src/sap/ui/core/HTML.js +1 -1
- package/src/sap/ui/core/History.js +1 -1
- package/src/sap/ui/core/Icon.js +1 -1
- package/src/sap/ui/core/IndicationColorSupport.js +1 -1
- package/src/sap/ui/core/IntervalTrigger.js +1 -1
- package/src/sap/ui/core/InvisibleMessage.js +1 -1
- package/src/sap/ui/core/InvisibleRenderer.js +1 -1
- package/src/sap/ui/core/InvisibleText.js +1 -1
- package/src/sap/ui/core/Item.js +1 -1
- package/src/sap/ui/core/LabelEnablement.js +1 -1
- package/src/sap/ui/core/LayoutData.js +1 -1
- package/src/sap/ui/core/Lib.js +40 -28
- package/src/sap/ui/core/ListItem.js +1 -1
- package/src/sap/ui/core/LocalBusyIndicator.js +1 -1
- package/src/sap/ui/core/Locale.js +1 -1
- package/src/sap/ui/core/LocaleData.js +1 -1
- package/src/sap/ui/core/Manifest.js +1 -1
- package/src/sap/ui/core/Message.js +1 -1
- package/src/sap/ui/core/RenderManager.js +1 -1
- package/src/sap/ui/core/Renderer.js +1 -1
- package/src/sap/ui/core/ResizeHandler.js +1 -1
- package/src/sap/ui/core/ScrollBar.js +1 -1
- package/src/sap/ui/core/SeparatorItem.js +1 -1
- package/src/sap/ui/core/Title.js +1 -1
- package/src/sap/ui/core/TooltipBase.js +1 -1
- package/src/sap/ui/core/UIArea.js +1 -1
- package/src/sap/ui/core/UIComponent.js +1 -1
- package/src/sap/ui/core/UIComponentMetadata.js +1 -1
- package/src/sap/ui/core/ValueStateSupport.js +1 -1
- package/src/sap/ui/core/VariantLayoutData.js +1 -1
- package/src/sap/ui/core/XMLComposite.js +1 -1
- package/src/sap/ui/core/XMLCompositeMetadata.js +1 -1
- package/src/sap/ui/core/_IconRegistry.js +19 -4
- package/src/sap/ui/core/date/Islamic.js +1 -0
- package/src/sap/ui/core/date/UI5Date.js +25 -5
- package/src/sap/ui/core/date/UniversalDate.js +2 -0
- package/src/sap/ui/core/date/UniversalDateUtils.js +1 -2
- package/src/sap/ui/core/delegate/ItemNavigation.js +1 -1
- package/src/sap/ui/core/delegate/ScrollEnablement.js +1 -1
- package/src/sap/ui/core/dnd/DragDropBase.js +1 -1
- package/src/sap/ui/core/dnd/DragDropInfo.js +1 -1
- package/src/sap/ui/core/dnd/DragInfo.js +1 -1
- package/src/sap/ui/core/dnd/DropInfo.js +1 -1
- package/src/sap/ui/core/format/DateFormat.js +13 -15
- package/src/sap/ui/core/format/NumberFormat.js +6 -4
- package/src/sap/ui/core/format/TimezoneUtil.js +21 -17
- package/src/sap/ui/core/hyphenation/Hyphenation.js +3 -3
- package/src/sap/ui/core/library.js +3 -3
- 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 +1 -1
- 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/mvc/Controller.js +1 -1
- package/src/sap/ui/core/mvc/ControllerExtension.js +1 -1
- package/src/sap/ui/core/mvc/ControllerMetadata.js +4 -3
- package/src/sap/ui/core/mvc/HTMLView.js +1 -1
- package/src/sap/ui/core/mvc/JSONView.js +1 -1
- package/src/sap/ui/core/mvc/JSView.js +1 -1
- package/src/sap/ui/core/mvc/TemplateView.js +1 -1
- package/src/sap/ui/core/mvc/View.js +13 -9
- package/src/sap/ui/core/mvc/XMLView.js +1 -1
- 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/search/OpenSearchProvider.js +1 -1
- package/src/sap/ui/core/search/SearchProvider.js +1 -1
- 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/Plugin.js +1 -1
- package/src/sap/ui/core/support/Support.js +1 -1
- package/src/sap/ui/core/support/plugins/ControlTree.js +1 -1
- 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 +1 -1
- package/src/sap/ui/core/themes/base/fonts/SAP-icons.ttf +0 -0
- package/src/sap/ui/core/themes/base/fonts/SAP-icons.woff2 +0 -0
- package/src/sap/ui/core/theming/ThemeManager.js +11 -2
- package/src/sap/ui/core/tmpl/DOMAttribute.js +1 -1
- package/src/sap/ui/core/tmpl/DOMElement.js +1 -1
- package/src/sap/ui/core/tmpl/HandlebarsTemplate.js +1 -1
- package/src/sap/ui/core/tmpl/Template.js +1 -1
- package/src/sap/ui/core/tmpl/TemplateControl.js +1 -1
- 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 +1 -1
- package/src/sap/ui/core/util/PasteHelper.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 +3 -3
- 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 +2 -2
- package/src/sap/ui/debug/ControlTree.js +1 -1
- package/src/sap/ui/debug/DebugEnv.js +1 -1
- package/src/sap/ui/debug/PropertyList.js +1 -1
- package/src/sap/ui/model/ClientModel.js +1 -1
- package/src/sap/ui/model/CompositeDataState.js +1 -1
- package/src/sap/ui/model/CompositeType.js +1 -1
- package/src/sap/ui/model/DataState.js +1 -1
- package/src/sap/ui/model/MetaModel.js +1 -1
- package/src/sap/ui/model/Model.js +1 -1
- package/src/sap/ui/model/SelectionModel.js +1 -1
- package/src/sap/ui/model/SimpleType.js +1 -1
- package/src/sap/ui/model/TreeAutoExpandMode.js +1 -1
- package/src/sap/ui/model/Type.js +1 -1
- package/src/sap/ui/model/json/JSONModel.js +1 -1
- package/src/sap/ui/model/message/MessageModel.js +1 -1
- package/src/sap/ui/model/odata/ODataAnnotations.js +1 -1
- package/src/sap/ui/model/odata/ODataMessageParser.js +1 -1
- package/src/sap/ui/model/odata/ODataMetaModel.js +4 -3
- package/src/sap/ui/model/odata/ODataMetadata.js +1 -1
- package/src/sap/ui/model/odata/ODataModel.js +1 -1
- package/src/sap/ui/model/odata/ODataUtils.js +5 -2
- package/src/sap/ui/model/odata/_ODataMetaModelUtils.js +62 -24
- 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 +3 -2
- package/src/sap/ui/model/odata/type/DateTimeOffset.js +1 -1
- package/src/sap/ui/model/odata/type/DateTimeWithTimezone.js +2 -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 +2 -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 +1 -1
- package/src/sap/ui/model/odata/v2/ODataAnnotations.js +2 -1
- package/src/sap/ui/model/odata/v2/ODataListBinding.js +4 -1
- package/src/sap/ui/model/odata/v2/ODataModel.js +131 -66
- package/src/sap/ui/model/odata/v2/ODataTreeBinding.js +1 -1
- package/src/sap/ui/model/odata/v4/Context.js +50 -14
- package/src/sap/ui/model/odata/v4/ODataBinding.js +83 -14
- package/src/sap/ui/model/odata/v4/ODataContextBinding.js +2 -4
- package/src/sap/ui/model/odata/v4/ODataListBinding.js +89 -12
- package/src/sap/ui/model/odata/v4/ODataMetaModel.js +3 -2
- package/src/sap/ui/model/odata/v4/ODataModel.js +5 -4
- package/src/sap/ui/model/odata/v4/ODataParentBinding.js +14 -3
- package/src/sap/ui/model/odata/v4/ODataPropertyBinding.js +9 -1
- package/src/sap/ui/model/odata/v4/lib/_AggregationCache.js +63 -62
- package/src/sap/ui/model/odata/v4/lib/_AggregationHelper.js +32 -7
- package/src/sap/ui/model/odata/v4/lib/_Cache.js +210 -10
- package/src/sap/ui/model/odata/v4/lib/_Helper.js +71 -29
- package/src/sap/ui/model/resource/ResourceModel.js +1 -1
- package/src/sap/ui/model/type/Boolean.js +1 -1
- package/src/sap/ui/model/type/Currency.js +1 -1
- package/src/sap/ui/model/type/Date.js +4 -3
- package/src/sap/ui/model/type/DateInterval.js +9 -8
- 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 +1 -1
- 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 +1 -1
- package/src/sap/ui/model/xml/XMLModel.js +1 -1
- package/src/sap/ui/qunit/QUnitUtils.js +6 -4
- 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/Opa5.js +4 -4
- package/src/sap/ui/test/generic/TestBase.js +14 -4
- package/src/sap/ui/thirdparty/jquery-mobile-custom.js +10 -4
- package/src/sap/ui/thirdparty/qunit-2.js +4 -1
- package/src/sap/ui/thirdparty/qunit.js +41 -11
- package/src/sap/ui/util/Storage.js +1 -1
|
@@ -33,7 +33,7 @@ sap.ui.define('sap/ui/debug/ControlTree', [
|
|
|
33
33
|
* @class Control Tree used for the Debug Environment
|
|
34
34
|
* @extends sap.ui.base.EventProvider
|
|
35
35
|
* @author Martin Schaus, Frank Weigel
|
|
36
|
-
* @version 1.
|
|
36
|
+
* @version 1.112.0
|
|
37
37
|
* @alias sap.ui.debug.ControlTree
|
|
38
38
|
* @private
|
|
39
39
|
*/
|
|
@@ -16,7 +16,7 @@ sap.ui.define('sap/ui/debug/DebugEnv', ['sap/ui/base/Interface', './ControlTree'
|
|
|
16
16
|
* @class Central Class for the Debug Environment
|
|
17
17
|
*
|
|
18
18
|
* @author Martin Schaus, Frank Weigel
|
|
19
|
-
* @version 1.
|
|
19
|
+
* @version 1.112.0
|
|
20
20
|
* @private
|
|
21
21
|
* @alias sap.ui.debug.DebugEnv
|
|
22
22
|
*/
|
|
@@ -39,7 +39,7 @@ sap.ui.define(['./SimpleType'],
|
|
|
39
39
|
* <code>true</code>.
|
|
40
40
|
* @extends sap.ui.model.SimpleType
|
|
41
41
|
* @public
|
|
42
|
-
* @version 1.
|
|
42
|
+
* @version 1.112.0
|
|
43
43
|
*/
|
|
44
44
|
var CompositeType = SimpleType.extend("sap.ui.model.CompositeType", /** @lends sap.ui.model.CompositeType.prototype */ {
|
|
45
45
|
|
|
@@ -20,7 +20,7 @@ sap.ui.define(['sap/ui/base/EventProvider', "sap/base/assert"],
|
|
|
20
20
|
* @extends sap.ui.base.EventProvider
|
|
21
21
|
*
|
|
22
22
|
* @author SAP SE
|
|
23
|
-
* @version 1.
|
|
23
|
+
* @version 1.112.0
|
|
24
24
|
*
|
|
25
25
|
* @param {int} iSelectionMode <code>sap.ui.model.SelectionModel.SINGLE_SELECTION</code> or <code>sap.ui.model.SelectionModel.MULTI_SELECTION</code>
|
|
26
26
|
*
|
package/src/sap/ui/model/Type.js
CHANGED
|
@@ -29,7 +29,7 @@ sap.ui.define(['sap/ui/model/BindingMode', 'sap/ui/model/ClientModel', 'sap/ui/m
|
|
|
29
29
|
* @extends sap.ui.model.ClientModel
|
|
30
30
|
*
|
|
31
31
|
* @author SAP SE
|
|
32
|
-
* @version 1.
|
|
32
|
+
* @version 1.112.0
|
|
33
33
|
*
|
|
34
34
|
* @param {sap.ui.core.message.MessageManager} oMessageManager The MessageManager instance
|
|
35
35
|
* @public
|
|
@@ -209,7 +209,7 @@ sap.ui.define([
|
|
|
209
209
|
* {@link #loaded loaded} has been resolved!
|
|
210
210
|
*
|
|
211
211
|
* @author SAP SE
|
|
212
|
-
* @version 1.
|
|
212
|
+
* @version 1.112.0
|
|
213
213
|
* @alias sap.ui.model.odata.ODataMetaModel
|
|
214
214
|
* @extends sap.ui.model.MetaModel
|
|
215
215
|
* @public
|
|
@@ -230,7 +230,8 @@ sap.ui.define([
|
|
|
230
230
|
oData = JSON.parse(JSON.stringify(oMetadata.getServiceMetadata()));
|
|
231
231
|
that.oModel = new JSONModel(oData);
|
|
232
232
|
that.oModel.setDefaultBindingMode(that.sDefaultBindingMode);
|
|
233
|
-
Utils.merge(oAnnotations ? oAnnotations.getData() : {}, oData, that
|
|
233
|
+
Utils.merge(oAnnotations ? oAnnotations.getData() : {}, oData, that,
|
|
234
|
+
oDataModel.bIgnoreAnnotationsFromMetadata);
|
|
234
235
|
Measurement.end(sPerformanceLoad);
|
|
235
236
|
}
|
|
236
237
|
|
|
@@ -242,7 +243,7 @@ sap.ui.define([
|
|
|
242
243
|
this.sDefaultBindingMode = BindingMode.OneTime;
|
|
243
244
|
this.oLoadedPromise = oAnnotationsLoadedPromise
|
|
244
245
|
? oAnnotationsLoadedPromise.then(load)
|
|
245
|
-
: new Promise(function (fnResolve
|
|
246
|
+
: new Promise(function (fnResolve) {
|
|
246
247
|
load();
|
|
247
248
|
fnResolve();
|
|
248
249
|
}); // call load() synchronously!
|
|
@@ -265,7 +265,7 @@ sap.ui.define([
|
|
|
265
265
|
* @param {string} vParameters.alias the system alias which will be used as the origin
|
|
266
266
|
* @param {string} vParameters.system the system id which will be used as the origin
|
|
267
267
|
* @param {string} vParameters.client the system's client
|
|
268
|
-
* @param {
|
|
268
|
+
* @param {boolean} vParameters.force setting this flag to <code>true</code> overrides the already existing origin
|
|
269
269
|
*
|
|
270
270
|
* @public
|
|
271
271
|
* @since 1.30.7
|
|
@@ -533,12 +533,14 @@ sap.ui.define([
|
|
|
533
533
|
break;
|
|
534
534
|
case "Edm.Time":
|
|
535
535
|
if (typeof vValue === "object") {
|
|
536
|
+
// no need to use UI5Date.getInstance as only the UTC timestamp is used
|
|
536
537
|
sValue = oTimeFormat.format(new Date(vValue.ms), true);
|
|
537
538
|
} else {
|
|
538
539
|
sValue = "time'" + vValue + "'";
|
|
539
540
|
}
|
|
540
541
|
break;
|
|
541
542
|
case "Edm.DateTime":
|
|
543
|
+
// no need to use UI5Date.getInstance as only the UTC timestamp is used
|
|
542
544
|
oDate = vValue instanceof Date ? vValue : new Date(vValue);
|
|
543
545
|
if (oDate.getMilliseconds() > 0) {
|
|
544
546
|
sValue = oDateTimeFormatMs.format(oDate, true);
|
|
@@ -547,6 +549,7 @@ sap.ui.define([
|
|
|
547
549
|
}
|
|
548
550
|
break;
|
|
549
551
|
case "Edm.DateTimeOffset":
|
|
552
|
+
// no need to use UI5Date.getInstance as only the UTC timestamp is used
|
|
550
553
|
oDate = vValue instanceof Date ? vValue : new Date(vValue);
|
|
551
554
|
sValue = oDateTimeOffsetFormat.format(oDate, true);
|
|
552
555
|
break;
|
|
@@ -742,7 +745,7 @@ sap.ui.define([
|
|
|
742
745
|
* the first value to compare
|
|
743
746
|
* @param {any} vValue2
|
|
744
747
|
* the second value to compare
|
|
745
|
-
* @param {
|
|
748
|
+
* @param {boolean} [bAsDecimal=false]
|
|
746
749
|
* if <code>true</code>, the string values <code>vValue1</code> and <code>vValue2</code> are
|
|
747
750
|
* compared as a decimal number (only sign, integer and fraction digits; no exponential
|
|
748
751
|
* format). Otherwise they are recognized by looking at their types.
|
|
@@ -911,8 +911,10 @@ sap.ui.define([
|
|
|
911
911
|
* @param {string} sTypeClass
|
|
912
912
|
* the type class of the given object; supported type classes are "Property" and
|
|
913
913
|
* "EntitySet"
|
|
914
|
+
* @param {boolean} [bIgnoreAnnotationsFromMetadata]
|
|
915
|
+
* whether annotations from metadata are ignored, so that no V4 annotations are created for them
|
|
914
916
|
*/
|
|
915
|
-
liftSAPData : function (o, sTypeClass) {
|
|
917
|
+
liftSAPData : function (o, sTypeClass, bIgnoreAnnotationsFromMetadata) {
|
|
916
918
|
if (!o.extensions) {
|
|
917
919
|
return;
|
|
918
920
|
}
|
|
@@ -920,9 +922,15 @@ sap.ui.define([
|
|
|
920
922
|
o.extensions.forEach(function (oExtension) {
|
|
921
923
|
if (oExtension.namespace === "http://www.sap.com/Protocols/SAPData") {
|
|
922
924
|
o["sap:" + oExtension.name] = oExtension.value;
|
|
923
|
-
|
|
925
|
+
if (!bIgnoreAnnotationsFromMetadata) {
|
|
926
|
+
Utils.addV4Annotation(o, oExtension, sTypeClass);
|
|
927
|
+
}
|
|
924
928
|
}
|
|
925
929
|
});
|
|
930
|
+
if (bIgnoreAnnotationsFromMetadata) {
|
|
931
|
+
return;
|
|
932
|
+
}
|
|
933
|
+
|
|
926
934
|
// after all SAP V2 annotations are lifted up add V4 annotations that are calculated
|
|
927
935
|
// by multiple V2 annotations or that have a different default value
|
|
928
936
|
switch (sTypeClass) {
|
|
@@ -955,8 +963,10 @@ sap.ui.define([
|
|
|
955
963
|
* metadata "JSON"
|
|
956
964
|
* @param {sap.ui.model.odata.ODataMetaModel} oMetaModel
|
|
957
965
|
* the metamodel
|
|
966
|
+
* @param {boolean} [bIgnoreAnnotationsFromMetadata]
|
|
967
|
+
* whether annotations from metadata are ignored, so that no V4 annotations are created for them
|
|
958
968
|
*/
|
|
959
|
-
merge : function (oAnnotations, oData, oMetaModel) {
|
|
969
|
+
merge : function (oAnnotations, oData, oMetaModel, bIgnoreAnnotationsFromMetadata) {
|
|
960
970
|
var aSchemas = oData.dataServices.schema;
|
|
961
971
|
|
|
962
972
|
if (!aSchemas) {
|
|
@@ -968,10 +978,10 @@ sap.ui.define([
|
|
|
968
978
|
// remove datajs artefact for inline annotations in $metadata
|
|
969
979
|
delete oSchema.annotations;
|
|
970
980
|
|
|
971
|
-
Utils.liftSAPData(oSchema);
|
|
981
|
+
Utils.liftSAPData(oSchema, bIgnoreAnnotationsFromMetadata);
|
|
972
982
|
oSchema.$path = "/dataServices/schema/" + i;
|
|
973
983
|
sSchemaVersion = oSchema["sap:schema-version"];
|
|
974
|
-
if (sSchemaVersion) {
|
|
984
|
+
if (sSchemaVersion && !bIgnoreAnnotationsFromMetadata) {
|
|
975
985
|
oSchema["Org.Odata.Core.V1.SchemaVersion"] = {
|
|
976
986
|
String : sSchemaVersion
|
|
977
987
|
};
|
|
@@ -980,34 +990,46 @@ sap.ui.define([
|
|
|
980
990
|
|
|
981
991
|
Utils.visitParents(oSchema, oAnnotations, "association",
|
|
982
992
|
function (oAssociation, mChildAnnotations) {
|
|
993
|
+
// as per https://www.sap.com/Protocols/SAPData there are no sap: annotations for assocation
|
|
994
|
+
// => parameter bIgnoreAnnotationsFromMetadata is irrelevant
|
|
983
995
|
Utils.visitChildren(oAssociation.end, mChildAnnotations);
|
|
984
996
|
});
|
|
985
997
|
|
|
986
998
|
Utils.visitParents(oSchema, oAnnotations, "complexType",
|
|
987
999
|
function (oComplexType, mChildAnnotations) {
|
|
988
|
-
Utils.visitChildren(oComplexType.property, mChildAnnotations, "Property"
|
|
989
|
-
|
|
1000
|
+
Utils.visitChildren(oComplexType.property, mChildAnnotations, "Property",
|
|
1001
|
+
/*aSchemas*/undefined, /*fnCallback*/undefined, /*iStartIndex*/undefined,
|
|
1002
|
+
bIgnoreAnnotationsFromMetadata);
|
|
1003
|
+
if (!bIgnoreAnnotationsFromMetadata) {
|
|
1004
|
+
Utils.addSapSemantics(oComplexType);
|
|
1005
|
+
}
|
|
990
1006
|
});
|
|
991
1007
|
|
|
992
1008
|
// visit all entity types before visiting the entity sets to ensure that V2
|
|
993
1009
|
// annotations are already lifted up and can be used for calculating entity
|
|
994
1010
|
// set annotations which are based on V2 annotations on entity properties
|
|
995
|
-
Utils.visitParents(oSchema, oAnnotations, "entityType", Utils.visitEntityType
|
|
1011
|
+
Utils.visitParents(oSchema, oAnnotations, "entityType", Utils.visitEntityType,
|
|
1012
|
+
/*iIndex*/ undefined, bIgnoreAnnotationsFromMetadata);
|
|
996
1013
|
});
|
|
997
1014
|
|
|
998
1015
|
aSchemas.forEach(function (oSchema) {
|
|
999
1016
|
// visit entity container after all entity types of all schemas are visited
|
|
1000
1017
|
Utils.visitParents(oSchema, oAnnotations, "entityContainer",
|
|
1001
1018
|
function (oEntityContainer, mChildAnnotations) {
|
|
1019
|
+
// for association sets, visitChildren does not create V4-annotations
|
|
1020
|
+
// => parameter bIgnoreAnnotationsFromMetadata is irrelevant
|
|
1002
1021
|
Utils.visitChildren(oEntityContainer.associationSet, mChildAnnotations);
|
|
1003
1022
|
Utils.visitChildren(oEntityContainer.entitySet, mChildAnnotations,
|
|
1004
|
-
"EntitySet", aSchemas
|
|
1023
|
+
"EntitySet", aSchemas, /*fnCallback*/undefined, /*iStartIndex*/undefined,
|
|
1024
|
+
bIgnoreAnnotationsFromMetadata);
|
|
1005
1025
|
Utils.visitChildren(oEntityContainer.functionImport, mChildAnnotations,
|
|
1006
|
-
"", null, Utils.visitParameters.bind(this,
|
|
1007
|
-
|
|
1026
|
+
"", null, Utils.visitParameters.bind(this, oAnnotations, oSchema, oEntityContainer),
|
|
1027
|
+
/*iStartIndex*/undefined, bIgnoreAnnotationsFromMetadata);
|
|
1008
1028
|
});
|
|
1009
1029
|
});
|
|
1010
|
-
|
|
1030
|
+
if (!bIgnoreAnnotationsFromMetadata) {
|
|
1031
|
+
Utils.addUnitAnnotations(aSchemas, oMetaModel);
|
|
1032
|
+
}
|
|
1011
1033
|
},
|
|
1012
1034
|
|
|
1013
1035
|
/**
|
|
@@ -1027,9 +1049,11 @@ sap.ui.define([
|
|
|
1027
1049
|
* optional callback for each child
|
|
1028
1050
|
* @param {number} [iStartIndex=0]
|
|
1029
1051
|
* optional start index in the given array
|
|
1052
|
+
* @param {boolean} [bIgnoreAnnotationsFromMetadata]
|
|
1053
|
+
* whether annotations from metadata are ignored, so that no V4 annotations are created for them
|
|
1030
1054
|
*/
|
|
1031
1055
|
visitChildren : function (aChildren, mChildAnnotations, sTypeClass, aSchemas, fnCallback,
|
|
1032
|
-
iStartIndex) {
|
|
1056
|
+
iStartIndex, bIgnoreAnnotationsFromMetadata) {
|
|
1033
1057
|
if (!aChildren) {
|
|
1034
1058
|
return;
|
|
1035
1059
|
}
|
|
@@ -1038,12 +1062,12 @@ sap.ui.define([
|
|
|
1038
1062
|
}
|
|
1039
1063
|
aChildren.forEach(function (oChild) {
|
|
1040
1064
|
// lift SAP data for easy access to SAP Annotations for OData V 2.0
|
|
1041
|
-
Utils.liftSAPData(oChild, sTypeClass);
|
|
1065
|
+
Utils.liftSAPData(oChild, sTypeClass, bIgnoreAnnotationsFromMetadata);
|
|
1042
1066
|
});
|
|
1043
1067
|
aChildren.forEach(function (oChild) {
|
|
1044
1068
|
var oEntityType;
|
|
1045
1069
|
|
|
1046
|
-
if (sTypeClass === "EntitySet") {
|
|
1070
|
+
if (sTypeClass === "EntitySet" && !bIgnoreAnnotationsFromMetadata) {
|
|
1047
1071
|
// calculated entity set annotations need to be added before V4
|
|
1048
1072
|
// annotations are merged
|
|
1049
1073
|
oEntityType = Utils.getObject(aSchemas, "entityType", oChild.entityType);
|
|
@@ -1051,7 +1075,7 @@ sap.ui.define([
|
|
|
1051
1075
|
}
|
|
1052
1076
|
|
|
1053
1077
|
if (fnCallback) {
|
|
1054
|
-
fnCallback(oChild);
|
|
1078
|
+
fnCallback(oChild, bIgnoreAnnotationsFromMetadata);
|
|
1055
1079
|
}
|
|
1056
1080
|
// merge V4 annotations after child annotations are processed
|
|
1057
1081
|
extend(oChild, mChildAnnotations[oChild.name || oChild.role]);
|
|
@@ -1065,11 +1089,19 @@ sap.ui.define([
|
|
|
1065
1089
|
* the entity type
|
|
1066
1090
|
* @param {object} mChildAnnotations
|
|
1067
1091
|
* map from child name (or role) to annotations
|
|
1092
|
+
* @param {boolean} [bIgnoreAnnotationsFromMetadata]
|
|
1093
|
+
* whether annotations from metadata are ignored, so that no V4 annotations are created for them
|
|
1068
1094
|
*/
|
|
1069
|
-
visitEntityType : function (oEntityType, mChildAnnotations) {
|
|
1070
|
-
Utils.visitChildren(oEntityType.property, mChildAnnotations, "Property"
|
|
1095
|
+
visitEntityType : function (oEntityType, mChildAnnotations, bIgnoreAnnotationsFromMetadata) {
|
|
1096
|
+
Utils.visitChildren(oEntityType.property, mChildAnnotations, "Property",
|
|
1097
|
+
/*aSchemas*/undefined, /*fnCallback*/undefined, /*iStartIndex*/undefined,
|
|
1098
|
+
bIgnoreAnnotationsFromMetadata);
|
|
1099
|
+
// for navigation properties, visitChildren does not create V4-annotations
|
|
1100
|
+
// => parameter bIgnoreAnnotationsFromMetadata is irrelevant
|
|
1071
1101
|
Utils.visitChildren(oEntityType.navigationProperty, mChildAnnotations);
|
|
1072
|
-
|
|
1102
|
+
if (!bIgnoreAnnotationsFromMetadata) {
|
|
1103
|
+
Utils.addSapSemantics(oEntityType);
|
|
1104
|
+
}
|
|
1073
1105
|
},
|
|
1074
1106
|
|
|
1075
1107
|
/**
|
|
@@ -1083,8 +1115,11 @@ sap.ui.define([
|
|
|
1083
1115
|
* the entity container
|
|
1084
1116
|
* @param {object} oFunctionImport
|
|
1085
1117
|
* a function import's V2 metadata object
|
|
1118
|
+
* @param {boolean} [bIgnoreAnnotationsFromMetadata]
|
|
1119
|
+
* whether annotations from metadata are ignored, so that no V4 annotations are created for them
|
|
1086
1120
|
*/
|
|
1087
|
-
visitParameters : function (oAnnotations, oSchema, oEntityContainer, oFunctionImport
|
|
1121
|
+
visitParameters : function (oAnnotations, oSchema, oEntityContainer, oFunctionImport,
|
|
1122
|
+
bIgnoreAnnotationsFromMetadata) {
|
|
1088
1123
|
var mAnnotations;
|
|
1089
1124
|
|
|
1090
1125
|
if (!oFunctionImport.parameter) {
|
|
@@ -1094,7 +1129,7 @@ sap.ui.define([
|
|
|
1094
1129
|
oSchema.namespace + "." + oEntityContainer.name, true);
|
|
1095
1130
|
oFunctionImport.parameter.forEach(
|
|
1096
1131
|
function (oParam) {
|
|
1097
|
-
Utils.liftSAPData(oParam);
|
|
1132
|
+
Utils.liftSAPData(oParam, /*sTypeClass*/undefined, bIgnoreAnnotationsFromMetadata);
|
|
1098
1133
|
extend(oParam, mAnnotations[oFunctionImport.name + "/" + oParam.name]);
|
|
1099
1134
|
}
|
|
1100
1135
|
);
|
|
@@ -1115,8 +1150,11 @@ sap.ui.define([
|
|
|
1115
1150
|
* mandatory callback for each parent, child annotations are passed in
|
|
1116
1151
|
* @param {number} [iIndex]
|
|
1117
1152
|
* optional index of a single parent to visit; default is to visit all
|
|
1153
|
+
* @param {boolean} [bIgnoreAnnotationsFromMetadata]
|
|
1154
|
+
* whether annotations from metadata are ignored, so that no V4 annotations are created for them
|
|
1118
1155
|
*/
|
|
1119
|
-
visitParents : function (oSchema, oAnnotations, sArrayName, fnCallback, iIndex
|
|
1156
|
+
visitParents : function (oSchema, oAnnotations, sArrayName, fnCallback, iIndex,
|
|
1157
|
+
bIgnoreAnnotationsFromMetadata) {
|
|
1120
1158
|
var aParents = oSchema[sArrayName];
|
|
1121
1159
|
|
|
1122
1160
|
function visitParent(oParent, j) {
|
|
@@ -1124,12 +1162,12 @@ sap.ui.define([
|
|
|
1124
1162
|
mChildAnnotations = Utils.getChildAnnotations(oAnnotations, sQualifiedName,
|
|
1125
1163
|
sArrayName === "entityContainer");
|
|
1126
1164
|
|
|
1127
|
-
Utils.liftSAPData(oParent);
|
|
1165
|
+
Utils.liftSAPData(oParent, /*sTypeClass*/undefined, bIgnoreAnnotationsFromMetadata);
|
|
1128
1166
|
// @see sap.ui.model.odata.ODataMetadata#_getEntityTypeByName
|
|
1129
1167
|
oParent.namespace = oSchema.namespace;
|
|
1130
1168
|
oParent.$path = oSchema.$path + "/" + sArrayName + "/" + j;
|
|
1131
1169
|
|
|
1132
|
-
fnCallback(oParent, mChildAnnotations);
|
|
1170
|
+
fnCallback(oParent, mChildAnnotations, bIgnoreAnnotationsFromMetadata);
|
|
1133
1171
|
// merge V4 annotations after child annotations are processed
|
|
1134
1172
|
extend(oParent, oAnnotations[sQualifiedName]);
|
|
1135
1173
|
}
|
|
@@ -65,7 +65,7 @@ sap.ui.define([
|
|
|
65
65
|
* @extends sap.ui.model.type.Currency
|
|
66
66
|
* @public
|
|
67
67
|
* @since 1.63.0
|
|
68
|
-
* @version 1.
|
|
68
|
+
* @version 1.112.0
|
|
69
69
|
*/
|
|
70
70
|
var Currency = BaseCurrency.extend("sap.ui.model.odata.type.Currency", {
|
|
71
71
|
constructor : function (oFormatOptions, oConstraints) {
|
|
@@ -115,7 +115,7 @@ sap.ui.define([
|
|
|
115
115
|
* @extends sap.ui.model.odata.type.ODataType
|
|
116
116
|
* @public
|
|
117
117
|
* @since 1.27.0
|
|
118
|
-
* @version 1.
|
|
118
|
+
* @version 1.112.0
|
|
119
119
|
*/
|
|
120
120
|
var DateTimeBase = ODataType.extend("sap.ui.model.odata.type.DateTimeBase", {
|
|
121
121
|
constructor : function (oFormatOptions, oConstraints) {
|
|
@@ -179,7 +179,8 @@ sap.ui.define([
|
|
|
179
179
|
DateTimeBase.prototype._getErrorMessage = function () {
|
|
180
180
|
var iFullYear = UI5Date.getInstance().getFullYear(),
|
|
181
181
|
oDate = isDateOnly(this)
|
|
182
|
-
|
|
182
|
+
// no need to use UI5Date.getInstance as only the UTC timestamp is used
|
|
183
|
+
? new Date(Date.UTC(iFullYear, 11, 31))
|
|
183
184
|
: UI5Date.getInstance(iFullYear, 11, 31, 23, 59, 58), // configured time zone
|
|
184
185
|
sText = isDateOnly(this) ? "EnterDate" : "EnterDateTime",
|
|
185
186
|
oResourceBundle = sap.ui.getCore().getLibraryResourceBundle();
|
|
@@ -60,7 +60,7 @@ sap.ui.define([
|
|
|
60
60
|
* @public
|
|
61
61
|
* @see {sap.ui.model.odata.v2.ODataModel#bindProperty}
|
|
62
62
|
* @since 1.99.0
|
|
63
|
-
* @version 1.
|
|
63
|
+
* @version 1.112.0
|
|
64
64
|
*/
|
|
65
65
|
var DateTimeWithTimezone = CompositeType.extend("sap.ui.model.odata.type.DateTimeWithTimezone",
|
|
66
66
|
{
|
|
@@ -100,6 +100,7 @@ sap.ui.define([
|
|
|
100
100
|
* @private
|
|
101
101
|
*/
|
|
102
102
|
DateTimeWithTimezone.prototype._getErrorMessage = function () {
|
|
103
|
+
// no need to use UI5Date.getInstance as only the UTC timestamp is used
|
|
103
104
|
var oDemoDateTime = new Date(Date.UTC(UI5Date.getInstance().getFullYear(), 11, 31, 23, 59, 58)),
|
|
104
105
|
sMessageKey = !this.bShowDate && !this.bShowTime
|
|
105
106
|
? "EnterDateTimeTimezone"
|