@openui5/sap.ui.fl 1.138.0 → 1.140.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/README.md +1 -1
- package/REUSE.toml +8 -1
- package/THIRDPARTY.txt +72 -66
- package/package.json +4 -4
- package/src/sap/ui/fl/.library +1 -1
- package/src/sap/ui/fl/FakeLrepConnectorLocalStorage.js +1 -1
- package/src/sap/ui/fl/FakeLrepConnectorSessionStorage.js +1 -1
- package/src/sap/ui/fl/FakeLrepLocalStorage.js +1 -1
- package/src/sap/ui/fl/LayerUtils.js +1 -1
- package/src/sap/ui/fl/Utils.js +1 -1
- package/src/sap/ui/fl/apply/_internal/DelegateMediator.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/FlexCustomData.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/Utils.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/Preprocessor.js +6 -6
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/Registration.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/RegistrationBuild.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/AddAnnotationsToOData.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/AddNewDataSource.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/AddNewInbound.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/AddNewOutbound.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/AddTechnicalAttributes.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/ChangeDataSource.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/ChangeInbound.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/ChangeOutbound.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/RemoveAllInboundsExceptOne.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/SetAch.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/SetDescription.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/app/SetTitle.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/fiori/SetAbstract.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/fiori/SetCloudDevAdaptationStatus.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/fiori/SetRegistrationIds.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ovp/AddNewCard.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ovp/ChangeCard.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ovp/DeleteCard.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/AddComponentUsages.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/AddLibrary.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/AddNewModel.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/AddNewModelEnhanceWith.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/ChangeModel.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/SetFlexExtensionPointEnabled.js +1 -1
- package/src/sap/ui/fl/apply/_internal/changes/descriptor/ui5/SetMinUI5Version.js +1 -1
- package/src/sap/ui/fl/apply/_internal/connectors/ObjectStorageUtils.js +1 -1
- package/src/sap/ui/fl/apply/_internal/controlVariants/URLHandler.js +25 -24
- package/src/sap/ui/fl/apply/_internal/extensionPoint/Processor.js +2 -2
- package/src/sap/ui/fl/apply/_internal/extensionPoint/Registry.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/AnnotationChange.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/AppDescriptorChange.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/CompVariant.js +13 -10
- package/src/sap/ui/fl/apply/_internal/flexObjects/ControllerExtensionChange.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/FlVariant.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/FlexObject.js +2 -2
- package/src/sap/ui/fl/apply/_internal/flexObjects/FlexObjectFactory.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/UIChange.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/Variant.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/VariantChange.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/VariantManagementChange.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexObjects/getVariantAuthor.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexState/DataSelector.js +3 -3
- package/src/sap/ui/fl/apply/_internal/flexState/FlexObjectState.js +12 -26
- package/src/sap/ui/fl/apply/_internal/flexState/FlexState.js +58 -114
- package/src/sap/ui/fl/apply/_internal/flexState/UI2Personalization/UI2PersonalizationState.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexState/changes/DependencyHandler.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexState/changes/ExtensionPointState.js +3 -3
- package/src/sap/ui/fl/apply/_internal/flexState/changes/UIChangesState.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexState/communication/FLPAboutInfo.js +2 -2
- package/src/sap/ui/fl/apply/_internal/flexState/compVariants/CompVariantManagementState.js +290 -10
- package/src/sap/ui/fl/apply/_internal/flexState/compVariants/applyChangesOnVariant.js +61 -0
- package/src/sap/ui/fl/apply/_internal/flexState/controlVariants/Switcher.js +1 -1
- package/src/sap/ui/fl/apply/_internal/flexState/controlVariants/VariantManagementState.js +22 -9
- package/src/sap/ui/fl/apply/_internal/preprocessors/ComponentLifecycleHooks.js +5 -4
- package/src/sap/ui/fl/apply/_internal/preprocessors/ControllerExtension.js +2 -2
- package/src/sap/ui/fl/apply/_internal/preprocessors/RegistrationDelegator.js +3 -3
- package/src/sap/ui/fl/apply/_internal/preprocessors/XmlPreprocessor.js +2 -2
- package/src/sap/ui/fl/apply/api/ControlVariantApplyAPI.js +1 -1
- package/src/sap/ui/fl/apply/api/FlexRuntimeInfoAPI.js +4 -4
- package/src/sap/ui/fl/apply/api/SmartVariantManagementApplyAPI.js +43 -44
- package/src/sap/ui/fl/apply/api/UI2PersonalizationApplyAPI.js +1 -1
- package/src/sap/ui/fl/changeHandler/AddIFrame.js +1 -1
- package/src/sap/ui/fl/changeHandler/AddXML.js +1 -1
- package/src/sap/ui/fl/changeHandler/AddXMLAtExtensionPoint.js +1 -1
- package/src/sap/ui/fl/changeHandler/Base.js +1 -1
- package/src/sap/ui/fl/changeHandler/BaseAddViaDelegate.js +1 -1
- package/src/sap/ui/fl/changeHandler/BaseAddXml.js +1 -1
- package/src/sap/ui/fl/changeHandler/BaseRename.js +1 -1
- package/src/sap/ui/fl/changeHandler/ChangeAnnotation.js +1 -1
- package/src/sap/ui/fl/changeHandler/HideControl.js +1 -1
- package/src/sap/ui/fl/changeHandler/MoveControls.js +1 -1
- package/src/sap/ui/fl/changeHandler/MoveElements.js +1 -1
- package/src/sap/ui/fl/changeHandler/PropertyBindingChange.js +1 -1
- package/src/sap/ui/fl/changeHandler/PropertyChange.js +1 -1
- package/src/sap/ui/fl/changeHandler/StashControl.js +1 -1
- package/src/sap/ui/fl/changeHandler/UnhideControl.js +1 -1
- package/src/sap/ui/fl/changeHandler/UnstashControl.js +1 -1
- package/src/sap/ui/fl/changeHandler/UpdateIFrame.js +1 -1
- package/src/sap/ui/fl/descriptorRelated/api/DescriptorChange.js +3 -3
- package/src/sap/ui/fl/descriptorRelated/api/DescriptorChangeFactory.js +3 -3
- package/src/sap/ui/fl/descriptorRelated/api/DescriptorInlineChangeFactory.js +1 -1
- package/src/sap/ui/fl/descriptorRelated/api/DescriptorVariantFactory.js +1 -1
- package/src/sap/ui/fl/initial/_internal/FlexConfiguration.js +1 -1
- package/src/sap/ui/fl/{apply/_internal/flexState → initial/_internal}/Loader.js +12 -10
- package/src/sap/ui/fl/{apply/_internal/flexState → initial/_internal}/ManifestUtils.js +1 -1
- package/src/sap/ui/fl/initial/_internal/Settings.js +13 -1
- package/src/sap/ui/fl/initial/_internal/Storage.js +3 -2
- package/src/sap/ui/fl/initial/_internal/StorageFeaturesMerger.js +1 -1
- package/src/sap/ui/fl/initial/_internal/StorageUtils.js +9 -7
- package/src/sap/ui/fl/initial/_internal/changeHandlers/ChangeHandlerRegistration.js +1 -1
- package/src/sap/ui/fl/initial/_internal/changeHandlers/ChangeHandlerStorage.js +1 -1
- package/src/sap/ui/fl/initial/_internal/connectors/Utils.js +1 -1
- package/src/sap/ui/fl/initial/_internal/storageResultDisassemble.js +1 -1
- package/src/sap/ui/fl/initial/api/InitialFlexAPI.js +1 -1
- package/src/sap/ui/fl/interfaces/BaseLoadConnector.js +1 -1
- package/src/sap/ui/fl/interfaces/Delegate.js +1 -1
- package/src/sap/ui/fl/library.js +43 -43
- package/src/sap/ui/fl/messagebundle_vi.properties +1 -1
- package/src/sap/ui/fl/support/_internal/extractChangeDependencies.js +6 -2
- package/src/sap/ui/fl/support/_internal/getAllUIChanges.js +2 -2
- package/src/sap/ui/fl/support/_internal/getChangeDependencies.js +2 -2
- package/src/sap/ui/fl/support/_internal/getFlexObjectInfos.js +2 -2
- package/src/sap/ui/fl/support/_internal/getFlexSettings.js +1 -1
- package/src/sap/ui/fl/support/api/SupportAPI.js +1 -1
- package/src/sap/ui/fl/support/apps/contentbrowser/controller/ContentDetails.controller.js +1 -1
- package/src/sap/ui/fl/support/apps/contentbrowser/controller/ContentDetailsEdit.controller.js +1 -1
- package/src/sap/ui/fl/support/apps/contentbrowser/controller/LayerContentMaster.controller.js +1 -1
- package/src/sap/ui/fl/support/apps/contentbrowser/controller/Layers.controller.js +1 -1
- package/src/sap/ui/fl/support/apps/contentbrowser/lrepConnector/LRepConnector.js +1 -1
- package/src/sap/ui/fl/support/apps/contentbrowser/utils/DataUtils.js +1 -1
- package/src/sap/ui/fl/support/apps/contentbrowser/utils/ErrorUtils.js +1 -1
- package/src/sap/ui/fl/transport/TransportSelection.js +1 -1
- package/src/sap/ui/fl/util/IFrame.js +15 -5
- package/src/sap/ui/fl/util/ManagedObjectModel.js +1 -1
- package/src/sap/ui/fl/variants/VariantManagement.js +39 -2
- package/src/sap/ui/fl/variants/VariantManager.js +9 -9
- package/src/sap/ui/fl/variants/VariantModel.js +59 -44
- package/src/sap/ui/fl/write/_internal/SaveAs.js +1 -1
- package/src/sap/ui/fl/write/_internal/Storage.js +14 -1
- package/src/sap/ui/fl/write/_internal/Versions.js +1 -1
- package/src/sap/ui/fl/write/_internal/appVariant/AppVariant.js +10 -1
- package/src/sap/ui/fl/write/_internal/appVariant/AppVariantFactory.js +6 -1
- package/src/sap/ui/fl/write/_internal/appVariant/AppVariantInlineChange.js +1 -1
- package/src/sap/ui/fl/write/_internal/appVariant/AppVariantInlineChangeFactory.js +1 -1
- package/src/sap/ui/fl/write/_internal/condenser/Condenser.js +1 -1
- package/src/sap/ui/fl/write/_internal/condenser/UIReconstruction.js +4 -2
- package/src/sap/ui/fl/write/_internal/connectors/BackendConnector.js +1 -1
- package/src/sap/ui/fl/write/_internal/connectors/BtpServiceConnector.js +27 -2
- package/src/sap/ui/fl/write/_internal/connectors/KeyUserConnector.js +1 -1
- package/src/sap/ui/fl/write/_internal/connectors/LrepConnector.js +4 -1
- package/src/sap/ui/fl/write/_internal/connectors/NeoLrepConnector.js +1 -1
- package/src/sap/ui/fl/write/_internal/connectors/ObjectPathConnector.js +1 -1
- package/src/sap/ui/fl/write/_internal/connectors/PersonalizationConnector.js +1 -1
- package/src/sap/ui/fl/write/_internal/connectors/Utils.js +1 -1
- package/src/sap/ui/fl/write/_internal/controlVariants/ControlVariantWriteUtils.js +2 -2
- package/src/sap/ui/fl/write/_internal/extensionPoint/Processor.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/ABAPAccess.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/ABAPExtensibilityVariant.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/ABAPExtensibilityVariantFactory.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/MultiTenantABAPExtensibilityVariant.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/ServiceValidation.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/SingleTenantABAPExtensibilityVariant.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/UriParser.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/Utils.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/CAPAccess.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/dialog/CustomFieldCAPDialog.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/editor/propertyEditor/booleanEditor/BooleanEditor.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/editor/propertyEditor/rangeEditor/RangeEditor.js +1 -1
- package/src/sap/ui/fl/write/_internal/fieldExtensibility/cap/editor/propertyEditor/timeEditor/TimeEditor.js +1 -1
- package/src/sap/ui/fl/write/_internal/flexState/FlexObjectManager.js +15 -54
- package/src/sap/ui/fl/write/_internal/flexState/UI2Personalization/UI2PersonalizationState.js +1 -1
- package/src/sap/ui/fl/write/_internal/flexState/changes/UIChangeManager.js +1 -1
- package/src/sap/ui/fl/write/_internal/flexState/compVariants/{CompVariantState.js → CompVariantManager.js} +186 -302
- package/src/sap/ui/fl/write/_internal/transport/TransportSelection.js +2 -2
- package/src/sap/ui/fl/write/_internal/transport/Transports.js +1 -1
- package/src/sap/ui/fl/write/api/AppVariantWriteAPI.js +2 -1
- package/src/sap/ui/fl/write/api/BusinessNetworkAPI.js +92 -6
- package/src/sap/ui/fl/write/api/ChangesWriteAPI.js +39 -17
- package/src/sap/ui/fl/write/api/ContextBasedAdaptationsAPI.js +17 -20
- package/src/sap/ui/fl/write/api/ContextSharingAPI.js +1 -1
- package/src/sap/ui/fl/write/api/FieldExtensibility.js +1 -1
- package/src/sap/ui/fl/write/api/LocalResetAPI.js +1 -1
- package/src/sap/ui/fl/write/api/PersistenceWriteAPI.js +25 -23
- package/src/sap/ui/fl/write/api/ReloadInfoAPI.js +5 -5
- package/src/sap/ui/fl/write/api/SACIntegrationUpdateVariant.js +6 -6
- package/src/sap/ui/fl/write/api/SmartBusinessWriteAPI.js +1 -1
- package/src/sap/ui/fl/write/api/SmartVariantManagementWriteAPI.js +25 -22
- package/src/sap/ui/fl/write/api/TranslationAPI.js +1 -1
- package/src/sap/ui/fl/write/api/UI2PersonalizationWriteAPI.js +2 -2
- package/src/sap/ui/fl/write/api/VersionsAPI.js +2 -2
- package/src/sap/ui/fl/write/api/connectors/FileListBaseConnector.js +1 -1
- package/src/sap/ui/fl/write/api/connectors/ObjectStorageConnector.js +2 -1
- package/src/sap/ui/fl/write/connectors/BaseConnector.js +13 -0
- package/ui5.yaml +0 -1
- package/src/sap/ui/fl/apply/_internal/flexState/compVariants/CompVariantMerger.js +0 -233
- package/src/sap/ui/fl/apply/_internal/flexState/compVariants/prepareCompVariantsMap.js +0 -118
- package/src/sap/ui/fl/util/resolveBinding.js +0 -79
|
@@ -6,47 +6,19 @@
|
|
|
6
6
|
|
|
7
7
|
sap.ui.define([
|
|
8
8
|
"sap/ui/fl/apply/_internal/flexState/compVariants/CompVariantManagementState",
|
|
9
|
-
"sap/ui/fl/apply/_internal/flexState/compVariants/CompVariantMerger",
|
|
10
9
|
"sap/ui/fl/apply/_internal/flexState/compVariants/Utils",
|
|
11
10
|
"sap/ui/fl/apply/_internal/flexState/FlexState",
|
|
12
|
-
"sap/ui/fl/
|
|
13
|
-
"sap/ui/fl/LayerUtils",
|
|
11
|
+
"sap/ui/fl/initial/_internal/ManifestUtils",
|
|
14
12
|
"sap/ui/fl/Utils"
|
|
15
13
|
], function(
|
|
16
14
|
CompVariantManagementState,
|
|
17
|
-
CompVariantMerger,
|
|
18
15
|
CompVariantUtils,
|
|
19
16
|
FlexState,
|
|
20
17
|
ManifestUtils,
|
|
21
|
-
LayerUtils,
|
|
22
18
|
Utils
|
|
23
19
|
) {
|
|
24
20
|
"use strict";
|
|
25
21
|
|
|
26
|
-
function getCompEntities(mPropertyBag) {
|
|
27
|
-
var oControl = mPropertyBag.control;
|
|
28
|
-
var oVMControl = oControl.getVariantManagement?.() || oControl;
|
|
29
|
-
var sSVMControlId = oVMControl.getId();
|
|
30
|
-
|
|
31
|
-
return FlexState.initialize({
|
|
32
|
-
reference: mPropertyBag.reference,
|
|
33
|
-
componentData: {},
|
|
34
|
-
manifest: Utils.getAppDescriptor(oControl),
|
|
35
|
-
componentId: Utils.getAppComponentForControl(oControl).getId()
|
|
36
|
-
}).then(function() {
|
|
37
|
-
var mCompVariantsMap = FlexState.getCompVariantsMap(mPropertyBag.reference);
|
|
38
|
-
// Store external input data to FlexState so they can be restored after invalidating cache
|
|
39
|
-
FlexState.setInitialNonFlCompVariantData(
|
|
40
|
-
mPropertyBag.reference,
|
|
41
|
-
mPropertyBag.persistencyKey,
|
|
42
|
-
mPropertyBag.standardVariant,
|
|
43
|
-
mPropertyBag.variants,
|
|
44
|
-
sSVMControlId
|
|
45
|
-
);
|
|
46
|
-
return mCompVariantsMap._initialize(mPropertyBag.persistencyKey, mPropertyBag.variants, sSVMControlId);
|
|
47
|
-
});
|
|
48
|
-
}
|
|
49
|
-
|
|
50
22
|
/**
|
|
51
23
|
* Object containing data for a SmartVariantManagement control.
|
|
52
24
|
*
|
|
@@ -101,7 +73,7 @@ sap.ui.define([
|
|
|
101
73
|
* sap.ui.comp.smarttable.SmartTable|
|
|
102
74
|
* sap.ui.comp.smartchart.SmartChart} mPropertyBag.control - Variant management control to load variants for
|
|
103
75
|
* @param {sap.ui.fl.apply.api.SmartVariantManagementApplyAPI.LoadVariantsInput} mPropertyBag.standardVariant - The standard variant of the control;
|
|
104
|
-
* a standard variant is created into the response but may be replaced later if data is loaded
|
|
76
|
+
* a standard variant is created into the response but may be replaced later if data is loaded afterward
|
|
105
77
|
* instructing the SVM to do so
|
|
106
78
|
* @param {sap.ui.fl.apply.api.SmartVariantManagementApplyAPI.LoadVariantsInput[]} mPropertyBag.variants - Variant data from other data providers like an OData service
|
|
107
79
|
* @returns {Promise<sap.ui.fl.apply.api.SmartVariantManagementApplyAPI.LoadVariantsResponse>} Object with the standard variant and the variants
|
|
@@ -110,24 +82,51 @@ sap.ui.define([
|
|
|
110
82
|
* @ui5-restricted sap.ui.comp
|
|
111
83
|
*/
|
|
112
84
|
async loadVariants(mPropertyBag) {
|
|
113
|
-
|
|
114
|
-
|
|
85
|
+
const oControl = mPropertyBag.control;
|
|
86
|
+
const sReference = ManifestUtils.getFlexReferenceForControl(oControl);
|
|
87
|
+
const sPersistencyKey = CompVariantUtils.getPersistencyKey(oControl);
|
|
115
88
|
|
|
116
|
-
const
|
|
89
|
+
const mProperties = Object.assign({
|
|
90
|
+
reference: sReference,
|
|
91
|
+
persistencyKey: sPersistencyKey,
|
|
92
|
+
componentId: Utils.getAppComponentForControl(oControl).getId()
|
|
93
|
+
}, mPropertyBag);
|
|
117
94
|
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
);
|
|
95
|
+
await FlexState.initialize({
|
|
96
|
+
componentId: mProperties.componentId
|
|
97
|
+
});
|
|
98
|
+
FlexState.addSVMControl(sReference, oControl);
|
|
99
|
+
CompVariantManagementState.addExternalVariants(mProperties);
|
|
124
100
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
101
|
+
const aVariants = CompVariantManagementState.assembleVariantList(mProperties);
|
|
102
|
+
|
|
103
|
+
const sDefaultVariantId = CompVariantManagementState.getDefaultVariantId({
|
|
104
|
+
persistencyKey: sPersistencyKey,
|
|
105
|
+
reference: sReference,
|
|
106
|
+
variants: aVariants
|
|
129
107
|
});
|
|
130
|
-
|
|
108
|
+
|
|
109
|
+
const aVariantsWithoutStandard = [];
|
|
110
|
+
let oStandardVariant;
|
|
111
|
+
|
|
112
|
+
aVariants.forEach((oVariant) => {
|
|
113
|
+
if (oVariant.getStandardVariant()) {
|
|
114
|
+
oStandardVariant = oVariant;
|
|
115
|
+
} else {
|
|
116
|
+
aVariantsWithoutStandard.push(oVariant);
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
// the default is always visible and thus a favorite
|
|
120
|
+
if (oVariant.getVariantId() === sDefaultVariantId) {
|
|
121
|
+
oVariant.setFavorite(true);
|
|
122
|
+
}
|
|
123
|
+
});
|
|
124
|
+
|
|
125
|
+
return {
|
|
126
|
+
defaultVariantId: sDefaultVariantId,
|
|
127
|
+
variants: aVariantsWithoutStandard,
|
|
128
|
+
standardVariant: oStandardVariant
|
|
129
|
+
};
|
|
131
130
|
}
|
|
132
131
|
};
|
|
133
132
|
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
sap.ui.define([
|
|
8
8
|
"sap/ui/fl/apply/_internal/flexState/UI2Personalization/UI2PersonalizationState",
|
|
9
9
|
"sap/ui/fl/apply/_internal/flexState/FlexState",
|
|
10
|
-
"sap/ui/fl/
|
|
10
|
+
"sap/ui/fl/initial/_internal/ManifestUtils"
|
|
11
11
|
], function(
|
|
12
12
|
UI2PersonalizationState,
|
|
13
13
|
FlexState,
|
|
@@ -23,7 +23,7 @@ sap.ui.define([
|
|
|
23
23
|
* @namespace
|
|
24
24
|
* @name sap.ui.fl.descriptorRelated
|
|
25
25
|
* @author SAP SE
|
|
26
|
-
* @version 1.
|
|
26
|
+
* @version 1.140.0
|
|
27
27
|
* @private
|
|
28
28
|
* @ui5-restricted sap.ui.rta, smart business
|
|
29
29
|
*/
|
|
@@ -33,7 +33,7 @@ sap.ui.define([
|
|
|
33
33
|
* @namespace
|
|
34
34
|
* @name sap.ui.fl.descriptorRelated.api
|
|
35
35
|
* @author SAP SE
|
|
36
|
-
* @version 1.
|
|
36
|
+
* @version 1.140.0
|
|
37
37
|
* @private
|
|
38
38
|
* @ui5-restricted sap.ui.rta, smart business
|
|
39
39
|
*/
|
|
@@ -47,7 +47,7 @@ sap.ui.define([
|
|
|
47
47
|
* @constructor
|
|
48
48
|
* @alias sap.ui.fl.descriptorRelated.api.DescriptorChange
|
|
49
49
|
* @author SAP SE
|
|
50
|
-
* @version 1.
|
|
50
|
+
* @version 1.140.0
|
|
51
51
|
* @private
|
|
52
52
|
* @ui5-restricted sap.ui.rta, smart business
|
|
53
53
|
*/
|
|
@@ -15,7 +15,7 @@ sap.ui.define([
|
|
|
15
15
|
* @namespace
|
|
16
16
|
* @name sap.ui.fl.descriptorRelated
|
|
17
17
|
* @author SAP SE
|
|
18
|
-
* @version 1.
|
|
18
|
+
* @version 1.140.0
|
|
19
19
|
* @private
|
|
20
20
|
* @ui5-restricted sap.ui.rta, smart business
|
|
21
21
|
*/
|
|
@@ -25,7 +25,7 @@ sap.ui.define([
|
|
|
25
25
|
* @namespace
|
|
26
26
|
* @name sap.ui.fl.descriptorRelated.api
|
|
27
27
|
* @author SAP SE
|
|
28
|
-
* @version 1.
|
|
28
|
+
* @version 1.140.0
|
|
29
29
|
* @private
|
|
30
30
|
* @ui5-restricted sap.ui.rta, smart business
|
|
31
31
|
*/
|
|
@@ -37,7 +37,7 @@ sap.ui.define([
|
|
|
37
37
|
* @constructor
|
|
38
38
|
* @alias sap.ui.fl.descriptorRelated.api.DescriptorChangeFactory
|
|
39
39
|
* @author SAP SE
|
|
40
|
-
* @version 1.
|
|
40
|
+
* @version 1.140.0
|
|
41
41
|
* @private
|
|
42
42
|
* @ui5-restricted sap.ui.rta, smart business
|
|
43
43
|
*/
|
|
@@ -38,7 +38,7 @@ sap.ui.define([
|
|
|
38
38
|
* @namespace
|
|
39
39
|
* @alias sap.ui.fl.descriptorRelated.api.DescriptorInlineChangeFactory
|
|
40
40
|
* @author SAP SE
|
|
41
|
-
* @version 1.
|
|
41
|
+
* @version 1.140.0
|
|
42
42
|
* @private
|
|
43
43
|
* @deprecated Since version 1.76
|
|
44
44
|
* @ui5-restricted sap.ui.rta, smart business
|
|
@@ -16,7 +16,7 @@ sap.ui.define([
|
|
|
16
16
|
* @namespace
|
|
17
17
|
* @alias sap.ui.fl.descriptorRelated.api.DescriptorVariantFactory
|
|
18
18
|
* @author SAP SE
|
|
19
|
-
* @version 1.
|
|
19
|
+
* @version 1.140.0
|
|
20
20
|
* @private
|
|
21
21
|
* @deprecated Since version 1.73
|
|
22
22
|
* @ui5-restricted sap.ui.rta, smart business
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
sap.ui.define([
|
|
8
8
|
"sap/base/util/ObjectPath",
|
|
9
9
|
"sap/ui/base/ManagedObject",
|
|
10
|
-
"sap/ui/fl/
|
|
10
|
+
"sap/ui/fl/initial/_internal/ManifestUtils",
|
|
11
11
|
"sap/ui/fl/initial/_internal/Settings",
|
|
12
12
|
"sap/ui/fl/initial/_internal/Storage",
|
|
13
13
|
"sap/ui/fl/initial/_internal/StorageUtils"
|
|
@@ -16,7 +16,7 @@ sap.ui.define([
|
|
|
16
16
|
ManagedObject,
|
|
17
17
|
ManifestUtils,
|
|
18
18
|
Settings,
|
|
19
|
-
|
|
19
|
+
Storage,
|
|
20
20
|
StorageUtils
|
|
21
21
|
) {
|
|
22
22
|
"use strict";
|
|
@@ -135,7 +135,7 @@ sap.ui.define([
|
|
|
135
135
|
*
|
|
136
136
|
* @namespace sap.ui.fl.apply._internal.flexState.Loader
|
|
137
137
|
* @since 1.74
|
|
138
|
-
* @version 1.
|
|
138
|
+
* @version 1.140.0
|
|
139
139
|
* @private
|
|
140
140
|
* @ui5-restricted sap.ui.fl.apply._internal.flexState
|
|
141
141
|
*/
|
|
@@ -155,15 +155,16 @@ sap.ui.define([
|
|
|
155
155
|
* @param {object} [mPropertyBag.asyncHints] - Async hints passed from the app index to the component processing
|
|
156
156
|
* @param {number} [mPropertyBag.version] - Number of the version in which the state should be initialized
|
|
157
157
|
* @param {string} [mPropertyBag.adaptationId] - Context-based adaptation for which the state should be initialized
|
|
158
|
-
* @param {
|
|
158
|
+
* @param {boolean} [mPropertyBag.skipLoadBundle=false] - If true only the partial flex data is loaded, without the bundle
|
|
159
159
|
* @param {boolean} [mPropertyBag.allContexts] - Includes also restricted context
|
|
160
|
+
* @param {object} [mPropertyBag.partialFlexData] - Already loaded data if only the bundle has to be loaded
|
|
160
161
|
* @returns {Promise<object>} resolves with the change file for the given component from the Storage
|
|
161
162
|
*/
|
|
162
163
|
loadFlexData(mPropertyBag) {
|
|
163
164
|
var sComponentName = ManifestUtils.getBaseComponentNameFromManifest(mPropertyBag.manifest);
|
|
164
165
|
|
|
165
166
|
if (mPropertyBag.partialFlexData) {
|
|
166
|
-
return
|
|
167
|
+
return Storage.completeFlexData({
|
|
167
168
|
reference: mPropertyBag.reference,
|
|
168
169
|
componentName: sComponentName,
|
|
169
170
|
partialFlexData: mPropertyBag.partialFlexData
|
|
@@ -173,7 +174,7 @@ sap.ui.define([
|
|
|
173
174
|
// the cache key cannot be used in case of a reinitialization
|
|
174
175
|
var sCacheKey = mPropertyBag.reInitialize ? undefined : ManifestUtils.getCacheKeyFromAsyncHints(mPropertyBag.reference, mPropertyBag.asyncHints);
|
|
175
176
|
|
|
176
|
-
return
|
|
177
|
+
return Storage.loadFlexData({
|
|
177
178
|
preview: ManifestUtils.getPreviewSectionFromAsyncHints(mPropertyBag.asyncHints),
|
|
178
179
|
reference: mPropertyBag.reference,
|
|
179
180
|
componentName: sComponentName,
|
|
@@ -182,10 +183,11 @@ sap.ui.define([
|
|
|
182
183
|
appDescriptor: mPropertyBag.manifest.getRawJson ? mPropertyBag.manifest.getRawJson() : mPropertyBag.manifest,
|
|
183
184
|
version: mPropertyBag.version,
|
|
184
185
|
allContexts: mPropertyBag.allContexts,
|
|
185
|
-
adaptationId: mPropertyBag.adaptationId
|
|
186
|
+
adaptationId: mPropertyBag.adaptationId,
|
|
187
|
+
skipLoadBundle: mPropertyBag.skipLoadBundle
|
|
186
188
|
})
|
|
187
|
-
.then(applyDeactivateChanges
|
|
188
|
-
.then(filterInvalidFileNames
|
|
189
|
+
.then(applyDeactivateChanges)
|
|
190
|
+
.then(filterInvalidFileNames)
|
|
189
191
|
.then(migrateSelectorFlags.bind(undefined, isMigrationNeeded(mPropertyBag.manifest)))
|
|
190
192
|
.then(formatFlexData);
|
|
191
193
|
},
|
|
@@ -200,7 +202,7 @@ sap.ui.define([
|
|
|
200
202
|
// the settings are available due to previous loadFlexData calls or
|
|
201
203
|
// not available due to an async hint stating that no changes are available, thus also no author mapping needed
|
|
202
204
|
const oSettings = Settings.getInstanceOrUndef();
|
|
203
|
-
return oSettings?.getIsVariantAuthorNameAvailable() ?
|
|
205
|
+
return oSettings?.getIsVariantAuthorNameAvailable() ? Storage.loadVariantsAuthors(sReference) : Promise.resolve({});
|
|
204
206
|
}
|
|
205
207
|
};
|
|
206
208
|
});
|
|
@@ -40,7 +40,7 @@ sap.ui.define([
|
|
|
40
40
|
* @extends sap.ui.base.ManagedObject
|
|
41
41
|
* @alias sap.ui.fl.initial._internal.Settings
|
|
42
42
|
* @since 1.137
|
|
43
|
-
* @version 1.
|
|
43
|
+
* @version 1.140.0
|
|
44
44
|
* @private
|
|
45
45
|
* @ui5-restricted sap.ui.fl
|
|
46
46
|
*/
|
|
@@ -99,6 +99,18 @@ sap.ui.define([
|
|
|
99
99
|
delete oSettingsProperties.isZeroDowntimeUpgradeRunning;
|
|
100
100
|
delete oSettingsProperties.isAtoAvailable;
|
|
101
101
|
|
|
102
|
+
// to avoid failing assertions, remove any unknown properties
|
|
103
|
+
const aUnknownPropertyNames = Object.keys(oSettingsProperties)
|
|
104
|
+
.map((sProperty) => {
|
|
105
|
+
if (!Settings.getMetadata().getAllProperties()[sProperty]) {
|
|
106
|
+
delete oSettingsProperties[sProperty];
|
|
107
|
+
return sProperty;
|
|
108
|
+
}
|
|
109
|
+
return null;
|
|
110
|
+
})
|
|
111
|
+
.filter(Boolean);
|
|
112
|
+
Log.warning(`Unknown settings received from the backend: ${aUnknownPropertyNames.join(", ")}`);
|
|
113
|
+
|
|
102
114
|
// The following line is used by the Flex Support Tool to set breakpoints - please adjust the tool if you change it!
|
|
103
115
|
oSettingsInstance = new Settings(oSettingsProperties);
|
|
104
116
|
return oSettingsInstance;
|
|
@@ -28,7 +28,7 @@ sap.ui.define([
|
|
|
28
28
|
*
|
|
29
29
|
* @namespace sap.ui.fl.initial._internal.Storage
|
|
30
30
|
* @since 1.67
|
|
31
|
-
* @version 1.
|
|
31
|
+
* @version 1.140.0
|
|
32
32
|
* @private
|
|
33
33
|
* @ui5-restricted sap.ui.fl
|
|
34
34
|
*/
|
|
@@ -204,6 +204,7 @@ sap.ui.define([
|
|
|
204
204
|
* @param {number} [mPropertyBag.version] - Number of the version for which the data should be loaded
|
|
205
205
|
* @param {boolean} [mPropertyBag.allContexts] Includes also restricted context
|
|
206
206
|
* @param {string} [mPropertyBag.adaptationId] - Context-based adaptation to be loaded
|
|
207
|
+
* @param {string} [mPropertyBag.skipLoadBundle=false] - If true only the partial flex data is loaded, without the bundle
|
|
207
208
|
* @returns {Promise<object>} Resolves with the responses from all configured connectors merged into one object
|
|
208
209
|
*/
|
|
209
210
|
Storage.loadFlexData = function(mPropertyBag) {
|
|
@@ -211,7 +212,7 @@ sap.ui.define([
|
|
|
211
212
|
return Promise.reject("No reference was provided");
|
|
212
213
|
}
|
|
213
214
|
|
|
214
|
-
return StorageUtils.getLoadConnectors()
|
|
215
|
+
return StorageUtils.getLoadConnectors(mPropertyBag.skipLoadBundle)
|
|
215
216
|
.then(_loadFlexDataFromConnectors.bind(this, mPropertyBag))
|
|
216
217
|
.then(_flattenAndMergeResultPromise);
|
|
217
218
|
};
|
|
@@ -25,7 +25,7 @@ sap.ui.define([
|
|
|
25
25
|
*
|
|
26
26
|
* @namespace sap.ui.fl.initial._internal.StorageUtils
|
|
27
27
|
* @since 1.74
|
|
28
|
-
* @version 1.
|
|
28
|
+
* @version 1.140.0
|
|
29
29
|
* @private
|
|
30
30
|
* @ui5-restricted sap.ui.fl.initial._internal.Storage, sap.ui.fl.write._internal.Storage,
|
|
31
31
|
* sap.ui.fl.initial._internal.connectors.ObjectStorageConnector, sap.ui.fl.initial._internal.connectors.ObjectPathConnector
|
|
@@ -140,14 +140,15 @@ sap.ui.define([
|
|
|
140
140
|
/**
|
|
141
141
|
* Provides all mandatory connectors required to apply or write data depending on the given namespace.
|
|
142
142
|
*
|
|
143
|
-
* @param {string} sNameSpace Namespace to determine the path to the configured connectors
|
|
144
|
-
* @param {boolean} bLoadConnectors Flag to determine if the loading scenario is used and the StaticFileConnector should be included
|
|
143
|
+
* @param {string} sNameSpace - Namespace to determine the path to the configured connectors
|
|
144
|
+
* @param {boolean} bLoadConnectors - Flag to determine if the loading scenario is used and the StaticFileConnector should be included
|
|
145
|
+
* @param {boolean} bSkipAddStaticFileConnector - Flag to determine if the StaticFileConnector should be added
|
|
145
146
|
* @returns {Promise<map[]>} Resolving with a list of maps for all configured connectors and their requested modules
|
|
146
147
|
*/
|
|
147
|
-
StorageUtils.getConnectors = function(sNameSpace, bLoadConnectors) {
|
|
148
|
+
StorageUtils.getConnectors = function(sNameSpace, bLoadConnectors, bSkipAddStaticFileConnector) {
|
|
148
149
|
var aConfiguredConnectors = FlexConfiguration.getFlexibilityServices();
|
|
149
150
|
var mConnectors = [];
|
|
150
|
-
if (bLoadConnectors) {
|
|
151
|
+
if (bLoadConnectors && !bSkipAddStaticFileConnector) {
|
|
151
152
|
mConnectors = [STATIC_FILE_CONNECTOR_CONFIGURATION];
|
|
152
153
|
}
|
|
153
154
|
|
|
@@ -160,10 +161,11 @@ sap.ui.define([
|
|
|
160
161
|
* Provides all mandatory connectors required to read data for the initial case; these are the static
|
|
161
162
|
* file connector as well as all connectors mentioned in the core-Configuration.
|
|
162
163
|
*
|
|
164
|
+
* @param {boolean} bSkipAddStaticFileConnector - Flag to determine if the StaticFileConnector should be added
|
|
163
165
|
* @returns {Promise<map[]>} Resolving with a list of maps for all configured initial connectors and their requested modules
|
|
164
166
|
*/
|
|
165
|
-
StorageUtils.getLoadConnectors = function() {
|
|
166
|
-
return this.getConnectors(INITIAL_CONNECTOR_NAME_SPACE, true);
|
|
167
|
+
StorageUtils.getLoadConnectors = function(bSkipAddStaticFileConnector) {
|
|
168
|
+
return this.getConnectors(INITIAL_CONNECTOR_NAME_SPACE, true, bSkipAddStaticFileConnector);
|
|
167
169
|
};
|
|
168
170
|
|
|
169
171
|
/**
|
|
@@ -62,7 +62,7 @@ sap.ui.define([
|
|
|
62
62
|
*
|
|
63
63
|
* @namespace sap.ui.fl.initial._internal.connectors.Utils
|
|
64
64
|
* @since 1.70
|
|
65
|
-
* @version 1.
|
|
65
|
+
* @version 1.140.0
|
|
66
66
|
* @private
|
|
67
67
|
* @ui5-restricted sap.ui.fl.initial._internal.connectors, sap.ui.fl.write._internal.connectors, sap.ui.fl.write._internal.transport
|
|
68
68
|
*/
|
|
@@ -51,7 +51,7 @@ function(
|
|
|
51
51
|
* @name sap.ui.fl.initial._internal.storageResultDisassemble
|
|
52
52
|
* @function
|
|
53
53
|
* @since 1.70
|
|
54
|
-
* @version 1.
|
|
54
|
+
* @version 1.140.0
|
|
55
55
|
* @private
|
|
56
56
|
* @ui5-restricted sap.ui.fl.initial._internal.Storage
|
|
57
57
|
* Disassembles a response with a variant section into one or more plain responses.
|