@sapui5/sap.ushell_abap 1.151.0 → 1.152.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/package.json +1 -1
- package/src/main/js/sap/ushell_abap/.library +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/AdapterContainer.js +30 -31
- package/src/main/js/sap/ushell_abap/adapters/abap/AppStateAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/ClientSideTargetResolutionAdapter.js +13 -18
- package/src/main/js/sap/ushell_abap/adapters/abap/CommonDataModelAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/ConfigurationDefaultsAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/ContainerAdapter.js +31 -41
- package/src/main/js/sap/ushell_abap/adapters/abap/FlpLaunchPageAdapter.js +430 -555
- package/src/main/js/sap/ushell_abap/adapters/abap/LaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/NavTargetResolutionAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/NavTargetResolutionInternalAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/PageBuildingAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/PagePersistenceAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/PersonalizationAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/PersonalizationV2Adapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/SearchAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/SupportTicketAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/Ui5ComponentLoaderAdapter.js +1 -1
- package/src/main/js/sap/ushell_abap/adapters/abap/UserInfoAdapter.js +119 -125
- package/src/main/js/sap/ushell_abap/adapters/hana/ContainerAdapter.js +27 -33
- package/src/main/js/sap/ushell_abap/bootstrap/PageSetsRequestHandler.js +25 -50
- package/src/main/js/sap/ushell_abap/bootstrap/SAPCompanionConditionSetter.js +1 -3
- package/src/main/js/sap/ushell_abap/integration/fileshares/NavTargetResolutionFileShareSupport.js +3 -1
- package/src/main/js/sap/ushell_abap/library.js +1 -1
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Catalog.js +69 -43
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Chip.js +53 -64
- package/src/main/js/sap/ushell_abap/pbServices/ui2/ODataWrapper.js +63 -78
- package/src/main/js/sap/ushell_abap/pbServices/ui2/Page.js +12 -15
- package/src/main/js/sap/ushell_abap/pbServices/ui2/contracts/configurationUi.js +10 -2
- package/src/main/js/sap/ushell_abap/services/NavigationDataProvider.js +4 -4
- package/src/main/js/sap/ushell_abap/ui5appruntime/AppInfoAdapter.js +19 -18
- package/ui5.yaml +1 -3
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<library xmlns="http://www.sap.com/sap.ui.library.xsd">
|
|
3
3
|
<name>sap.ushell_abap</name>
|
|
4
4
|
<vendor>SAP SE</vendor>
|
|
5
|
-
<version>1.
|
|
5
|
+
<version>1.152.0</version>
|
|
6
6
|
<copyright>Copyright (c) 2009-2026 SAP SE, All Rights Reserved</copyright>
|
|
7
7
|
<documentation>SAP library: sap.ushell_abap</documentation>
|
|
8
8
|
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
sap.ui.define([
|
|
4
4
|
"sap/base/util/ObjectPath",
|
|
5
5
|
"sap/base/Log",
|
|
6
|
-
"sap/ui/thirdparty/jquery",
|
|
7
6
|
"sap/ui/core/format/DateFormat",
|
|
8
7
|
"sap/ushell_abap/pbServices/ui2/ODataService",
|
|
9
8
|
"sap/ushell/services/PersonalizationV2/constants",
|
|
@@ -11,7 +10,6 @@ sap.ui.define([
|
|
|
11
10
|
], (
|
|
12
11
|
ObjectPath,
|
|
13
12
|
Log,
|
|
14
|
-
jQuery,
|
|
15
13
|
DateFormat,
|
|
16
14
|
ODataService,
|
|
17
15
|
PersonalizationV2Constants,
|
|
@@ -72,7 +70,6 @@ sap.ui.define([
|
|
|
72
70
|
|
|
73
71
|
// loads data from backend, when done, oPropertyBag contains the items
|
|
74
72
|
AdapterContainer.prototype.load = function () {
|
|
75
|
-
const oDeferred = new jQuery.Deferred();
|
|
76
73
|
const that = this;
|
|
77
74
|
const oDataWrapper = this._obtainODataWrapper();
|
|
78
75
|
// load container data with _sContainerKey data into _oPoprertyBag
|
|
@@ -84,29 +81,29 @@ sap.ui.define([
|
|
|
84
81
|
return false;
|
|
85
82
|
});
|
|
86
83
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
84
|
+
return new Promise((resolve, reject) => {
|
|
85
|
+
oDataWrapper.read(sRelativeUrl, (oData) => {
|
|
86
|
+
// TODO : align container id?
|
|
87
|
+
that._oJSONContainer = oData;
|
|
88
|
+
// overwrite key and category, do not trust server response
|
|
89
|
+
that._oJSONContainer.category = that._category;
|
|
90
|
+
that._oJSONContainer.id = that._sContainerKey;
|
|
91
|
+
that._oJSONContainer.appName = that._sAppName;
|
|
92
|
+
// response contains items.results (!)
|
|
93
|
+
that._oJSONContainer.PersContainerItems = (that._oJSONContainer.PersContainerItems && that._oJSONContainer.PersContainerItems.results) || [];
|
|
94
|
+
resolve(that);
|
|
95
|
+
}, (sErrorMessage, oParsedError) => {
|
|
96
|
+
// this error handler used to resolve with an empty personalization container
|
|
97
|
+
// but was changed to reject the promise so that the caller can react to the error
|
|
98
|
+
Log.error(sErrorMessage);
|
|
101
99
|
|
|
102
|
-
|
|
100
|
+
reject(new LaunchpadError(sErrorMessage, oParsedError));
|
|
101
|
+
});
|
|
103
102
|
});
|
|
104
|
-
return oDeferred.promise();
|
|
105
103
|
};
|
|
106
104
|
|
|
107
105
|
AdapterContainer.prototype.save = function () {
|
|
108
106
|
Log.debug("[000] save", "AdapterContainer");
|
|
109
|
-
const oDeferred = new jQuery.Deferred();
|
|
110
107
|
const that = this;
|
|
111
108
|
const oDataWrapper = this._obtainODataWrapper();
|
|
112
109
|
const sRelativeURL = sCONTAINERCOLLECTIONNAME;
|
|
@@ -115,16 +112,16 @@ sap.ui.define([
|
|
|
115
112
|
return false;
|
|
116
113
|
});
|
|
117
114
|
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
115
|
+
return new Promise((resolve, reject) => {
|
|
116
|
+
oDataWrapper.create(sRelativeURL, this._oJSONContainer, (/* response */) => {
|
|
117
|
+
resolve(that);
|
|
118
|
+
}, (sErrorMessage, oParsedError) => {
|
|
119
|
+
reject(new LaunchpadError(sErrorMessage, oParsedError));
|
|
120
|
+
});
|
|
122
121
|
});
|
|
123
|
-
return oDeferred.promise();
|
|
124
122
|
};
|
|
125
123
|
|
|
126
124
|
AdapterContainer.prototype.del = function () {
|
|
127
|
-
const oDeferred = new jQuery.Deferred();
|
|
128
125
|
const that = this;
|
|
129
126
|
const oDataWrapper = this._obtainODataWrapper();
|
|
130
127
|
const sRelativeURL = `${sCONTAINERCOLLECTIONNAME}(category='${this._category}',id='${encodeURIComponent(this._sContainerKey)}')`;
|
|
@@ -133,13 +130,15 @@ sap.ui.define([
|
|
|
133
130
|
return false;
|
|
134
131
|
});
|
|
135
132
|
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
133
|
+
const pResult = new Promise((resolve, reject) => {
|
|
134
|
+
oDataWrapper.del(sRelativeURL, (response) => {
|
|
135
|
+
resolve(that);
|
|
136
|
+
}, (sErrorMessage, oParsedError) => {
|
|
137
|
+
reject(new LaunchpadError(sErrorMessage, oParsedError));
|
|
138
|
+
});
|
|
140
139
|
});
|
|
141
140
|
this._reset();
|
|
142
|
-
return
|
|
141
|
+
return pResult;
|
|
143
142
|
};
|
|
144
143
|
|
|
145
144
|
AdapterContainer.prototype.getItemKeys = function () {
|
|
@@ -9,12 +9,13 @@
|
|
|
9
9
|
* <li>provide the resolveHashFragmentFallback function, a fallback method called by ClientSideTargetResolution service.</li>
|
|
10
10
|
* </ul>
|
|
11
11
|
*
|
|
12
|
-
* @version 1.
|
|
12
|
+
* @version 1.152.0
|
|
13
13
|
*/
|
|
14
14
|
sap.ui.define([
|
|
15
15
|
"sap/base/util/ObjectPath",
|
|
16
16
|
"sap/base/util/isPlainObject",
|
|
17
17
|
"sap/base/util/deepExtend",
|
|
18
|
+
"sap/ushell/base/promisify",
|
|
18
19
|
"sap/ushell/base/SAPBusinessClientEnablement",
|
|
19
20
|
"sap/ushell/base/UrlParsing",
|
|
20
21
|
"sap/ushell/utils",
|
|
@@ -28,6 +29,7 @@ sap.ui.define([
|
|
|
28
29
|
ObjectPath,
|
|
29
30
|
isPlainObject,
|
|
30
31
|
deepExtend,
|
|
32
|
+
promisify,
|
|
31
33
|
SAPBusinessClientEnablement,
|
|
32
34
|
UrlParsing,
|
|
33
35
|
ushellUtils,
|
|
@@ -1292,29 +1294,22 @@ sap.ui.define([
|
|
|
1292
1294
|
});
|
|
1293
1295
|
};
|
|
1294
1296
|
|
|
1295
|
-
ClientSideTargetResolutionAdapter.prototype._compactUrl = function (sUrl) {
|
|
1297
|
+
ClientSideTargetResolutionAdapter.prototype._compactUrl = async function (sUrl) {
|
|
1296
1298
|
const aMatches = sUrl.match(/\?.*/);
|
|
1297
1299
|
const sMatch = aMatches && aMatches[0];
|
|
1298
1300
|
const iLengthLimit = this._getWDAUrlShorteningLengthLimit() - 200;
|
|
1299
1301
|
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
}
|
|
1302
|
+
if (sMatch && sMatch.length < iLengthLimit) {
|
|
1303
|
+
return sUrl;
|
|
1304
|
+
}
|
|
1304
1305
|
|
|
1305
|
-
|
|
1306
|
+
const oParams = UrlParsing.parseParameters(aMatches[0]);
|
|
1306
1307
|
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
fnResolve(sReconstructedUrl);
|
|
1313
|
-
})
|
|
1314
|
-
.fail(fnReject);
|
|
1315
|
-
})
|
|
1316
|
-
.catch(fnReject);
|
|
1317
|
-
});
|
|
1308
|
+
const oShellNavigationInternal = await Container.getServiceAsync("ShellNavigationInternal");
|
|
1309
|
+
const oCompactedParams = await promisify(oShellNavigationInternal.compactParams(oParams, aNotCompactedWDAParameters, undefined /* no Component */));
|
|
1310
|
+
|
|
1311
|
+
const sReconstructedUrl = `${sUrl.match(/^[^?]*/)[0]}?${UrlParsing.paramsToString(oCompactedParams)}`;
|
|
1312
|
+
return sReconstructedUrl;
|
|
1318
1313
|
};
|
|
1319
1314
|
|
|
1320
1315
|
ClientSideTargetResolutionAdapter.prototype._getWDAUrlShorteningLengthLimit = function () {
|
|
@@ -2,10 +2,9 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* @fileOverview The Unified Shell's container adapter for the ABAP platform.
|
|
4
4
|
*
|
|
5
|
-
* @version 1.
|
|
5
|
+
* @version 1.152.0
|
|
6
6
|
*/
|
|
7
7
|
sap.ui.define([
|
|
8
|
-
"sap/ui/thirdparty/jquery",
|
|
9
8
|
"sap/ushell/base/SAPBusinessClientEnablement",
|
|
10
9
|
"sap/ushell/System",
|
|
11
10
|
"sap/ushell/User",
|
|
@@ -20,7 +19,6 @@ sap.ui.define([
|
|
|
20
19
|
"sap/ushell/Config",
|
|
21
20
|
"sap/ushell/Container"
|
|
22
21
|
], (
|
|
23
|
-
jQuery,
|
|
24
22
|
SAPBusinessClientEnablement,
|
|
25
23
|
System,
|
|
26
24
|
User,
|
|
@@ -318,12 +316,11 @@ sap.ui.define([
|
|
|
318
316
|
/**
|
|
319
317
|
* Does the bootstrap for the ABAP platform (and loads the container's configuration).
|
|
320
318
|
*
|
|
321
|
-
* @returns {
|
|
319
|
+
* @returns {Promise} Resolves once the bootstrap is done.
|
|
322
320
|
*
|
|
323
321
|
* @since 1.11.0
|
|
324
322
|
*/
|
|
325
|
-
this.load = function () {
|
|
326
|
-
const oDeferred = new jQuery.Deferred();
|
|
323
|
+
this.load = async function () {
|
|
327
324
|
const oStartupResult = oProperties.config;
|
|
328
325
|
const oSystemProperties = oStartupResult.systemProperties;
|
|
329
326
|
|
|
@@ -372,48 +369,41 @@ sap.ui.define([
|
|
|
372
369
|
|
|
373
370
|
// TODO: remove this from startup sequence
|
|
374
371
|
this._setUserImage(oUser);
|
|
375
|
-
|
|
376
|
-
return oDeferred.resolve().promise();
|
|
377
372
|
};
|
|
378
373
|
|
|
379
374
|
/**
|
|
380
375
|
* Add further remote systems to be logged out
|
|
381
376
|
*
|
|
382
|
-
* @returns {
|
|
377
|
+
* @returns {Promise} Resolved after further remote systems are added in to local storage
|
|
383
378
|
* @since 1.19.0
|
|
384
379
|
*/
|
|
385
|
-
this.addFurtherRemoteSystems = function () {
|
|
386
|
-
const
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
});
|
|
413
|
-
})
|
|
414
|
-
.catch(oDeferred.reject);
|
|
415
|
-
|
|
416
|
-
return oDeferred.promise();
|
|
380
|
+
this.addFurtherRemoteSystems = async function () {
|
|
381
|
+
const PageBuildingService = await Container.getServiceAsync("PageBuilding");
|
|
382
|
+
await new Promise((resolve, reject) => {
|
|
383
|
+
PageBuildingService
|
|
384
|
+
.getFactory()
|
|
385
|
+
.getPageBuildingService()
|
|
386
|
+
.readAllCatalogsForUser("type eq 'H' or type eq 'REMOTE'", (oData) => { // success handler
|
|
387
|
+
const sSocialMediaUrl = "/sap/opu/odata/sap/SM_CATALOG_SRV/";
|
|
388
|
+
if (oData.results) {
|
|
389
|
+
oData.results.forEach((oCatalog) => {
|
|
390
|
+
const bIsHANAUrl = /^\/sap\/hba\//.test(oCatalog.baseUrl);
|
|
391
|
+
if (oCatalog.type === "H" || oCatalog.baseUrl === sSocialMediaUrl || bIsHANAUrl) {
|
|
392
|
+
Container.addRemoteSystem(new System({
|
|
393
|
+
alias: oCatalog.systemAlias,
|
|
394
|
+
platform: (bIsHANAUrl || oCatalog.type === "H")
|
|
395
|
+
? "hana" : "abap",
|
|
396
|
+
baseUrl: oCatalog.type === "H" ? "" : ";o="
|
|
397
|
+
}));
|
|
398
|
+
}
|
|
399
|
+
});
|
|
400
|
+
}
|
|
401
|
+
resolve();
|
|
402
|
+
}, (sErrorMessage) => { // error handler
|
|
403
|
+
Log.error("Reading REMOTE catalogs failed:", sErrorMessage, "sap.ushell_abap.adapters.abap.ContainerAdapter");
|
|
404
|
+
reject(new Error(sErrorMessage));
|
|
405
|
+
});
|
|
406
|
+
});
|
|
417
407
|
};
|
|
418
408
|
|
|
419
409
|
/**
|