@sapui5/sap.suite.ui.generic.template 1.132.0 → 1.133.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/sap/suite/ui/generic/template/.library +1 -1
- package/src/sap/suite/ui/generic/template/AnalyticalListPage/Component.js +0 -4
- package/src/sap/suite/ui/generic/template/AnalyticalListPage/control/visualfilterbar/FilterItemMicroBar.js +3 -1
- package/src/sap/suite/ui/generic/template/AnalyticalListPage/control/visualfilterbar/FilterItemMicroChart.js +7 -2
- package/src/sap/suite/ui/generic/template/AnalyticalListPage/control/visualfilterbar/FilterItemMicroDonut.js +3 -1
- package/src/sap/suite/ui/generic/template/AnalyticalListPage/control/visualfilterbar/FilterItemMicroLine.js +3 -1
- package/src/sap/suite/ui/generic/template/AnalyticalListPage/controller/KpiTagController.js +3 -4
- package/src/sap/suite/ui/generic/template/AnalyticalListPage/extensionAPI/ExtensionAPI.js +2 -2
- package/src/sap/suite/ui/generic/template/AnalyticalListPage/manifest.json +1 -1
- package/src/sap/suite/ui/generic/template/AnalyticalListPage/util/AnnotationHelper.js +3 -0
- package/src/sap/suite/ui/generic/template/Canvas/manifest.json +1 -1
- package/src/sap/suite/ui/generic/template/ListReport/AnnotationHelperSmartList.js +2 -2
- package/src/sap/suite/ui/generic/template/ListReport/controller/ControllerImplementation.js +2 -0
- package/src/sap/suite/ui/generic/template/ListReport/extensionAPI/ExtensionAPI.js +2 -2
- package/src/sap/suite/ui/generic/template/ListReport/manifest.json +1 -1
- package/src/sap/suite/ui/generic/template/ListReport/view/fragments/SmartTable.fragment.xml +1 -1
- package/src/sap/suite/ui/generic/template/ObjectPage/Component.js +13 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/controller/ControllerImplementation.js +11 -8
- package/src/sap/suite/ui/generic/template/ObjectPage/controller/MessageSortingHandler.js +63 -10
- package/src/sap/suite/ui/generic/template/ObjectPage/controllerFrameworkExtensions.js +1 -0
- package/src/sap/suite/ui/generic/template/ObjectPage/extensionAPI/ExtensionAPI.js +2 -2
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n.properties +37 -6
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ar.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_bg.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ca.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_cnr.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_cs.properties +26 -6
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_cy.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_da.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_de.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_el.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_en.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_en_GB.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_en_US_saprigi.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_es.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_es_MX.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_et.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_fi.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_fr.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_fr_CA.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_hi.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_hr.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_hu.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_id.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_it.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_iw.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ja.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_kk.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ko.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_lt.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_lv.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_mk.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ms.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_nl.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_no.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_pl.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_pt.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_pt_PT.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ro.properties +26 -6
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ru.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sh.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sk.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sl.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sr.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sv.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_th.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_tr.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_uk.properties +27 -7
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_vi.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_zh_CN.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_zh_TW.properties +25 -5
- package/src/sap/suite/ui/generic/template/ObjectPage/manifest.json +1 -1
- package/src/sap/suite/ui/generic/template/ObjectPage/view/fragments/SmartTable.fragment.xml +1 -1
- package/src/sap/suite/ui/generic/template/QuickCreate/manifest.json +1 -1
- package/src/sap/suite/ui/generic/template/QuickView/manifest.json +1 -1
- package/src/sap/suite/ui/generic/template/designtime/controls/DynamicPage.designtime.js +74 -17
- package/src/sap/suite/ui/generic/template/designtime/controls/ObjectPageLayout.designtime.js +22 -11
- package/src/sap/suite/ui/generic/template/designtime/controls/SmartFilterBar.designtime.js +142 -38
- package/src/sap/suite/ui/generic/template/designtime/controls/SmartTable.designtime.js +43 -19
- package/src/sap/suite/ui/generic/template/designtime/floorplans/AnalyticalListPage.designtime.js +18 -18
- package/src/sap/suite/ui/generic/template/designtime/floorplans/ListReport.designtime.js +19 -16
- package/src/sap/suite/ui/generic/template/designtime/floorplans/ObjectPage.designtime.js +10 -7
- package/src/sap/suite/ui/generic/template/designtime/utils/designtimeHelper.js +32 -44
- package/src/sap/suite/ui/generic/template/designtime/utils/designtimeUtils.js +47 -2
- package/src/sap/suite/ui/generic/template/fragments/DeterminingButton.fragment.xml +18 -20
- package/src/sap/suite/ui/generic/template/fragments/GridTableCells.fragment.xml +4 -4
- package/src/sap/suite/ui/generic/template/fragments/HeaderDataPointContent.fragment.xml +1 -1
- package/src/sap/suite/ui/generic/template/fragments/HeaderFormDataField.fragment.xml +2 -2
- package/src/sap/suite/ui/generic/template/fragments/MessagePopover.fragment.xml +2 -1
- package/src/sap/suite/ui/generic/template/fragments/TableCell.fragment.xml +2 -2
- package/src/sap/suite/ui/generic/template/fragments/TreeTableColumns.fragment.xml +1 -1
- package/src/sap/suite/ui/generic/template/genericUtilities/controlStateWrapperFactory/SmartVariantManagementWrapper.js +4 -2
- package/src/sap/suite/ui/generic/template/js/AnnotationHelper.js +15 -19
- package/src/sap/suite/ui/generic/template/js/AnnotationHelperStreamSupport.js +3 -0
- package/src/sap/suite/ui/generic/template/js/QuickTemplates/QuickTemplateComponentFactory.js +2 -3
- package/src/sap/suite/ui/generic/template/js/RuntimeFormatters.js +78 -22
- package/src/sap/suite/ui/generic/template/lib/AppComponent.js +1 -1
- package/src/sap/suite/ui/generic/template/lib/CRUDActionHandler.js +12 -3
- package/src/sap/suite/ui/generic/template/lib/CommonEventHandlers.js +13 -1
- package/src/sap/suite/ui/generic/template/lib/CommonUtils.js +41 -36
- package/src/sap/suite/ui/generic/template/lib/MessageButtonHelper.js +6 -0
- package/src/sap/suite/ui/generic/template/lib/MessageStripHelper.js +1 -1
- package/src/sap/suite/ui/generic/template/lib/RetryAfterHandler.js +2 -3
- package/src/sap/suite/ui/generic/template/lib/TemplateComponent.js +3 -4
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n.properties +3 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ar.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_bg.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ca.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_cnr.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_cs.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_cy.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_da.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_de.properties +5 -3
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_el.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en_GB.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en_US_sappsd.properties +11 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en_US_saprigi.properties +6 -2
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en_US_saptrc.properties +9 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_es.properties +4 -2
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_es_MX.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_et.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_fi.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_fr.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_fr_CA.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_hi.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_hr.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_hu.properties +4 -2
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_id.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_it.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_iw.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ja.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_kk.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ko.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_lt.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_lv.properties +3 -1
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_mk.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ms.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_nl.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_no.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_pl.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_pt.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_pt_PT.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ro.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ru.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sh.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sk.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sl.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sr.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sv.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_th.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_tr.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_uk.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_vi.properties +3 -1
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_zh_CN.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/i18n/i18n_zh_TW.properties +2 -0
- package/src/sap/suite/ui/generic/template/lib/insights/InsightsCardHelper.js +27 -11
- package/src/sap/suite/ui/generic/template/lib/navigation/NavigationController.js +1 -1
- package/src/sap/suite/ui/generic/template/lib/presentationControl/SmartTableHandler.js +93 -1
- package/src/sap/suite/ui/generic/template/library.js +1 -1
- package/src/sap/suite/ui/generic/template/listTemplates/fragments/DetailSmartTable.fragment.xml +1 -1
- package/src/sap/suite/ui/generic/template/manifestMerger/ChangePageConfiguration.js +3 -0
- package/src/sap/suite/ui/generic/template/manifestMerger/MergerUtil.js +27 -1
|
@@ -29,6 +29,7 @@ sap.ui.define([
|
|
|
29
29
|
* @property {boolean=} bSupportsGlobalScope - Indicates if the setting supports global scope. (Default: false)
|
|
30
30
|
* @property {string[]=} restrictedTo - The array of components for which the setting is restricted.
|
|
31
31
|
* @property {boolean=} bGlobalSettingsOnly - Indicates if the setting is only available in global settings. (Default: false)
|
|
32
|
+
* @property {boolean} keyUser - Indicates if the setting is allowed for key user.
|
|
32
33
|
*/
|
|
33
34
|
|
|
34
35
|
/**
|
|
@@ -129,28 +130,28 @@ sap.ui.define([
|
|
|
129
130
|
const sProperty = oSetting.id;
|
|
130
131
|
switch (sProperty) {
|
|
131
132
|
case "type":
|
|
132
|
-
mPropertyValues[sProperty] = oTableSettings.type
|
|
133
|
+
mPropertyValues[sProperty] = oTableSettings.type ?? oSetting.value;
|
|
133
134
|
break;
|
|
134
135
|
case "multiSelect":
|
|
135
|
-
mPropertyValues[sProperty] = oTableSettings.multiSelect
|
|
136
|
+
mPropertyValues[sProperty] = oTableSettings.multiSelect ?? oSetting.value;
|
|
136
137
|
break;
|
|
137
138
|
case "createMode":
|
|
138
|
-
mPropertyValues[sProperty] = oTableSettings.createMode
|
|
139
|
+
mPropertyValues[sProperty] = oTableSettings.createMode ?? oSetting.value;
|
|
139
140
|
break;
|
|
140
141
|
case "selectAll":
|
|
141
|
-
mPropertyValues[sProperty] = oTableSettings.selectAll
|
|
142
|
+
mPropertyValues[sProperty] = oTableSettings.selectAll ?? oSetting.value;
|
|
142
143
|
break;
|
|
143
144
|
case "condensedTableLayout":
|
|
144
|
-
mPropertyValues[sProperty] = oTableSettings.condensedTableLayout
|
|
145
|
+
mPropertyValues[sProperty] = oTableSettings.condensedTableLayout ?? oSetting.value;
|
|
145
146
|
break;
|
|
146
147
|
case "widthIncludingColumnHeader":
|
|
147
|
-
mPropertyValues[sProperty] = oTableSettings.widthIncludingColumnHeader
|
|
148
|
+
mPropertyValues[sProperty] = oTableSettings.widthIncludingColumnHeader ?? oSetting.value;
|
|
148
149
|
break;
|
|
149
150
|
case "addCardtoInsightsHidden":
|
|
150
|
-
mPropertyValues[sProperty] = oTableSettings.addCardtoInsightsHidden
|
|
151
|
+
mPropertyValues[sProperty] = oTableSettings.addCardtoInsightsHidden ?? oSetting.value;
|
|
151
152
|
break;
|
|
152
153
|
case "selectionLimit":
|
|
153
|
-
mPropertyValues[sProperty] = oTableSettings.selectionLimit
|
|
154
|
+
mPropertyValues[sProperty] = oTableSettings.selectionLimit ?? oSetting.value;
|
|
154
155
|
break;
|
|
155
156
|
default:
|
|
156
157
|
break;
|
|
@@ -159,12 +160,28 @@ sap.ui.define([
|
|
|
159
160
|
return mPropertyValues;
|
|
160
161
|
}
|
|
161
162
|
|
|
162
|
-
async function fnOpenTableConfigurationDialog(
|
|
163
|
+
async function fnOpenTableConfigurationDialog(oControl, mPropertyBag) {
|
|
164
|
+
// if control is not a SmartTable, find the parent SmartTable
|
|
165
|
+
// work around for the issue where the SmartTable is not selectable in the RTA
|
|
166
|
+
const oSmartTable = oControl.isA("sap.ui.comp.smarttable.SmartTable") ? oControl : oControl.getParent();
|
|
167
|
+
|
|
168
|
+
if (!oSmartTable.isA("sap.ui.comp.smarttable.SmartTable")) {
|
|
169
|
+
throw new Error("The SmartTable control could not be found");
|
|
170
|
+
}
|
|
171
|
+
|
|
163
172
|
const oResourceModel = oSmartTable.getModel("i18n");
|
|
164
173
|
const oComponent = designtimeUtils.getOwnerComponentFor(oSmartTable);
|
|
165
174
|
const sComponentName = oComponent.getMetadata().getComponentName();
|
|
166
175
|
// Get the allowed designtime settings for the SmartTable
|
|
167
|
-
const
|
|
176
|
+
const aAllDesigntimeSettings = getAllDesigntimeSettings(oSmartTable);
|
|
177
|
+
|
|
178
|
+
/**
|
|
179
|
+
* @type {DesigntimeSetting[]}
|
|
180
|
+
*/
|
|
181
|
+
let aAllowedDesigntimeSettings = designtimeUtils.filterDesigntimeSettingsByFloorPlan(oSmartTable, aAllDesigntimeSettings);
|
|
182
|
+
|
|
183
|
+
// Get the allowed designtime settings based on the adaptation mode (key user or Designtime)
|
|
184
|
+
aAllowedDesigntimeSettings = designtimeUtils.getAllowedDesigntimeSettingsBasedOnAdaptationMode(aAllowedDesigntimeSettings, oComponent);
|
|
168
185
|
|
|
169
186
|
// Get the other table properties outside of the tableSettings Eg: settings/condensedTableLayout
|
|
170
187
|
const aOtherTableProperties = ["condensedTableLayout"];
|
|
@@ -296,7 +313,7 @@ sap.ui.define([
|
|
|
296
313
|
* @param {object} oSmartTable - The SmartTable object.
|
|
297
314
|
* @returns {DesigntimeSetting[]} - The designtime settings for the SmartTable.
|
|
298
315
|
*/
|
|
299
|
-
let
|
|
316
|
+
let getAllDesigntimeSettings = function getAllDesigntimeSettings(oSmartTable) {
|
|
300
317
|
/**
|
|
301
318
|
* @type {DesigntimeSetting}
|
|
302
319
|
*/
|
|
@@ -313,7 +330,8 @@ sap.ui.define([
|
|
|
313
330
|
{ id: "TreeTable", name: "Tree Table" },
|
|
314
331
|
{ id: "AnalyticalTable", name: "Analytical Table" }
|
|
315
332
|
],
|
|
316
|
-
bSupportsGlobalScope: false
|
|
333
|
+
bSupportsGlobalScope: false,
|
|
334
|
+
keyUser: true
|
|
317
335
|
};
|
|
318
336
|
|
|
319
337
|
/**
|
|
@@ -331,7 +349,8 @@ sap.ui.define([
|
|
|
331
349
|
enums: [
|
|
332
350
|
{ id: "false", name: "Single" },
|
|
333
351
|
{ id: "true", name: "Multi" }
|
|
334
|
-
]
|
|
352
|
+
],
|
|
353
|
+
keyUser: true
|
|
335
354
|
};
|
|
336
355
|
|
|
337
356
|
/**
|
|
@@ -344,7 +363,8 @@ sap.ui.define([
|
|
|
344
363
|
value: false,
|
|
345
364
|
type: "boolean",
|
|
346
365
|
getPath: getPathForTableSettings("selectAll"),
|
|
347
|
-
bSupportsGlobalScope: false
|
|
366
|
+
bSupportsGlobalScope: false,
|
|
367
|
+
keyUser: true
|
|
348
368
|
};
|
|
349
369
|
|
|
350
370
|
// /**
|
|
@@ -376,7 +396,8 @@ sap.ui.define([
|
|
|
376
396
|
value: false,
|
|
377
397
|
type: "boolean",
|
|
378
398
|
getPath: () => "component/settings/condensedTableLayout",
|
|
379
|
-
bSupportsGlobalScope: false
|
|
399
|
+
bSupportsGlobalScope: false,
|
|
400
|
+
keyUser: true
|
|
380
401
|
};
|
|
381
402
|
|
|
382
403
|
/**
|
|
@@ -391,7 +412,8 @@ sap.ui.define([
|
|
|
391
412
|
getPath: getPathForTableSettings("widthIncludingColumnHeader"),
|
|
392
413
|
bSupportsGlobalScope: true,
|
|
393
414
|
restrictedTo: [sListReportComponentName],
|
|
394
|
-
bGlobalSettingsOnly: true
|
|
415
|
+
bGlobalSettingsOnly: true,
|
|
416
|
+
keyUser: true
|
|
395
417
|
};
|
|
396
418
|
|
|
397
419
|
/**
|
|
@@ -404,7 +426,8 @@ sap.ui.define([
|
|
|
404
426
|
value: false,
|
|
405
427
|
type: "boolean",
|
|
406
428
|
getPath: getPathForTableSettings("addCardtoInsightsHidden"),
|
|
407
|
-
restrictedTo: [sListReportComponentName]
|
|
429
|
+
restrictedTo: [sListReportComponentName],
|
|
430
|
+
keyUser: true
|
|
408
431
|
};
|
|
409
432
|
|
|
410
433
|
/**
|
|
@@ -416,7 +439,8 @@ sap.ui.define([
|
|
|
416
439
|
description: "Define the selection limit",
|
|
417
440
|
value: 300,
|
|
418
441
|
type: "number",
|
|
419
|
-
getPath: getPathForTableSettings("selectionLimit")
|
|
442
|
+
getPath: getPathForTableSettings("selectionLimit"),
|
|
443
|
+
keyUser: true
|
|
420
444
|
};
|
|
421
445
|
|
|
422
446
|
|
|
@@ -439,7 +463,7 @@ sap.ui.define([
|
|
|
439
463
|
};
|
|
440
464
|
|
|
441
465
|
// Expose the functions for QUnit tests
|
|
442
|
-
|
|
466
|
+
getAllDesigntimeSettings = testableHelper.testableStatic(getAllDesigntimeSettings, "getAllDesigntimeSettings");
|
|
443
467
|
getPathForTableSettings = testableHelper.testableStatic(getPathForTableSettings, "getPathForTableSettings");
|
|
444
468
|
testableHelper.testableStatic(getRuntimeAdapationProperties, "getRuntimeAdapationProperties");
|
|
445
469
|
testableHelper.testableStatic(getManifestTableSettings, "getManifestTableSettings");
|
package/src/sap/suite/ui/generic/template/designtime/floorplans/AnalyticalListPage.designtime.js
CHANGED
|
@@ -6,11 +6,14 @@
|
|
|
6
6
|
*/
|
|
7
7
|
// Provides the design time metadata for the sap.suite.ui.generic.template.AnalyticalListPage component
|
|
8
8
|
|
|
9
|
-
sap.ui.define([
|
|
10
|
-
|
|
9
|
+
sap.ui.define([
|
|
10
|
+
"sap/suite/ui/generic/template/designtime/utils/designtimeHelper",
|
|
11
|
+
"sap/suite/ui/generic/template/designtime/utils/designtimeUtils"
|
|
12
|
+
],
|
|
13
|
+
function (designtimeHelper, designtimeUtils) {
|
|
11
14
|
"use strict";
|
|
12
15
|
|
|
13
|
-
// allow list for designtime adaptation / level-0.
|
|
16
|
+
// allow list for designtime adaptation / level-0.
|
|
14
17
|
var mAllowLevel0 = {
|
|
15
18
|
"sap.f.DynamicPage": {
|
|
16
19
|
properties: ["headerExpanded", "preserveHeaderStateOnScroll"]
|
|
@@ -42,7 +45,7 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
42
45
|
properties: ["liveMode", "showClearOnFB", "showFilterConfiguration", "showRestoreOnFB", "considerPresentationVariant"]
|
|
43
46
|
},
|
|
44
47
|
"sap.m.Table": {
|
|
45
|
-
properties: ["growingThreshold"]
|
|
48
|
+
properties: ["growingThreshold", "rememberSelections"]
|
|
46
49
|
},
|
|
47
50
|
"sap.m.Column": {
|
|
48
51
|
properties: ["width", "hAlign"]
|
|
@@ -60,12 +63,9 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
60
63
|
properties: ["scrollThreshold"]
|
|
61
64
|
}
|
|
62
65
|
};
|
|
63
|
-
|
|
64
|
-
// grey list for designtime adaptation / level-0 (no technical difference too allow list, separated just for documentation
|
|
66
|
+
|
|
67
|
+
// grey list for designtime adaptation / level-0 (no technical difference too allow list, separated just for documentation
|
|
65
68
|
var mGreyLevel0 = {
|
|
66
|
-
"sap.suite.ui.generic.template.AnalyticalListPage.control.smartfilterbarext:SmartFilterBarExt": {
|
|
67
|
-
properties: ["useDateRangeType"]
|
|
68
|
-
},
|
|
69
69
|
"sap.ui.table.AnalyticalTable": {
|
|
70
70
|
properties: ["selectionMode", "minAutoRowCount", "visibleRowCountMode"]
|
|
71
71
|
},
|
|
@@ -76,12 +76,12 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
76
76
|
properties: ["header", "useTooltip"]
|
|
77
77
|
}
|
|
78
78
|
};
|
|
79
|
-
|
|
80
|
-
// allow list for key user adaptation.
|
|
79
|
+
|
|
80
|
+
// allow list for key user adaptation.
|
|
81
81
|
var mAllowKeyUser = {
|
|
82
82
|
"sap.m.MenuButton": { // used for create and create with filters and possibly created by combining of buttons
|
|
83
83
|
actions: ["split", "rename", "remove"]
|
|
84
|
-
},
|
|
84
|
+
},
|
|
85
85
|
"sap.m.Button": {
|
|
86
86
|
actions: ["remove", "reveal", "rename"]
|
|
87
87
|
},
|
|
@@ -104,7 +104,7 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
104
104
|
actions: ["rename"]
|
|
105
105
|
}
|
|
106
106
|
};
|
|
107
|
-
|
|
107
|
+
|
|
108
108
|
// allow list for variant management: All changes done here are stored with a variant, and only applied when that variant is selected.
|
|
109
109
|
// this mode is indicated by url parameter fiori-tools-rta-mode=true
|
|
110
110
|
var mAllowVariantManagement = {
|
|
@@ -127,8 +127,8 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
127
127
|
// there's no reliable way to differentiate designtime adaptation and key user adaptation. However
|
|
128
128
|
// - property changes are possible only in designtime adaptation
|
|
129
129
|
// - for any other changes (using change handlers), we anyway need to be prepared for the change if it is allowed in one mode, so it shouldn't matter if it's also possible in the other mode
|
|
130
|
-
const sRtaModeValue =
|
|
131
|
-
const mAllow = sRtaModeValue ===
|
|
132
|
-
|
|
133
|
-
});
|
|
134
|
-
|
|
130
|
+
const sRtaModeValue = designtimeUtils.getRtaModeValue();
|
|
131
|
+
const mAllow = sRtaModeValue === designtimeUtils.FioriToolsRtaMode.True ? mAllowVariantManagement : designtimeHelper.getMergedAllowList([mAllowLevel0, mGreyLevel0, mAllowKeyUser]);
|
|
132
|
+
return designtimeHelper.getViewDesignTime(mAllow, sRtaModeValue);
|
|
133
|
+
});
|
|
134
|
+
|
|
@@ -6,11 +6,14 @@
|
|
|
6
6
|
*/
|
|
7
7
|
// Provides the design time metadata for the sap.suite.ui.generic.template.ListReport component
|
|
8
8
|
|
|
9
|
-
sap.ui.define([
|
|
10
|
-
|
|
9
|
+
sap.ui.define([
|
|
10
|
+
"sap/suite/ui/generic/template/designtime/utils/designtimeHelper",
|
|
11
|
+
"sap/suite/ui/generic/template/designtime/utils/designtimeUtils"
|
|
12
|
+
],
|
|
13
|
+
function (designtimeHelper, designtimeUtils) {
|
|
11
14
|
"use strict";
|
|
12
15
|
|
|
13
|
-
// allow list for designtime adaptation / level-0.
|
|
16
|
+
// allow list for designtime adaptation / level-0.
|
|
14
17
|
var mAllowLevel0 = {
|
|
15
18
|
"sap.f.DynamicPage": {
|
|
16
19
|
properties: ["fitContent"]
|
|
@@ -23,7 +26,7 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
23
26
|
actions: ["settings"]
|
|
24
27
|
},
|
|
25
28
|
"sap.m.Table": {
|
|
26
|
-
properties: ["popinLayout", "includeItemInSelection", "growingThreshold"]
|
|
29
|
+
properties: ["popinLayout", "includeItemInSelection", "growingThreshold", "rememberSelections"]
|
|
27
30
|
},
|
|
28
31
|
"sap.m.Column": {
|
|
29
32
|
properties: ["width", "hAlign"]
|
|
@@ -62,8 +65,8 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
62
65
|
properties: ["scrollThreshold"]
|
|
63
66
|
}
|
|
64
67
|
};
|
|
65
|
-
|
|
66
|
-
// grey list for designtime adaptation / level-0 (no technical difference too allow list, separated just for documentation
|
|
68
|
+
|
|
69
|
+
// grey list for designtime adaptation / level-0 (no technical difference too allow list, separated just for documentation
|
|
67
70
|
var mGreyLevel0 = {
|
|
68
71
|
"sap.f.DynamicPage": {
|
|
69
72
|
properties: ["headerExpanded"]
|
|
@@ -72,7 +75,7 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
72
75
|
properties: ["width"]
|
|
73
76
|
},
|
|
74
77
|
"sap.ui.comp.smartfilterbar.SmartFilterBar": {
|
|
75
|
-
properties: ["showClearOnFB", "showFilterConfiguration", "showRestoreOnFB", "
|
|
78
|
+
properties: ["showClearOnFB", "showFilterConfiguration", "showRestoreOnFB", "filterBarExpanded", "showGoOnFB"]
|
|
76
79
|
},
|
|
77
80
|
"sap.m.Label": { // not created by us, but by SFB
|
|
78
81
|
properties: ["width", "wrapping"]
|
|
@@ -120,8 +123,8 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
120
123
|
properties: ["type"]
|
|
121
124
|
}
|
|
122
125
|
};
|
|
123
|
-
|
|
124
|
-
// allow list for key user adaptation.
|
|
126
|
+
|
|
127
|
+
// allow list for key user adaptation.
|
|
125
128
|
var mAllowKeyUser = {
|
|
126
129
|
"sap.ui.comp.smartform.SmartForm": { // used in multiedit dialog
|
|
127
130
|
aggregations: {
|
|
@@ -143,7 +146,7 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
143
146
|
},
|
|
144
147
|
"sap.m.MenuButton": { // used for create and create with filters and possibly created by combining of buttons
|
|
145
148
|
actions: ["split", "rename", "remove"]
|
|
146
|
-
},
|
|
149
|
+
},
|
|
147
150
|
"sap.m.Button": {
|
|
148
151
|
actions: ["remove", "reveal", "rename"]
|
|
149
152
|
},
|
|
@@ -166,7 +169,7 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
166
169
|
actions: ["rename"]
|
|
167
170
|
}
|
|
168
171
|
};
|
|
169
|
-
|
|
172
|
+
|
|
170
173
|
// allow list for variant management: All changes done here are stored with a variant, and only applied when that variant is selected.
|
|
171
174
|
// this mode is indicated by url parameter fiori-tools-rta-mode=true
|
|
172
175
|
var mAllowVariantManagement = {
|
|
@@ -189,8 +192,8 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
189
192
|
// there's no reliable way to differentiate designtime adaptation and key user adaptation. However
|
|
190
193
|
// - property changes are possible only in designtime adaptation
|
|
191
194
|
// - for any other changes (using change handlers), we anyway need to be prepared for the change if it is allowed in one mode, so it shouldn't matter if it's also possible in the other mode
|
|
192
|
-
const sRtaModeValue =
|
|
193
|
-
const mAllow = sRtaModeValue ===
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
195
|
+
const sRtaModeValue = designtimeUtils.getRtaModeValue();
|
|
196
|
+
const mAllow = sRtaModeValue === designtimeUtils.FioriToolsRtaMode.True ? mAllowVariantManagement : designtimeHelper.getMergedAllowList([mAllowLevel0, mGreyLevel0, mAllowKeyUser]);
|
|
197
|
+
return designtimeHelper.getViewDesignTime(mAllow, sRtaModeValue);
|
|
198
|
+
});
|
|
199
|
+
|
|
@@ -6,8 +6,11 @@
|
|
|
6
6
|
*/
|
|
7
7
|
// Provides the design time metadata for the sap.suite.ui.generic.template.ObjectPage component
|
|
8
8
|
|
|
9
|
-
sap.ui.define([
|
|
10
|
-
|
|
9
|
+
sap.ui.define([
|
|
10
|
+
"sap/suite/ui/generic/template/designtime/utils/designtimeHelper",
|
|
11
|
+
"sap/suite/ui/generic/template/designtime/utils/designtimeUtils"
|
|
12
|
+
],
|
|
13
|
+
function (designtimeHelper, designtimeUtils) {
|
|
11
14
|
"use strict";
|
|
12
15
|
|
|
13
16
|
// allow list for designtime adaptation / level-0.
|
|
@@ -40,7 +43,7 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
40
43
|
actions: ["settings"]
|
|
41
44
|
},
|
|
42
45
|
"sap.m.Table": {
|
|
43
|
-
properties: ["growingThreshold", "popinLayout", "includeItemInSelection"] // growingThreshold should not be possible in single section with single subsection
|
|
46
|
+
properties: ["growingThreshold", "popinLayout", "includeItemInSelection", "rememberSelections"] // growingThreshold should not be possible in single section with single subsection
|
|
44
47
|
},
|
|
45
48
|
"sap.m.Column": {
|
|
46
49
|
properties: ["width", "hAlign"]
|
|
@@ -274,8 +277,8 @@ sap.ui.define(["sap/suite/ui/generic/template/designtime/utils/designtimeHelper"
|
|
|
274
277
|
// there's no reliable way to differentiate designtime adaptation and key user adaptation. However
|
|
275
278
|
// - property changes are possible only in designtime adaptation
|
|
276
279
|
// - for any other changes (using change handlers), we anyway need to be prepared for the change if it is allowed in one mode, so it shouldn't matter if it's also possible in the other mode
|
|
277
|
-
const sRtaModeValue =
|
|
278
|
-
const mAllow = sRtaModeValue ===
|
|
279
|
-
|
|
280
|
+
const sRtaModeValue = designtimeUtils.getRtaModeValue();
|
|
281
|
+
const mAllow = sRtaModeValue === designtimeUtils.FioriToolsRtaMode.True ? mAllowVariantManagement : designtimeHelper.getMergedAllowList([mAllowLevel0, mGreyLevel0, mAllowKeyUser]);
|
|
282
|
+
return designtimeHelper.getViewDesignTime(mAllow);
|
|
280
283
|
|
|
281
|
-
|
|
284
|
+
});
|
|
@@ -56,7 +56,6 @@ sap.ui.define([
|
|
|
56
56
|
var mControlInfo = {};
|
|
57
57
|
var aViews = [];
|
|
58
58
|
// var oLogger = new FeLogger("designtime.utils.designTimeHelper").getLogger();
|
|
59
|
-
var RTA_MODE_URL_PARAM_KEY = "fiori-tools-rta-mode";
|
|
60
59
|
var oMutationObserver;
|
|
61
60
|
/**
|
|
62
61
|
* get effective designtime for all controls on current active view
|
|
@@ -127,15 +126,6 @@ sap.ui.define([
|
|
|
127
126
|
function fnStopMutationObserver() {
|
|
128
127
|
oMutationObserver && oMutationObserver.disconnect();
|
|
129
128
|
}
|
|
130
|
-
/**
|
|
131
|
-
* Parses the URL parameters and returns the value of RTA mode URL parameter (fiori-tools-rta-mode)
|
|
132
|
-
* @returns {string | null} A promise which returns a value of RTA mode
|
|
133
|
-
*/
|
|
134
|
-
function getRtaModeValue() {
|
|
135
|
-
const oUrlParams = new URLSearchParams(window.location.search);
|
|
136
|
-
const sRtaModeValue = oUrlParams.get(RTA_MODE_URL_PARAM_KEY);
|
|
137
|
-
return sRtaModeValue;
|
|
138
|
-
}
|
|
139
129
|
|
|
140
130
|
/*
|
|
141
131
|
* Returns the branch of the control tree as an array ordered from bottom to top, if the control is relevant (i.e. direct part of a template view). I.e. the first entry of the array is the
|
|
@@ -334,7 +324,7 @@ sap.ui.define([
|
|
|
334
324
|
return oResult;
|
|
335
325
|
}
|
|
336
326
|
|
|
337
|
-
function getViewDesignTime(mAllow
|
|
327
|
+
function getViewDesignTime(mAllow) {
|
|
338
328
|
return loadBaseDesigntime().then(function () {
|
|
339
329
|
|
|
340
330
|
// provide propagation function for all controls contained allowing only what we want to allow
|
|
@@ -347,32 +337,35 @@ sap.ui.define([
|
|
|
347
337
|
var oReducedDesigntime = oElement.getMetadata().getElementName && getReducedDesignTime(oElement, mAllow[oElement.getMetadata().getElementName()]);
|
|
348
338
|
|
|
349
339
|
var oCustomDesigntime = {};
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
340
|
+
switch (oElement.getMetadata().getElementName()) {
|
|
341
|
+
case "sap.uxap.ObjectPageLayout":
|
|
342
|
+
oCustomDesigntime = ObjectPageLayoutDesigntimeHelper.getDesigntime(
|
|
343
|
+
oElement
|
|
344
|
+
);
|
|
345
|
+
break;
|
|
346
|
+
case "sap.ui.comp.smartfilterbar.SmartFilterBar":
|
|
347
|
+
case "sap.suite.ui.generic.template.AnalyticalListPage.control.SmartFilterBarExt":
|
|
348
|
+
case "sap.suite.ui.generic.template.AnalyticalListPage.control.visualfilterbar.SmartVisualFilterBar":
|
|
349
|
+
oCustomDesigntime = SmartFilterBarDesigntimeHelper.getDesigntime(
|
|
350
|
+
oElement
|
|
351
|
+
);
|
|
352
|
+
break;
|
|
353
|
+
case "sap.ui.comp.smarttable.SmartTable":
|
|
354
|
+
case "sap.ui.table.Table":
|
|
355
|
+
case "sap.m.Table":
|
|
356
|
+
case "sap.ui.table.AnalyticalTable":
|
|
357
|
+
oCustomDesigntime = SmartTableDesigntimeHelper.getDesigntime(
|
|
358
|
+
oElement
|
|
359
|
+
);
|
|
360
|
+
break;
|
|
361
|
+
case "sap.f.DynamicPage":
|
|
362
|
+
oCustomDesigntime = DynamicPageDesigntimeHelper.getDesigntime(
|
|
363
|
+
oElement
|
|
364
|
+
);
|
|
365
|
+
break;
|
|
366
|
+
default:
|
|
367
|
+
break;
|
|
368
|
+
|
|
376
369
|
}
|
|
377
370
|
return merge(oReducedDesigntime, oCustomDesigntime);
|
|
378
371
|
}
|
|
@@ -418,16 +411,11 @@ sap.ui.define([
|
|
|
418
411
|
}
|
|
419
412
|
});
|
|
420
413
|
}
|
|
421
|
-
|
|
422
|
-
True: "true",
|
|
423
|
-
ForAdaptation: "forAdaptation"
|
|
424
|
-
};
|
|
414
|
+
|
|
425
415
|
|
|
426
416
|
return {
|
|
427
417
|
getMergedAllowList: deepMergeWithArray,
|
|
428
418
|
getViewDesignTime: getViewDesignTime,
|
|
429
|
-
|
|
430
|
-
stopMutationObserver: fnStopMutationObserver,
|
|
431
|
-
FioriToolsRtaMode
|
|
419
|
+
stopMutationObserver: fnStopMutationObserver
|
|
432
420
|
};
|
|
433
421
|
});
|
|
@@ -353,6 +353,7 @@ sap.ui.define([
|
|
|
353
353
|
* @property {DesigntimeSetting[]} [writeObject] - An array of DesigntimeSetting objects.
|
|
354
354
|
* @property {string} [writeObjectFor] - The value of the setting for which the Object should be constructed.
|
|
355
355
|
* @property {boolean} [skipChange] - Indicates if the change should be skipped.
|
|
356
|
+
* @property {boolean} [keyUser] - Indicates if the setting is allowed for key user.
|
|
356
357
|
|
|
357
358
|
* @typedef {string | boolean | string[] } PropertyValue
|
|
358
359
|
|
|
@@ -455,7 +456,16 @@ sap.ui.define([
|
|
|
455
456
|
return oSupportedGlobalManifestSettings;
|
|
456
457
|
}
|
|
457
458
|
|
|
458
|
-
|
|
459
|
+
/**
|
|
460
|
+
* Retrieves the allowed designtime settings for the given control based on the floorplan component name.
|
|
461
|
+
* If the control is not restricted to a specific component, all settings are returned.
|
|
462
|
+
* If the control is restricted to a specific component, only the settings for that component are returned.
|
|
463
|
+
* @param {sap.ui.core.Control} oControl - The control.
|
|
464
|
+
* @param {DesigntimeSetting[]} aDesigntimeSettings - The array of designtime settings.
|
|
465
|
+
* @returns {DesigntimeSetting[]} - The allowed designtime settings.
|
|
466
|
+
*/
|
|
467
|
+
|
|
468
|
+
function filterDesigntimeSettingsByFloorPlan(oControl, aDesigntimeSettings) {
|
|
459
469
|
const sComponentName = getOwnerComponentFor(oControl).getMetadata().getComponentName();
|
|
460
470
|
return aDesigntimeSettings.filter(oSetting => !oSetting.restrictedTo || oSetting.restrictedTo.includes(sComponentName));
|
|
461
471
|
}
|
|
@@ -466,6 +476,38 @@ sap.ui.define([
|
|
|
466
476
|
getChanges = testableHelper.testableStatic(getChanges, "getChanges");
|
|
467
477
|
getChangeStructure = testableHelper.testableStatic(getChangeStructure, "getChangeStructure");
|
|
468
478
|
|
|
479
|
+
/**
|
|
480
|
+
* Parses the URL parameters and returns the value of RTA mode URL parameter (fiori-tools-rta-mode)
|
|
481
|
+
* @returns {string | null} A promise which returns a value of RTA mode
|
|
482
|
+
*/
|
|
483
|
+
function getRtaModeValue() {
|
|
484
|
+
var RTA_MODE_URL_PARAM_KEY = "fiori-tools-rta-mode";
|
|
485
|
+
|
|
486
|
+
const oUrlParams = new URLSearchParams(window.location.search);
|
|
487
|
+
const sRtaModeValue = oUrlParams.get(RTA_MODE_URL_PARAM_KEY);
|
|
488
|
+
return sRtaModeValue;
|
|
489
|
+
}
|
|
490
|
+
|
|
491
|
+
const FioriToolsRtaMode = {
|
|
492
|
+
True: "true",
|
|
493
|
+
ForAdaptation: "forAdaptation"
|
|
494
|
+
};
|
|
495
|
+
|
|
496
|
+
/**
|
|
497
|
+
* Returns the allowed designtime settings based on the adaptation mode.
|
|
498
|
+
* If the adaptation mode is not set, only key user settings are returned.
|
|
499
|
+
* If the adaptation mode is set, all settings are returned.
|
|
500
|
+
*
|
|
501
|
+
* @param {DesigntimeSetting[]} aDesigntimeSettings
|
|
502
|
+
* @returns {DesigntimeSetting[]}
|
|
503
|
+
*/
|
|
504
|
+
function getAllowedDesigntimeSettingsBasedOnAdaptationMode(aDesigntimeSettings) {
|
|
505
|
+
if (!getRtaModeValue()) {
|
|
506
|
+
return aDesigntimeSettings.filter(oSetting => oSetting.keyUser);
|
|
507
|
+
}
|
|
508
|
+
return aDesigntimeSettings;
|
|
509
|
+
}
|
|
510
|
+
|
|
469
511
|
return {
|
|
470
512
|
openAdaptionDialog: fnOpenAdaptionDialog,
|
|
471
513
|
getSettings,
|
|
@@ -476,6 +518,9 @@ sap.ui.define([
|
|
|
476
518
|
SettingScope,
|
|
477
519
|
ChangeType,
|
|
478
520
|
getSupportedGlobalManifestSettings,
|
|
479
|
-
|
|
521
|
+
filterDesigntimeSettingsByFloorPlan,
|
|
522
|
+
getRtaModeValue,
|
|
523
|
+
FioriToolsRtaMode,
|
|
524
|
+
getAllowedDesigntimeSettingsBasedOnAdaptationMode
|
|
480
525
|
};
|
|
481
526
|
});
|
|
@@ -2,26 +2,24 @@
|
|
|
2
2
|
xmlns:template="http://schemas.sap.com/sapui5/extension/sap.ui.core.template/1"
|
|
3
3
|
template:require="{AH: 'sap/suite/ui/generic/template/js/AnnotationHelper', AHModel: 'sap/ui/model/odata/AnnotationHelper'}">
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
type="{path:'dataField>', formatter: 'AH.buildExpressionForButtonCriticality'}"
|
|
10
|
-
text="{= ${path: 'dataField>Label', formatter: 'AHModel.format'}}"
|
|
11
|
-
visible="{parts: [{path: 'parameter>/treeNode'}, {path: 'action>sap:applicable-path'}, {path: 'dataField>'}], formatter: 'AH.actionControlDetermining'}"
|
|
5
|
+
<template:with path="dataField>Action" helper="AHModel.gotoFunctionImport" var="action">
|
|
6
|
+
<Button id="{parts: [{path: 'dataField>'}, {path: 'facet>'}], formatter: 'AH.getStableIdPartForDatafieldActionButton'}::Determining"
|
|
7
|
+
type="{path:'dataField>', formatter: 'AH.buildExpressionForButtonCriticality'}" text="{= ${path: 'dataField>Label', formatter: 'AHModel.format'}}"
|
|
8
|
+
visible="{parts: [{path: 'parameter>/treeNode'}, {path: 'action>sap:applicable-path'}, {path: 'dataField>'}], formatter: 'AH.actionControlDetermining'}"
|
|
12
9
|
press="{parts: [{path: 'parameter>/settings'}, {path: 'dataField>'}, {path: 'parameter>/manifest'}, {value: 'true'}], formatter: 'AH.getAnnotatedActionPress'}">
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
10
|
+
<customData>
|
|
11
|
+
<core:CustomData key="Action" value="{path: 'dataField>Action', formatter: 'AHModel.format'}" />
|
|
12
|
+
<core:CustomData key="Label" value="{path: 'dataField>Label', formatter: 'AHModel.format'}" />
|
|
13
|
+
<core:CustomData key="ActionType" value="determining" />
|
|
14
|
+
<template:if test="{= ${dataField>RecordType} === 'com.sap.vocabularies.UI.v1.DataFieldForIntentBasedNavigation'}">
|
|
15
|
+
<core:CustomData key="SemanticObject" value="{path: 'dataField>SemanticObject', formatter: 'AHModel.format'}" />
|
|
16
|
+
<core:CustomData key="RequiresContext" value="{path: 'dataField>RequiresContext', formatter: 'AHModel.format'}" />
|
|
17
|
+
</template:if>
|
|
18
|
+
<template:with path="dataField>Action" helper="AHModel.gotoFunctionImport" var="action">
|
|
19
|
+
<core:CustomData key="ActionFor" value="{action>sap:action-for}" />
|
|
20
|
+
</template:with>
|
|
21
|
+
</customData>
|
|
22
|
+
</Button>
|
|
23
|
+
</template:with>
|
|
26
24
|
|
|
27
25
|
</core:FragmentDefinition>
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
<smartField:SmartField value="{path: 'dataField>Value', formatter: 'AHModel.simplePath'}" editable="false" contextEditable="false" fetchValueListReadOnly="false"
|
|
28
28
|
ariaLabelledBy="{columnId>id}">
|
|
29
29
|
<smartField:configuration>
|
|
30
|
-
<smartField:Configuration displayBehaviour="{parts: [{path: 'dataField>'}, {path: '
|
|
30
|
+
<smartField:Configuration displayBehaviour="{parts: [{path: 'dataField>'}, {path: 'listEntitySet>'}, {path: 'dataFieldTarget>Data'}], formatter: 'AH.getTextArrangementForSCFields'}"/>
|
|
31
31
|
</smartField:configuration>
|
|
32
32
|
<template:if test="{= ${dataField>Criticality}}">
|
|
33
33
|
<smartField:controlProposal>
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
<core:CustomData key="Target" value="{dataField>Target/NavigationPropertyPath}" />
|
|
56
56
|
</smartField:customData>
|
|
57
57
|
<smartField:configuration>
|
|
58
|
-
<smartField:Configuration displayBehaviour="{parts: [{path: 'dataField>'}, {
|
|
58
|
+
<smartField:Configuration displayBehaviour="{parts: [{path: 'dataField>'}, {path: 'listEntitySet>'}], formatter: 'AH.getTextArrangementForSmartControl'}" />
|
|
59
59
|
</smartField:configuration>
|
|
60
60
|
</smartField:SmartField>
|
|
61
61
|
</template:elseif>
|
|
@@ -84,7 +84,7 @@
|
|
|
84
84
|
<RatingIndicator
|
|
85
85
|
enabled="true" editable="false" maxValue="{path: 'dataFieldTarget>TargetValue', formatter: 'AHModel.format'}"
|
|
86
86
|
binding="{= ${ path: 'dataField>Target/AnnotationPath'}.indexOf('/') > -1 ? '{' + ${path: 'dataField>Target/AnnotationPath'}.slice(0, ${ path: 'dataField>Target/AnnotationPath'}.indexOf('/')) + '}' : null}"
|
|
87
|
-
value="{path: 'dataFieldTarget>Value', formatter: 'AHModel.format'}"
|
|
87
|
+
value="{path: 'dataFieldTarget>Value', formatter: 'AHModel.format'}" iconSize="16px" />
|
|
88
88
|
</template:with>
|
|
89
89
|
</template:elseif>
|
|
90
90
|
<template:elseif test="{= ${dataFieldTarget>Visualization/EnumMember} === 'com.sap.vocabularies.UI.v1.VisualizationType/Progress'}">
|
|
@@ -99,7 +99,7 @@
|
|
|
99
99
|
state="{path:'dataFieldTarget>', formatter: 'AH.buildExpressionForProgressIndicatorCriticality'}">
|
|
100
100
|
<customData>
|
|
101
101
|
<core:CustomData key="Target" value="{= ${path: 'dataFieldTarget>TargetValue', formatter: 'AHModel.format'} }" />
|
|
102
|
-
<core:CustomData key="UoM" value="{= ${path: '
|
|
102
|
+
<core:CustomData key="UoM" value="{= ${path: 'value>Org.OData.Measures.V1.Unit', formatter: 'AHModel.format'} }" />
|
|
103
103
|
</customData>
|
|
104
104
|
</ProgressIndicator>
|
|
105
105
|
</template:with>
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
</sfi:semanticObjectController>
|
|
19
19
|
<sfi:configuration>
|
|
20
20
|
<sfi:Configuration
|
|
21
|
-
displayBehaviour="{parts: [{path: 'dataPoint>'}, {path: '
|
|
21
|
+
displayBehaviour="{parts: [{path: 'dataPoint>'}, {path: 'entitySet>'}], formatter: 'AH.getTextArrangementForSmartControl'}"/>
|
|
22
22
|
</sfi:configuration>
|
|
23
23
|
<template:if test="{= ${dataPoint>Criticality} }">
|
|
24
24
|
<sfi:controlProposal>
|