@openui5/sap.ui.mdc 1.141.2 → 1.143.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 +2 -2
- package/REUSE.toml +39 -1
- package/THIRDPARTY.txt +36 -3
- package/package.json +4 -4
- package/src/sap/ui/mdc/.library +1 -1
- package/src/sap/ui/mdc/ActionToolbar.js +89 -63
- package/src/sap/ui/mdc/Chart.js +1 -1
- package/src/sap/ui/mdc/Control.js +1 -1
- package/src/sap/ui/mdc/DefaultTypeMap.js +1 -1
- package/src/sap/ui/mdc/Element.js +1 -1
- package/src/sap/ui/mdc/Field.js +31 -8
- package/src/sap/ui/mdc/FilterBar.js +1 -1
- package/src/sap/ui/mdc/FilterField.js +11 -11
- package/src/sap/ui/mdc/Geomap.js +571 -0
- package/src/sap/ui/mdc/GeomapDelegate.js +285 -0
- package/src/sap/ui/mdc/GeomapRenderer.js +76 -0
- package/src/sap/ui/mdc/Link.js +1 -1
- package/src/sap/ui/mdc/MultiValueField.js +7 -7
- package/src/sap/ui/mdc/Table.js +141 -116
- package/src/sap/ui/mdc/TableDelegate.js +3 -2
- package/src/sap/ui/mdc/ValueHelp.js +1 -1
- package/src/sap/ui/mdc/ValueHelpDelegate.js +4 -1
- package/src/sap/ui/mdc/actiontoolbar/ActionToolbarAction.js +1 -1
- package/src/sap/ui/mdc/chart/ChartImplementationContainer.js +1 -1
- package/src/sap/ui/mdc/chart/ChartSelectionDetails.js +1 -1
- package/src/sap/ui/mdc/chart/PropertyHelper.js +1 -1
- package/src/sap/ui/mdc/chart/ToolbarControlFactory.js +1 -1
- package/src/sap/ui/mdc/chart/Util.js +5 -2
- package/src/sap/ui/mdc/condition/Condition.js +1 -1
- package/src/sap/ui/mdc/condition/ConditionConverter.js +1 -1
- package/src/sap/ui/mdc/condition/ConditionModel.js +1 -1
- package/src/sap/ui/mdc/condition/FilterConverter.js +1 -1
- package/src/sap/ui/mdc/condition/FilterOperatorUtil.js +1 -1
- package/src/sap/ui/mdc/condition/Operator.js +1 -1
- package/src/sap/ui/mdc/condition/OperatorDynamicDateOption.js +1 -1
- package/src/sap/ui/mdc/condition/RangeOperator.js +1 -1
- package/src/sap/ui/mdc/designtime/geomap/Geomap.designtime.js +23 -0
- package/src/sap/ui/mdc/enums/GeomapControlPosition.js +46 -0
- package/src/sap/ui/mdc/enums/TableActionPosition.js +123 -0
- package/src/sap/ui/mdc/enums/TablePopinDisplay.js +36 -0
- package/src/sap/ui/mdc/field/ConditionType.js +1 -1
- package/src/sap/ui/mdc/field/ConditionTypeMixin.js +1 -1
- package/src/sap/ui/mdc/field/ConditionsType.js +1 -1
- package/src/sap/ui/mdc/field/CustomFieldInfo.js +1 -1
- package/src/sap/ui/mdc/field/DynamicDateRangeConditionsType.js +1 -1
- package/src/sap/ui/mdc/field/FieldBase.js +137 -66
- package/src/sap/ui/mdc/field/FieldInfoBase.js +1 -1
- package/src/sap/ui/mdc/field/FieldInput.js +1 -1
- package/src/sap/ui/mdc/field/FieldInputRenderUtil.js +1 -1
- package/src/sap/ui/mdc/field/FieldMultiInput.js +1 -1
- package/src/sap/ui/mdc/field/FieldSelect.js +7 -1
- package/src/sap/ui/mdc/field/ListFieldHelpItem.js +1 -1
- package/src/sap/ui/mdc/field/MultiValueFieldDelegate.js +22 -0
- package/src/sap/ui/mdc/field/MultiValueFieldItem.js +1 -1
- package/src/sap/ui/mdc/field/TokenDisplay.js +1 -1
- package/src/sap/ui/mdc/field/TokenizerDisplay.js +1 -1
- package/src/sap/ui/mdc/field/content/ContentFactory.js +3 -0
- package/src/sap/ui/mdc/filterbar/FilterBarBase.js +35 -1
- package/src/sap/ui/mdc/filterbar/FilterBarBaseRenderer.js +3 -0
- package/src/sap/ui/mdc/filterbar/PropertyHelper.js +1 -1
- package/src/sap/ui/mdc/filterbar/p13n/AdaptationFilterBar.js +1 -1
- package/src/sap/ui/mdc/filterbar/vh/FilterBar.js +1 -1
- package/src/sap/ui/mdc/flexibility/Chart.flexibility.js +1 -1
- package/src/sap/ui/mdc/flexibility/FilterBar.flexibility.js +1 -1
- package/src/sap/ui/mdc/flexibility/FilterItemFlex.js +1 -1
- package/src/sap/ui/mdc/flexibility/ItemBaseFlex.js +1 -1
- package/src/sap/ui/mdc/flexibility/SortFlex.js +12 -5
- package/src/sap/ui/mdc/flexibility/Table.flexibility.js +17 -11
- package/src/sap/ui/mdc/flexibility/actiontoolbar/CombineAction.js +1 -1
- package/src/sap/ui/mdc/flexibility/actiontoolbar/SplitAction.js +1 -1
- package/src/sap/ui/mdc/flexibility/helpers/getAffectedSorter.js +25 -0
- package/src/sap/ui/mdc/geomap/Item.js +48 -0
- package/src/sap/ui/mdc/geomap/PropertyHelper.js +70 -0
- package/src/sap/ui/mdc/library.js +19 -4
- package/src/sap/ui/mdc/link/Factory.js +1 -1
- package/src/sap/ui/mdc/link/LinkItem.js +1 -1
- package/src/sap/ui/mdc/link/Panel.js +1 -1
- package/src/sap/ui/mdc/link/PanelItem.js +1 -1
- package/src/sap/ui/mdc/link/SemanticObjectMapping.js +1 -1
- package/src/sap/ui/mdc/link/SemanticObjectMappingItem.js +1 -1
- package/src/sap/ui/mdc/link/SemanticObjectUnavailableAction.js +1 -1
- package/src/sap/ui/mdc/messagebundle.properties +15 -1
- package/src/sap/ui/mdc/messagebundle_ar.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_bg.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_ca.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_cnr.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_cs.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_cy.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_da.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_de.properties +10 -2
- package/src/sap/ui/mdc/messagebundle_el.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_en.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_en_GB.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_en_US_saprigi.properties +12 -1
- package/src/sap/ui/mdc/messagebundle_es.properties +10 -2
- package/src/sap/ui/mdc/messagebundle_es_MX.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_et.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_fi.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_fr.properties +11 -3
- package/src/sap/ui/mdc/messagebundle_fr_CA.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_hi.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_hr.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_hu.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_id.properties +11 -3
- package/src/sap/ui/mdc/messagebundle_it.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_iw.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_ja.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_kk.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_ko.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_lt.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_lv.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_mk.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_ms.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_nl.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_no.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_pl.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_pt.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_pt_PT.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_ro.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_ru.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_sh.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_sk.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_sl.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_sr.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_sv.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_th.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_tr.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_uk.properties +8 -0
- package/src/sap/ui/mdc/messagebundle_vi.properties +11 -3
- package/src/sap/ui/mdc/messagebundle_zh_CN.properties +9 -1
- package/src/sap/ui/mdc/messagebundle_zh_TW.properties +8 -0
- package/src/sap/ui/mdc/mixin/AdaptationMixin.js +1 -1
- package/src/sap/ui/mdc/mixin/DelegateMixin.js +1 -1
- package/src/sap/ui/mdc/mixin/FilterBarLayoutMixin.js +1 -1
- package/src/sap/ui/mdc/mixin/FilterIntegrationMixin.js +1 -1
- package/src/sap/ui/mdc/mixin/PromiseMixin.js +1 -1
- package/src/sap/ui/mdc/mixin/PropertyHelperMixin.js +1 -1
- package/src/sap/ui/mdc/odata/TypeMap.js +1 -1
- package/src/sap/ui/mdc/odata/v4/GeomapDelegate.js +60 -0
- package/src/sap/ui/mdc/odata/v4/TableDelegate.js +53 -2
- package/src/sap/ui/mdc/odata/v4/TypeMap.js +1 -1
- package/src/sap/ui/mdc/odata/v4/vizChart/ChartDelegate.js +16 -0
- package/src/sap/ui/mdc/p13n/PropertyHelper.js +1 -1
- package/src/sap/ui/mdc/p13n/StateUtil.js +1 -1
- package/src/sap/ui/mdc/p13n/panels/ChartItemPanel.js +3 -0
- package/src/sap/ui/mdc/p13n/subcontroller/ColumnFreezeController.js +1 -1
- package/src/sap/ui/mdc/p13n/subcontroller/ShowDetailsController.js +1 -1
- package/src/sap/ui/mdc/rules/Table.support.js +149 -118
- package/src/sap/ui/mdc/table/ActionLayoutData.js +47 -0
- package/src/sap/ui/mdc/table/Column.js +40 -186
- package/src/sap/ui/mdc/table/ColumnSettings.js +1 -1
- package/src/sap/ui/mdc/table/CreationRow.js +1 -1
- package/src/sap/ui/mdc/table/DragDropConfig.js +1 -1
- package/src/sap/ui/mdc/table/GridTableType.js +35 -21
- package/src/sap/ui/mdc/table/ODataV4PropertyHelper.js +1 -1
- package/src/sap/ui/mdc/table/PropertyHelper.js +1 -1
- package/src/sap/ui/mdc/table/ResponsiveColumnSettings.js +1 -1
- package/src/sap/ui/mdc/table/ResponsiveTableType.js +97 -14
- package/src/sap/ui/mdc/table/RowActionItem.js +1 -1
- package/src/sap/ui/mdc/table/RowSettings.js +1 -1
- package/src/sap/ui/mdc/table/TableSettings.js +34 -7
- package/src/sap/ui/mdc/table/TableTypeBase.js +38 -7
- package/src/sap/ui/mdc/table/utils/Personalization.js +1 -1
- package/src/sap/ui/mdc/themes/base/Geomap.less +50 -0
- package/src/sap/ui/mdc/ushell/SemanticObjectMapping.js +1 -1
- package/src/sap/ui/mdc/ushell/SemanticObjectMappingItem.js +1 -1
- package/src/sap/ui/mdc/ushell/SemanticObjectUnavailableAction.js +1 -1
- package/src/sap/ui/mdc/util/InfoBar.js +1 -1
- package/src/sap/ui/mdc/util/PromiseCache.js +1 -1
- package/src/sap/ui/mdc/util/PropertyHelper.js +1 -1
- package/src/sap/ui/mdc/util/PropertyHelperUtil.js +1 -1
- package/src/sap/ui/mdc/valuehelp/Dialog.js +2 -2
- package/src/sap/ui/mdc/valuehelp/FilterBar.js +22 -3
- package/src/sap/ui/mdc/valuehelp/Popover.js +1 -1
- package/src/sap/ui/mdc/valuehelp/base/Container.js +1 -1
- package/src/sap/ui/mdc/valuehelp/base/Content.js +1 -1
- package/src/sap/ui/mdc/valuehelp/base/DefineConditionPanel.js +140 -26
- package/src/sap/ui/mdc/valuehelp/base/DialogTab.js +1 -1
- package/src/sap/ui/mdc/valuehelp/base/FilterableListContent.js +4 -3
- package/src/sap/ui/mdc/valuehelp/base/ListContent.js +1 -1
- package/src/sap/ui/mdc/valuehelp/content/Bool.js +1 -1
- package/src/sap/ui/mdc/valuehelp/content/Conditions.js +1 -1
- package/src/sap/ui/mdc/valuehelp/content/FixedList.js +1 -1
- package/src/sap/ui/mdc/valuehelp/content/FixedListItem.js +1 -1
- package/src/sap/ui/mdc/valuehelp/content/MDCTable.js +1 -1
- package/src/sap/ui/mdc/valuehelp/content/MTable.js +7 -5
- package/test/sap/ui/mdc/testutils/opa/filterbar/Actions.js +36 -0
- package/test/sap/ui/mdc/testutils/opa/filterfield/Actions.js +20 -3
- package/test/sap/ui/mdc/testutils/opa/valueHelp/Actions.js +33 -1
|
@@ -17,7 +17,7 @@ sap.ui.define([
|
|
|
17
17
|
* Enhances a FilterBar control prototype methods for properly handling layout changes in FilterBar controls.
|
|
18
18
|
*
|
|
19
19
|
* @author SAP SE
|
|
20
|
-
* @version 1.
|
|
20
|
+
* @version 1.143.0
|
|
21
21
|
* @alias sap.ui.mdc.mixin.FilterBarLayoutMixin
|
|
22
22
|
* @namespace
|
|
23
23
|
* @since 1.141.0
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* OpenUI5
|
|
3
|
+
* (c) Copyright 2025 SAP SE or an SAP affiliate company.
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
sap.ui.define([
|
|
8
|
+
"../../GeomapDelegate", 'sap/ui/mdc/odata/v4/TypeMap'
|
|
9
|
+
], (
|
|
10
|
+
GeomapDelegate,
|
|
11
|
+
ODataV4TypeMap
|
|
12
|
+
) => {
|
|
13
|
+
"use strict";
|
|
14
|
+
/**
|
|
15
|
+
* Delegate class for {@link sap.ui.mdc.Geomap Geomap} and ODataV4.<br>
|
|
16
|
+
* This class provides method calls, which are called by the <code>Geomap</code> at specific operations and allows to overwrite an internal behaviour.
|
|
17
|
+
*
|
|
18
|
+
* @namespace
|
|
19
|
+
* @author SAP SE
|
|
20
|
+
* @alias module:sap/ui/mdc/odata/v4/GeomapDelegate
|
|
21
|
+
* @extends module:sap/ui/mdc/GeomapDelegate
|
|
22
|
+
* @since 1.140
|
|
23
|
+
*
|
|
24
|
+
* @experimental
|
|
25
|
+
* @private
|
|
26
|
+
* @ui5-restricted sap.fe, sap.ui.mdc
|
|
27
|
+
*
|
|
28
|
+
*/
|
|
29
|
+
const Delegate = Object.assign({}, GeomapDelegate);
|
|
30
|
+
|
|
31
|
+
Delegate.getTypeMap = function(oPayload) {
|
|
32
|
+
return ODataV4TypeMap;
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Creates an MDC geomap Item for given property.
|
|
37
|
+
* @param {string} sPropertyName the name of the property in the propertyInfo object.
|
|
38
|
+
* @param {sap.ui.mdc.Geomap} oGeomap Reference to the MDC geomap
|
|
39
|
+
* @param {string} sRole Role of the new item (if available)
|
|
40
|
+
* @returns {Promise<sap.ui.mdc.geomap.Item>} Created MDC Item
|
|
41
|
+
*
|
|
42
|
+
* @experimental
|
|
43
|
+
* @private
|
|
44
|
+
* @ui5-restricted sap.fe, sap.ui.mdc
|
|
45
|
+
*/
|
|
46
|
+
Delegate._createMDCChartItem = function(sPropertyName, oGeomap, sRole) {
|
|
47
|
+
|
|
48
|
+
return this._getPropertyInfosByName(sPropertyName, oGeomap).then((oPropertyInfo) => {
|
|
49
|
+
if (!oPropertyInfo) {
|
|
50
|
+
return null;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
return this._createMDCItemFromProperty(oPropertyInfo, oGeomap.getId(), sRole);
|
|
54
|
+
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
return Delegate;
|
|
60
|
+
});
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
sap.ui.define([
|
|
8
8
|
"../../TableDelegate",
|
|
9
9
|
"../../table/ODataV4PropertyHelper",
|
|
10
|
+
"sap/ui/mdc/Table",
|
|
10
11
|
"sap/ui/mdc/enums/TableP13nMode",
|
|
11
12
|
"sap/ui/mdc/enums/TableType",
|
|
12
13
|
"sap/ui/mdc/enums/TableSelectionMode",
|
|
@@ -19,6 +20,7 @@ sap.ui.define([
|
|
|
19
20
|
], (
|
|
20
21
|
TableDelegate,
|
|
21
22
|
ODataV4PropertyHelper,
|
|
23
|
+
Table,
|
|
22
24
|
P13nMode,
|
|
23
25
|
TableType,
|
|
24
26
|
SelectionMode,
|
|
@@ -55,7 +57,7 @@ sap.ui.define([
|
|
|
55
57
|
* @public
|
|
56
58
|
*/
|
|
57
59
|
|
|
58
|
-
|
|
60
|
+
/*
|
|
59
61
|
* restricted for sap.fe (there's no way to make a property of a type private, therefore it's defined outside of the typedef)
|
|
60
62
|
* TODO: Rename to "contextDefiningProperties" before making it public.
|
|
61
63
|
* property {string[]} [extension.additionalProperties]
|
|
@@ -231,6 +233,36 @@ sap.ui.define([
|
|
|
231
233
|
return aSorters;
|
|
232
234
|
};
|
|
233
235
|
|
|
236
|
+
/**
|
|
237
|
+
* Extracts the model name and path from a binding path string.
|
|
238
|
+
*
|
|
239
|
+
* @param {string} sPath The binding path that might contain a model name (e.g. "myModel>/Products" or "/Products")
|
|
240
|
+
* @returns {{modelName: string, path: string}} Model name and path
|
|
241
|
+
*/
|
|
242
|
+
function extractModelNameAndPath(sPath) {
|
|
243
|
+
const aMatch = sPath?.match(/^([^>]+)>(.*)$/);
|
|
244
|
+
|
|
245
|
+
if (aMatch) {
|
|
246
|
+
return {modelName: aMatch[1], path: aMatch[2]};
|
|
247
|
+
} else {
|
|
248
|
+
return {modelName: undefined, path: sPath};
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
/**
|
|
253
|
+
* Compares two binding paths, taking into account that one might contain a model name while the other doesn't.
|
|
254
|
+
*
|
|
255
|
+
* @param {string} sPath1 The first path to compare
|
|
256
|
+
* @param {string} sPath2 The second path to compare
|
|
257
|
+
* @returns {boolean} Whether the paths are different
|
|
258
|
+
*/
|
|
259
|
+
function hasPathChanged(sPath1, sPath2) {
|
|
260
|
+
const oPath1 = extractModelNameAndPath(sPath1);
|
|
261
|
+
const oPath2 = extractModelNameAndPath(sPath2);
|
|
262
|
+
|
|
263
|
+
return oPath1.path !== oPath2.path;
|
|
264
|
+
}
|
|
265
|
+
|
|
234
266
|
/**
|
|
235
267
|
* Updates the binding of the table with the binding info object returned from
|
|
236
268
|
* {@link module:sap/ui/mdc/TableDelegate.updateBindingInfo updateBindingInfo}. If an update is not possible, it rebinds the table.
|
|
@@ -262,7 +294,7 @@ sap.ui.define([
|
|
|
262
294
|
oModel.setProperty("/@custom/hasGrandTotal", false);
|
|
263
295
|
}
|
|
264
296
|
|
|
265
|
-
if (!oBinding || oBinding.getPath()
|
|
297
|
+
if (!oBinding || hasPathChanged(oBinding.getPath(), oBindingInfo.path)) {
|
|
266
298
|
this.rebind(oTable, oBindingInfo);
|
|
267
299
|
return;
|
|
268
300
|
}
|
|
@@ -302,6 +334,21 @@ sap.ui.define([
|
|
|
302
334
|
}
|
|
303
335
|
};
|
|
304
336
|
|
|
337
|
+
/**
|
|
338
|
+
* @inheritDoc
|
|
339
|
+
*/
|
|
340
|
+
Delegate.rebind = function(oTable, oBindingInfo) {
|
|
341
|
+
Table._addBindingListener(oBindingInfo, "createActivate", () => {
|
|
342
|
+
Promise.resolve().then(() => { // The count is updated after the event is fired
|
|
343
|
+
oTable._updateRowCountForHeader();
|
|
344
|
+
});
|
|
345
|
+
});
|
|
346
|
+
Table._addBindingListener(oBindingInfo, "createCompleted", () => {
|
|
347
|
+
oTable._updateRowCountForHeader();
|
|
348
|
+
});
|
|
349
|
+
TableDelegate.rebind.apply(this, arguments);
|
|
350
|
+
};
|
|
351
|
+
|
|
305
352
|
Delegate.fetchExpandAndCollapseConfiguration = function(oTable) {
|
|
306
353
|
if (!oTable._isOfType(TableType.TreeTable)) {
|
|
307
354
|
return Promise.resolve({});
|
|
@@ -809,6 +856,10 @@ sap.ui.define([
|
|
|
809
856
|
for (const sPropertyKey of aVisiblePropertyKeys) {
|
|
810
857
|
const oProperty = oPropertyHelper.getProperty(sPropertyKey);
|
|
811
858
|
|
|
859
|
+
if (!oProperty) {
|
|
860
|
+
continue;
|
|
861
|
+
}
|
|
862
|
+
|
|
812
863
|
if (oProperty.extension.technicallyGroupable) {
|
|
813
864
|
addGroupablePropertyTo$$Aggregation(mAggregation, oTable, oProperty);
|
|
814
865
|
}
|
|
@@ -1107,6 +1107,14 @@ sap.ui.define([
|
|
|
1107
1107
|
vizProperties: {
|
|
1108
1108
|
plotArea: {
|
|
1109
1109
|
scrollbar: { forceToShowInMobile: true }
|
|
1110
|
+
},
|
|
1111
|
+
tooltip: {
|
|
1112
|
+
formatString: null
|
|
1113
|
+
},
|
|
1114
|
+
valueAxis: {
|
|
1115
|
+
label: {
|
|
1116
|
+
formatString: null
|
|
1117
|
+
}
|
|
1110
1118
|
}
|
|
1111
1119
|
}
|
|
1112
1120
|
}));
|
|
@@ -1187,6 +1195,14 @@ sap.ui.define([
|
|
|
1187
1195
|
oChartImplementationContainer.setShowNoDataStruct(true);
|
|
1188
1196
|
|
|
1189
1197
|
const oError = aUnAvailableCharts[iUnavailableIndex].error;
|
|
1198
|
+
const oTypeButton = oIllustratedMessage?.getAdditionalContent()[1];
|
|
1199
|
+
const bIsTypeButton = oTypeButton?.isA("sap.m.Button") && oTypeButton?.getText() === this._oMDCRb.getText("chart.SELECT_ANOTHER_CHART_TYPE");
|
|
1200
|
+
if (bIsTypeButton && oInnerChart._getVisibleMeasures()?.length === 0) {
|
|
1201
|
+
oError["Measure"] = 0;
|
|
1202
|
+
oTypeButton.setVisible(false);
|
|
1203
|
+
} else {
|
|
1204
|
+
oTypeButton.setVisible(true);
|
|
1205
|
+
}
|
|
1190
1206
|
this._sErrorMsg = ChartUtil.getErrorMessageForMissingMeasuresAndDimensions(sChartType, oError);
|
|
1191
1207
|
oIllustratedMessage.setDescription(this._sErrorMsg);
|
|
1192
1208
|
this._bInvalidChartType = true;
|
|
@@ -111,7 +111,7 @@ sap.ui.define([
|
|
|
111
111
|
* Retrieves the externalized state for a given control instance.
|
|
112
112
|
* The retrieved state is equivalent to the <code>getCurrentState</code> API for the given control,
|
|
113
113
|
* after all necessary changes have been applied (for example, variant appliance and <code>p13n, StateUtil</code> changes).
|
|
114
|
-
* After the returned <code>Promise</code> has been resolved, the returned state is in sync with the
|
|
114
|
+
* After the returned <code>Promise</code> has been resolved, the returned state is in sync with the corresponding
|
|
115
115
|
* state object of the MDC control (for example, <code>filterConditions</code> for the <code>FilterBar</code> control).
|
|
116
116
|
*
|
|
117
117
|
* @public
|
|
@@ -4,178 +4,209 @@
|
|
|
4
4
|
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
|
|
5
5
|
*/
|
|
6
6
|
sap.ui.define([
|
|
7
|
-
"sap/ui/support/library"
|
|
8
|
-
|
|
7
|
+
"sap/ui/support/library",
|
|
8
|
+
"sap/base/Log"
|
|
9
|
+
], (
|
|
10
|
+
SupportLibrary,
|
|
11
|
+
Log
|
|
12
|
+
) => {
|
|
9
13
|
"use strict";
|
|
10
14
|
|
|
11
|
-
const Categories = SupportLibrary
|
|
12
|
-
const Severity = SupportLibrary.Severity;
|
|
13
|
-
const Audiences = SupportLibrary.Audiences;
|
|
15
|
+
const {Categories, Severity, Audiences} = SupportLibrary;
|
|
14
16
|
|
|
15
|
-
|
|
16
|
-
id
|
|
17
|
+
const oHeaderVisibleWhenToolbarHidden = {
|
|
18
|
+
id: "HeaderVisibleWhenToolbarHidden",
|
|
17
19
|
audiences: [Audiences.Control],
|
|
18
20
|
categories: [Categories.Accessibility],
|
|
19
21
|
enabled: true,
|
|
20
22
|
minversion: "1.121",
|
|
21
|
-
title: "Header visibility",
|
|
22
|
-
description: "Checks
|
|
23
|
-
resolution: "Set the
|
|
23
|
+
title: "Header visibility when the toolbar is hidden",
|
|
24
|
+
description: "Checks 'headerVisible' when the toolbar is hidden",
|
|
25
|
+
resolution: "Set the 'headerVisible' property of the 'sap.ui.mdc.Table' to false",
|
|
24
26
|
resolutionurls: [],
|
|
25
27
|
check: function (oIssueManager, oCoreFacade, oScope) {
|
|
26
|
-
oScope.getElementsByClassName("sap.ui.mdc.Table")
|
|
27
|
-
.
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
});
|
|
28
|
+
oScope.getElementsByClassName("sap.ui.mdc.Table").forEach((oTable) => {
|
|
29
|
+
if (oTable.getHideToolbar() && oTable.getHeaderVisible()) {
|
|
30
|
+
oIssueManager.addIssue({
|
|
31
|
+
severity: Severity.High,
|
|
32
|
+
details: "'headerVisible' is true but toolbar is hidden.",
|
|
33
|
+
context: {
|
|
34
|
+
id: oTable.getId()
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
});
|
|
38
39
|
}
|
|
39
40
|
};
|
|
40
41
|
|
|
41
|
-
const
|
|
42
|
-
id
|
|
42
|
+
const oShowRowCountWhenToolbarHidden = {
|
|
43
|
+
id: "ShowRowCountWhenToolbarHidden",
|
|
43
44
|
audiences: [Audiences.Control],
|
|
44
45
|
categories: [Categories.Accessibility],
|
|
45
46
|
enabled: true,
|
|
46
47
|
minversion: "1.121",
|
|
47
|
-
title: "
|
|
48
|
-
description: "Checks
|
|
49
|
-
resolution: "Set
|
|
48
|
+
title: "Showing row count when the toolbar is hidden",
|
|
49
|
+
description: "Checks 'showRowCount' when the toolbar is hidden",
|
|
50
|
+
resolution: "Set the 'showRowCount' property of the 'sap.ui.mdc.Table' to false",
|
|
50
51
|
resolutionurls: [],
|
|
51
|
-
check: function
|
|
52
|
-
oScope.getElementsByClassName("sap.ui.mdc.Table")
|
|
53
|
-
.
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
});
|
|
52
|
+
check: function(oIssueManager, oCoreFacade, oScope) {
|
|
53
|
+
oScope.getElementsByClassName("sap.ui.mdc.Table").forEach((oTable) => {
|
|
54
|
+
if (oTable.getHideToolbar() && oTable.getShowRowCount()) {
|
|
55
|
+
oIssueManager.addIssue({
|
|
56
|
+
severity: Severity.Low,
|
|
57
|
+
details: "'showRowCount' is true but toolbar is hidden.",
|
|
58
|
+
context: {
|
|
59
|
+
id: oTable.getId()
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
64
|
}
|
|
65
65
|
};
|
|
66
66
|
|
|
67
|
-
const
|
|
68
|
-
id
|
|
67
|
+
const oEnableExportWhenToolbarHidden = {
|
|
68
|
+
id: "EnableExportWhenToolbarHidden",
|
|
69
69
|
audiences: [Audiences.Control],
|
|
70
70
|
categories: [Categories.Accessibility],
|
|
71
71
|
enabled: true,
|
|
72
72
|
minversion: "1.121",
|
|
73
|
-
title: "
|
|
74
|
-
description: "Checks
|
|
75
|
-
resolution: "Set the '
|
|
76
|
-
resolutionurls: [
|
|
77
|
-
text: "SAP Fiori Design Guidelines: Illustrated Message",
|
|
78
|
-
href: "https://experience.sap.com/fiori-design-web/illustrated-message/"
|
|
79
|
-
}],
|
|
73
|
+
title: "Export when the toolbar is hidden",
|
|
74
|
+
description: "Checks 'enableExport' when the toolbar is hidden",
|
|
75
|
+
resolution: "Set the 'enableExport' property of the 'sap.ui.mdc.Table' to false",
|
|
76
|
+
resolutionurls: [],
|
|
80
77
|
check: function (oIssueManager, oCoreFacade, oScope) {
|
|
81
|
-
oScope.getElementsByClassName("sap.ui.mdc.Table")
|
|
82
|
-
.
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
});
|
|
78
|
+
oScope.getElementsByClassName("sap.ui.mdc.Table").forEach((oTable) => {
|
|
79
|
+
if (oTable.getHideToolbar() && oTable.getEnableExport()) {
|
|
80
|
+
oIssueManager.addIssue({
|
|
81
|
+
severity: Severity.Low,
|
|
82
|
+
details: "'enableExport' is true but toolbar is hidden.",
|
|
83
|
+
context: {
|
|
84
|
+
id: oTable.getId()
|
|
85
|
+
}
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
});
|
|
93
89
|
}
|
|
94
90
|
};
|
|
95
91
|
|
|
96
|
-
const
|
|
97
|
-
id
|
|
92
|
+
const oToolbarElementsWhenToolbarHidden = {
|
|
93
|
+
id: "ToolbarElementsWhenToolbarHidden",
|
|
98
94
|
audiences: [Audiences.Control],
|
|
99
95
|
categories: [Categories.Accessibility],
|
|
100
96
|
enabled: true,
|
|
101
97
|
minversion: "1.121",
|
|
102
|
-
title: "
|
|
103
|
-
description: "Checks whether the '
|
|
104
|
-
resolution: "
|
|
98
|
+
title: "Actions, quickFilter, and a table-related VariantManagement when the toolbar is hidden",
|
|
99
|
+
description: "Checks whether the 'actions', 'quickFilter', and 'variant' aggregations are used when the toolbar is hidden",
|
|
100
|
+
resolution: "Remove 'actions', 'quickFilter', and 'variants' aggregations from the 'sap.ui.mdc.Table'",
|
|
105
101
|
resolutionurls: [],
|
|
106
102
|
check: function (oIssueManager, oCoreFacade, oScope) {
|
|
107
|
-
oScope.getElementsByClassName("sap.ui.mdc.Table")
|
|
108
|
-
.
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
103
|
+
oScope.getElementsByClassName("sap.ui.mdc.Table").forEach((oTable) => {
|
|
104
|
+
const bActions = (oTable.getActions() !== undefined && oTable.getActions() !== null && oTable.getActions().length !== 0);
|
|
105
|
+
const bVariant = (oTable.getVariant() !== undefined && oTable.getVariant() !== null && oTable.getVariant().length !== 0);
|
|
106
|
+
const bQuickFilter = (oTable.getQuickFilter() !== undefined && oTable.getQuickFilter() !== null && oTable.getQuickFilter().length !== 0);
|
|
107
|
+
|
|
108
|
+
if (oTable.getHideToolbar() && (bActions || bVariant || bQuickFilter)) {
|
|
109
|
+
oIssueManager.addIssue({
|
|
110
|
+
severity: Severity.High,
|
|
111
|
+
details: "'actions', 'quickFilter', and 'variant' aggregations are not empty.",
|
|
112
|
+
context: {
|
|
113
|
+
id: oTable.getId()
|
|
114
|
+
}
|
|
115
|
+
});
|
|
116
|
+
}
|
|
117
|
+
});
|
|
119
118
|
}
|
|
120
119
|
};
|
|
121
120
|
|
|
122
|
-
const
|
|
123
|
-
id
|
|
121
|
+
const oHeader = {
|
|
122
|
+
id: "Header",
|
|
124
123
|
audiences: [Audiences.Control],
|
|
125
124
|
categories: [Categories.Accessibility],
|
|
126
125
|
enabled: true,
|
|
127
126
|
minversion: "1.121",
|
|
128
|
-
title: "
|
|
129
|
-
description: "Checks
|
|
130
|
-
resolution: "
|
|
127
|
+
title: "Table header value",
|
|
128
|
+
description: "Checks if the table 'header' is set",
|
|
129
|
+
resolution: "Set a table title via the 'header' property of the 'sap.ui.mdc.Table'",
|
|
131
130
|
resolutionurls: [],
|
|
132
131
|
check: function (oIssueManager, oCoreFacade, oScope) {
|
|
133
|
-
oScope.getElementsByClassName("sap.ui.mdc.Table")
|
|
134
|
-
.
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
context: {
|
|
145
|
-
id: oElement.getId()
|
|
146
|
-
}
|
|
147
|
-
});
|
|
148
|
-
}
|
|
149
|
-
});
|
|
132
|
+
oScope.getElementsByClassName("sap.ui.mdc.Table").forEach((oTable) => {
|
|
133
|
+
if (!oTable.getHeader()) {
|
|
134
|
+
oIssueManager.addIssue({
|
|
135
|
+
severity: Severity.High,
|
|
136
|
+
details: "Header isn't set. Set a title in the header property.",
|
|
137
|
+
context: {
|
|
138
|
+
id: oTable.getId()
|
|
139
|
+
}
|
|
140
|
+
});
|
|
141
|
+
}
|
|
142
|
+
});
|
|
150
143
|
}
|
|
151
144
|
};
|
|
152
145
|
|
|
153
|
-
const
|
|
154
|
-
id
|
|
146
|
+
const oIllustratedMessageForNoData = {
|
|
147
|
+
id: "IllustratedMessageForNoData",
|
|
155
148
|
audiences: [Audiences.Control],
|
|
156
149
|
categories: [Categories.Accessibility],
|
|
157
150
|
enabled: true,
|
|
158
151
|
minversion: "1.121",
|
|
159
|
-
title: "
|
|
160
|
-
description: "Checks
|
|
161
|
-
resolution: "Set the '
|
|
162
|
-
resolutionurls: [
|
|
152
|
+
title: "IllustratedMessage for noData",
|
|
153
|
+
description: "Checks whether 'noData' is an 'IllustratedMessage' when the toolbar is hidden",
|
|
154
|
+
resolution: "Set the 'noData' aggregation of the 'sap.ui.mdc.Table' to an 'sap.m.IllustratedMessage'",
|
|
155
|
+
resolutionurls: [{
|
|
156
|
+
text: "SAP Fiori Design Guidelines: Illustrated Message",
|
|
157
|
+
href: "https://experience.sap.com/fiori-design-web/illustrated-message/"
|
|
158
|
+
}],
|
|
163
159
|
check: function (oIssueManager, oCoreFacade, oScope) {
|
|
164
|
-
oScope.getElementsByClassName("sap.ui.mdc.Table")
|
|
165
|
-
.
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
160
|
+
oScope.getElementsByClassName("sap.ui.mdc.Table").forEach((oTable) => {
|
|
161
|
+
if (oTable.getHideToolbar() && (!oTable.getNoData() || !oTable.getNoData().isA("sap.m.IllustratedMessage"))) {
|
|
162
|
+
oIssueManager.addIssue({
|
|
163
|
+
severity: Severity.High,
|
|
164
|
+
details: "'noData' aggregation is either not set or no 'sap.m.IllustratedMessage' control is used.",
|
|
165
|
+
context: {
|
|
166
|
+
id: oTable.getId()
|
|
167
|
+
}
|
|
168
|
+
});
|
|
169
|
+
}
|
|
170
|
+
});
|
|
171
|
+
}
|
|
172
|
+
};
|
|
173
|
+
|
|
174
|
+
const oStateValidation = {
|
|
175
|
+
id: "StateValidation",
|
|
176
|
+
audiences: [Audiences.Control],
|
|
177
|
+
categories: [Categories.Functionality],
|
|
178
|
+
enabled: true,
|
|
179
|
+
minversion: "1.141",
|
|
180
|
+
title: "Table reports invalid state modifications",
|
|
181
|
+
description: "The table contains state modifications, for example sort conditions, for non-existent PropertyInfo properties",
|
|
182
|
+
resolution: "Remove the invalid state modifications or add the missing PropertyInfo properties",
|
|
183
|
+
check: function(oIssueManager, oCoreFacade, oScope) {
|
|
184
|
+
oScope.getElementsByClassName("sap.ui.mdc.Table").forEach((oTable) => {
|
|
185
|
+
Log.getLogEntries().filter((oLogEntry) =>
|
|
186
|
+
oLogEntry.details === oTable.toString()
|
|
187
|
+
&& oLogEntry.level === Log.Level.ERROR
|
|
188
|
+
&& oLogEntry.message.startsWith("Invalid state:")
|
|
189
|
+
).forEach((oLogEntry) => {
|
|
190
|
+
oIssueManager.addIssue({
|
|
191
|
+
severity: Severity.High,
|
|
192
|
+
details: oLogEntry.message,
|
|
193
|
+
context: {
|
|
194
|
+
id: oTable.getId()
|
|
195
|
+
}
|
|
196
|
+
});
|
|
175
197
|
});
|
|
198
|
+
});
|
|
176
199
|
}
|
|
177
200
|
};
|
|
178
201
|
|
|
179
|
-
return [
|
|
202
|
+
return [
|
|
203
|
+
oHeaderVisibleWhenToolbarHidden,
|
|
204
|
+
oShowRowCountWhenToolbarHidden,
|
|
205
|
+
oEnableExportWhenToolbarHidden,
|
|
206
|
+
oToolbarElementsWhenToolbarHidden,
|
|
207
|
+
oHeader,
|
|
208
|
+
oIllustratedMessageForNoData,
|
|
209
|
+
oStateValidation
|
|
210
|
+
];
|
|
180
211
|
|
|
181
212
|
}, true);
|