@openui5/sap.ui.table 1.110.0 → 1.111.1
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 +3 -3
- package/src/sap/ui/table/.library +1 -1
- package/src/sap/ui/table/AnalyticalColumn.js +1 -1
- package/src/sap/ui/table/AnalyticalColumnMenu.js +1 -1
- package/src/sap/ui/table/AnalyticalTable.js +1 -1
- package/src/sap/ui/table/Column.js +12 -3
- package/src/sap/ui/table/ColumnMenu.js +1 -1
- package/src/sap/ui/table/CreationRow.js +1 -1
- package/src/sap/ui/table/Row.js +1 -1
- package/src/sap/ui/table/RowAction.js +1 -1
- package/src/sap/ui/table/RowActionItem.js +1 -1
- package/src/sap/ui/table/RowSettings.js +1 -1
- package/src/sap/ui/table/Table.js +8 -11
- package/src/sap/ui/table/TablePersoController.js +1 -1
- package/src/sap/ui/table/TreeTable.js +1 -1
- package/src/sap/ui/table/extensions/Accessibility.js +1 -1
- package/src/sap/ui/table/extensions/AccessibilityRender.js +1 -1
- package/src/sap/ui/table/extensions/DragAndDrop.js +9 -1
- package/src/sap/ui/table/extensions/ExtensionBase.js +1 -1
- package/src/sap/ui/table/extensions/Keyboard.js +1 -1
- package/src/sap/ui/table/extensions/KeyboardDelegate.js +9 -3
- package/src/sap/ui/table/extensions/Pointer.js +1 -1
- package/src/sap/ui/table/extensions/Scrolling.js +1 -1
- package/src/sap/ui/table/extensions/ScrollingIOS.js +1 -1
- package/src/sap/ui/table/extensions/Synchronization.js +1 -1
- package/src/sap/ui/table/library.js +10 -10
- package/src/sap/ui/table/menus/ColumnHeaderMenuAdapter.js +1 -1
- package/src/sap/ui/table/menus/MobileColumnHeaderMenuAdapter.js +1 -1
- package/src/sap/ui/table/plugins/BindingSelection.js +11 -3
- package/src/sap/ui/table/plugins/MultiSelectionPlugin.js +12 -25
- package/src/sap/ui/table/plugins/PluginBase.js +1 -1
- package/src/sap/ui/table/plugins/SelectionModelSelection.js +5 -2
- package/src/sap/ui/table/plugins/SelectionPlugin.js +1 -1
- package/src/sap/ui/table/plugins/V4Aggregation.js +1 -1
- package/src/sap/ui/table/rowmodes/AutoRowMode.js +1 -1
- package/src/sap/ui/table/rowmodes/FixedRowMode.js +1 -1
- package/src/sap/ui/table/rowmodes/InteractiveRowMode.js +1 -1
- package/src/sap/ui/table/rowmodes/RowMode.js +15 -7
- package/src/sap/ui/table/rowmodes/VariableRowMode.js +1 -1
- package/src/sap/ui/table/utils/TableUtils.js +1 -1
- package/src/sap/ui/table/utils/_BindingUtils.js +1 -1
- package/src/sap/ui/table/utils/_ColumnUtils.js +9 -5
- package/src/sap/ui/table/utils/_GroupingUtils.js +1 -1
- package/src/sap/ui/table/utils/_HookUtils.js +1 -1
- package/src/sap/ui/table/utils/_MenuUtils.js +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openui5/sap.ui.table",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.111.1",
|
|
4
4
|
"description": "OpenUI5 UI Library sap.ui.table",
|
|
5
5
|
"author": "SAP SE (https://www.sap.com)",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"url": "https://github.com/SAP/openui5.git"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@openui5/sap.ui.core": "1.
|
|
18
|
-
"@openui5/sap.ui.unified": "1.
|
|
17
|
+
"@openui5/sap.ui.core": "1.111.1",
|
|
18
|
+
"@openui5/sap.ui.unified": "1.111.1"
|
|
19
19
|
}
|
|
20
20
|
}
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
<copyright>OpenUI5
|
|
7
7
|
* (c) Copyright 2009-2023 SAP SE or an SAP affiliate company.
|
|
8
8
|
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.</copyright>
|
|
9
|
-
<version>1.
|
|
9
|
+
<version>1.111.1</version>
|
|
10
10
|
|
|
11
11
|
<documentation>Table-like controls, mainly for desktop scenarios.</documentation>
|
|
12
12
|
|
|
@@ -72,7 +72,7 @@ sap.ui.define([
|
|
|
72
72
|
* @class
|
|
73
73
|
* The column allows you to define column specific properties that will be applied when rendering the table.
|
|
74
74
|
* @extends sap.ui.core.Element
|
|
75
|
-
* @version 1.
|
|
75
|
+
* @version 1.111.1
|
|
76
76
|
*
|
|
77
77
|
* @constructor
|
|
78
78
|
* @public
|
|
@@ -328,7 +328,7 @@ sap.ui.define([
|
|
|
328
328
|
/**
|
|
329
329
|
* The menu that can be opened by the header element of this column.
|
|
330
330
|
*
|
|
331
|
-
* @since 1.
|
|
331
|
+
* @since 1.110
|
|
332
332
|
*/
|
|
333
333
|
headerMenu: {type: "sap.ui.core.IColumnHeaderMenu", multiple: false}
|
|
334
334
|
},
|
|
@@ -1230,6 +1230,15 @@ sap.ui.define([
|
|
|
1230
1230
|
}
|
|
1231
1231
|
};
|
|
1232
1232
|
|
|
1233
|
+
/**
|
|
1234
|
+
* A hook getting called by the DragInfo to determine whether the column allows dragging.
|
|
1235
|
+
* @param {sap.ui.core.dnd.IDragInfo} oDragInfo drag information
|
|
1236
|
+
* @private
|
|
1237
|
+
*/
|
|
1238
|
+
Column.prototype.isDragAllowed = function(oDragInfo) {
|
|
1239
|
+
return TableUtils.Column.isColumnMovable(this, true);
|
|
1240
|
+
};
|
|
1241
|
+
|
|
1233
1242
|
/**
|
|
1234
1243
|
* Returns an unused column template clone. Unused means, it does not have a parent.
|
|
1235
1244
|
*
|
|
@@ -1380,7 +1389,7 @@ sap.ui.define([
|
|
|
1380
1389
|
* @private
|
|
1381
1390
|
*/
|
|
1382
1391
|
Column.prototype.getHeaderMenuInstance = function() {
|
|
1383
|
-
return Core.byId(this.
|
|
1392
|
+
return Core.byId(this.getHeaderMenu());
|
|
1384
1393
|
};
|
|
1385
1394
|
|
|
1386
1395
|
function validateCellContentVisibilitySettings(mSettings) {
|
package/src/sap/ui/table/Row.js
CHANGED
|
@@ -35,7 +35,7 @@ sap.ui.define([
|
|
|
35
35
|
* If more action items are available as the available space allows to display an overflow mechanism is provided.
|
|
36
36
|
* This control must only be used in the context of the <code>sap.ui.table.Table</code> control to define row actions.
|
|
37
37
|
* @extends sap.ui.core.Control
|
|
38
|
-
* @version 1.
|
|
38
|
+
* @version 1.111.1
|
|
39
39
|
*
|
|
40
40
|
* @constructor
|
|
41
41
|
* @public
|
|
@@ -24,7 +24,7 @@ sap.ui.define([
|
|
|
24
24
|
* The <code>RowSettings</code> control allows you to configure a row.
|
|
25
25
|
* You can only use this control in the context of the <code>sap.ui.table.Table</code> control to define row settings.
|
|
26
26
|
* @extends sap.ui.core.Element
|
|
27
|
-
* @version 1.
|
|
27
|
+
* @version 1.111.1
|
|
28
28
|
*
|
|
29
29
|
* @constructor
|
|
30
30
|
* @public
|
|
@@ -92,7 +92,7 @@ sap.ui.define([
|
|
|
92
92
|
* the data model and binding being used.
|
|
93
93
|
* </p>
|
|
94
94
|
* @extends sap.ui.core.Control
|
|
95
|
-
* @version 1.
|
|
95
|
+
* @version 1.111.1
|
|
96
96
|
*
|
|
97
97
|
* @constructor
|
|
98
98
|
* @public
|
|
@@ -1019,10 +1019,12 @@ sap.ui.define([
|
|
|
1019
1019
|
* @inheritDoc
|
|
1020
1020
|
*/
|
|
1021
1021
|
Table.prototype.applySettings = function(mSettings, oScope) {
|
|
1022
|
+
// The threshold must be set before the OData binding for the "rows" aggregation is initialized. If the metadata is already loaded, a
|
|
1023
|
+
// getContexts call may be triggered immediately with the default threshold (100) instead of the one in the settings.
|
|
1022
1024
|
// Some settings might rely on the existence of a row mode or plugin. If row modes and plugins are in the settings and applied before
|
|
1023
1025
|
// other settings, initialization of legacy row modes and plugins can be avoided.
|
|
1024
1026
|
if (mSettings) {
|
|
1025
|
-
var aEarlySettings = ["rowMode", "plugins"];
|
|
1027
|
+
var aEarlySettings = ["threshold", "rowMode", "plugins"];
|
|
1026
1028
|
var mEarlySettings = {};
|
|
1027
1029
|
|
|
1028
1030
|
for (var i = 0; i < aEarlySettings.length; i++) {
|
|
@@ -1577,19 +1579,14 @@ sap.ui.define([
|
|
|
1577
1579
|
var oDummyColumn = this.getDomRef("dummycolhdr");
|
|
1578
1580
|
|
|
1579
1581
|
if (oDummyColumn) {
|
|
1580
|
-
// This complexity is required because of Chrome's zoom math.
|
|
1581
|
-
var oTableElement = this.getDomRef("header");
|
|
1582
|
-
var iTableWidth = oTableElement.clientWidth;
|
|
1583
1582
|
var iColumnsWidth = this.getColumns().reduce(function(iColumnsWidth, oColumn) {
|
|
1584
|
-
|
|
1585
|
-
|
|
1583
|
+
var oDomRef = oColumn.getDomRef();
|
|
1584
|
+
if (oDomRef && oColumn.getIndex() >= this.getComputedFixedColumnCount()) {
|
|
1585
|
+
iColumnsWidth += oDomRef.offsetWidth;
|
|
1586
1586
|
}
|
|
1587
1587
|
return iColumnsWidth;
|
|
1588
1588
|
}.bind(this), 0);
|
|
1589
|
-
var bDummyColumnHasWidth =
|
|
1590
|
-
// when the column widths contain subpixels, iTableWidth might be higher than iColumnsWidth
|
|
1591
|
-
// for just a fraction of a pixel even though no dummy column is needed. To avoid left positioning
|
|
1592
|
-
// of the row actions instead of absolute right, the calculation is adjusted with +1 pixel.
|
|
1589
|
+
var bDummyColumnHasWidth = oDummyColumn.clientWidth > 0;
|
|
1593
1590
|
|
|
1594
1591
|
if (!bHasFlexibleRowActions && bDummyColumnHasWidth) {
|
|
1595
1592
|
var iRowActionPos = iColumnsWidth + oTableSizes.tableRowHdrScrWidth + oTableSizes.tableCtrlFixedWidth;
|
|
@@ -929,7 +929,7 @@ sap.ui.define([
|
|
|
929
929
|
* @class Extension for sap.ui.table.Table which handles ACC related things.
|
|
930
930
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
931
931
|
* @author SAP SE
|
|
932
|
-
* @version 1.
|
|
932
|
+
* @version 1.111.1
|
|
933
933
|
* @constructor
|
|
934
934
|
* @private
|
|
935
935
|
* @alias sap.ui.table.extensions.Accessibility
|
|
@@ -42,7 +42,7 @@ sap.ui.define([
|
|
|
42
42
|
* @class Extension for sap.ui.table.TableRenderer which handles ACC related things.
|
|
43
43
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
44
44
|
* @author SAP SE
|
|
45
|
-
* @version 1.
|
|
45
|
+
* @version 1.111.1
|
|
46
46
|
* @constructor
|
|
47
47
|
* @private
|
|
48
48
|
* @alias sap.ui.table.extensions.AccessibilityRender
|
|
@@ -137,6 +137,14 @@ sap.ui.define([
|
|
|
137
137
|
}
|
|
138
138
|
}
|
|
139
139
|
} else if (oDropControl.isA("sap.ui.table.Column")) {
|
|
140
|
+
var iTargetColumnIndex = TableUtils.getCellInfo(TableUtils.getCell(this, oEvent.target)).columnIndex;
|
|
141
|
+
|
|
142
|
+
if (oDraggedControl.isA("sap.ui.table.Column")
|
|
143
|
+
&& !TableUtils.Column.isColumnMovableTo(oDraggedControl, iTargetColumnIndex, true)) {
|
|
144
|
+
oEvent.setMarked("NonDroppable");
|
|
145
|
+
return;
|
|
146
|
+
}
|
|
147
|
+
|
|
140
148
|
var mTableCntRect = this.getDomRef("sapUiTableCnt").getBoundingClientRect();
|
|
141
149
|
oDragSession.setIndicatorConfig({
|
|
142
150
|
height: mTableCntRect.height - (this._getScrollExtension().isHorizontalScrollbarVisible() ? 16 : 0)
|
|
@@ -244,7 +252,7 @@ sap.ui.define([
|
|
|
244
252
|
*
|
|
245
253
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
246
254
|
* @author SAP SE
|
|
247
|
-
* @version 1.
|
|
255
|
+
* @version 1.111.1
|
|
248
256
|
* @constructor
|
|
249
257
|
* @private
|
|
250
258
|
* @alias sap.ui.table.extensions.DragAndDrop
|
|
@@ -267,7 +267,7 @@ sap.ui.define([
|
|
|
267
267
|
* @class Extension for sap.ui.table.Table which handles keyboard related things.
|
|
268
268
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
269
269
|
* @author SAP SE
|
|
270
|
-
* @version 1.
|
|
270
|
+
* @version 1.111.1
|
|
271
271
|
* @constructor
|
|
272
272
|
* @private
|
|
273
273
|
* @alias sap.ui.table.extensions.Keyboard
|
|
@@ -65,7 +65,7 @@ sap.ui.define([
|
|
|
65
65
|
*
|
|
66
66
|
* @extends sap.ui.base.Object
|
|
67
67
|
* @author SAP SE
|
|
68
|
-
* @version 1.
|
|
68
|
+
* @version 1.111.1
|
|
69
69
|
* @constructor
|
|
70
70
|
* @private
|
|
71
71
|
* @alias sap.ui.table.extensions.KeyboardDelegate
|
|
@@ -996,7 +996,11 @@ sap.ui.define([
|
|
|
996
996
|
|
|
997
997
|
} else if ($Target.hasClass("sapUiTableCtrlAfter")) {
|
|
998
998
|
if (!TableUtils.isNoDataVisible(this)) {
|
|
999
|
-
|
|
999
|
+
if (this._getRowMode().getHideEmptyRows && this._getRowMode().getHideEmptyRows()) {
|
|
1000
|
+
setFocusOnColumnHeaderOfLastFocusedDataCell(this, oEvent);
|
|
1001
|
+
} else {
|
|
1002
|
+
restoreFocusOnLastFocusedDataCell(this, oEvent);
|
|
1003
|
+
}
|
|
1000
1004
|
}
|
|
1001
1005
|
}
|
|
1002
1006
|
|
|
@@ -1271,7 +1275,9 @@ sap.ui.define([
|
|
|
1271
1275
|
}
|
|
1272
1276
|
|
|
1273
1277
|
} else if (oCellInfo.isOfType(CellType.ANYCOLUMNHEADER)) {
|
|
1274
|
-
if (TableUtils.
|
|
1278
|
+
if (this.getCreationRow() && this.getCreationRow().getVisible() && !TableUtils.hasData(this)) {
|
|
1279
|
+
forwardFocusToTabDummy(this, "sapUiTableCtrlAfter");
|
|
1280
|
+
} else if (TableUtils.isNoDataVisible(this)) {
|
|
1275
1281
|
this.$("noDataCnt").trigger("focus");
|
|
1276
1282
|
oEvent.preventDefault();
|
|
1277
1283
|
} else if (this.getRows().length > 0) {
|
|
@@ -803,7 +803,7 @@ sap.ui.define([
|
|
|
803
803
|
* @class Extension for sap.ui.table.Table which handles mouse and touch related things.
|
|
804
804
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
805
805
|
* @author SAP SE
|
|
806
|
-
* @version 1.
|
|
806
|
+
* @version 1.111.1
|
|
807
807
|
* @constructor
|
|
808
808
|
* @private
|
|
809
809
|
* @alias sap.ui.table.extensions.Pointer
|
|
@@ -2256,7 +2256,7 @@ sap.ui.define([
|
|
|
2256
2256
|
* @class Extension for sap.ui.table.Table which handles scrolling.
|
|
2257
2257
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
2258
2258
|
* @author SAP SE
|
|
2259
|
-
* @version 1.
|
|
2259
|
+
* @version 1.111.1
|
|
2260
2260
|
* @constructor
|
|
2261
2261
|
* @private
|
|
2262
2262
|
* @alias sap.ui.table.extensions.Scrolling
|
|
@@ -27,7 +27,7 @@ sap.ui.define([
|
|
|
27
27
|
* @class Extension for sap.ui.table.Table which handles the scrollbar on iOS.
|
|
28
28
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
29
29
|
* @author SAP SE
|
|
30
|
-
* @version 1.
|
|
30
|
+
* @version 1.111.1
|
|
31
31
|
* @constructor
|
|
32
32
|
* @private
|
|
33
33
|
* @alias sap.ui.table.extensions.ScrollingIOS
|
|
@@ -181,7 +181,7 @@ sap.ui.define([
|
|
|
181
181
|
* @class Extension for sap.ui.table.Table that allows synchronization with a table.
|
|
182
182
|
* @extends sap.ui.table.extensions.ExtensionBase
|
|
183
183
|
* @author SAP SE
|
|
184
|
-
* @version 1.
|
|
184
|
+
* @version 1.111.1
|
|
185
185
|
* @constructor
|
|
186
186
|
* @private
|
|
187
187
|
* @alias sap.ui.table.extensions.Synchronization
|
|
@@ -20,13 +20,13 @@ sap.ui.define(['sap/ui/core/Core', 'sap/ui/model/TreeAutoExpandMode',
|
|
|
20
20
|
* @namespace
|
|
21
21
|
* @alias sap.ui.table
|
|
22
22
|
* @author SAP SE
|
|
23
|
-
* @version 1.
|
|
23
|
+
* @version 1.111.1
|
|
24
24
|
* @since 0.8
|
|
25
25
|
* @public
|
|
26
26
|
*/
|
|
27
27
|
var thisLib = sap.ui.getCore().initLibrary({
|
|
28
28
|
name: "sap.ui.table",
|
|
29
|
-
version: "1.
|
|
29
|
+
version: "1.111.1",
|
|
30
30
|
dependencies: ["sap.ui.core", "sap.ui.unified"],
|
|
31
31
|
designtime: "sap/ui/table/designtime/library.designtime",
|
|
32
32
|
types: [
|
|
@@ -80,7 +80,7 @@ sap.ui.define(['sap/ui/core/Core', 'sap/ui/model/TreeAutoExpandMode',
|
|
|
80
80
|
/**
|
|
81
81
|
* Navigation mode of the table
|
|
82
82
|
*
|
|
83
|
-
* @version 1.
|
|
83
|
+
* @version 1.111.1
|
|
84
84
|
* @enum {string}
|
|
85
85
|
* @public
|
|
86
86
|
*/
|
|
@@ -107,7 +107,7 @@ sap.ui.define(['sap/ui/core/Core', 'sap/ui/model/TreeAutoExpandMode',
|
|
|
107
107
|
/**
|
|
108
108
|
* Row Action types.
|
|
109
109
|
*
|
|
110
|
-
* @version 1.
|
|
110
|
+
* @version 1.111.1
|
|
111
111
|
* @enum {string}
|
|
112
112
|
* @public
|
|
113
113
|
*/
|
|
@@ -136,7 +136,7 @@ sap.ui.define(['sap/ui/core/Core', 'sap/ui/model/TreeAutoExpandMode',
|
|
|
136
136
|
/**
|
|
137
137
|
* Selection behavior of the table
|
|
138
138
|
*
|
|
139
|
-
* @version 1.
|
|
139
|
+
* @version 1.111.1
|
|
140
140
|
* @enum {string}
|
|
141
141
|
* @public
|
|
142
142
|
*/
|
|
@@ -165,7 +165,7 @@ sap.ui.define(['sap/ui/core/Core', 'sap/ui/model/TreeAutoExpandMode',
|
|
|
165
165
|
/**
|
|
166
166
|
* Selection mode of the table
|
|
167
167
|
*
|
|
168
|
-
* @version 1.
|
|
168
|
+
* @version 1.111.1
|
|
169
169
|
* @enum {string}
|
|
170
170
|
* @public
|
|
171
171
|
*/
|
|
@@ -201,7 +201,7 @@ sap.ui.define(['sap/ui/core/Core', 'sap/ui/model/TreeAutoExpandMode',
|
|
|
201
201
|
/**
|
|
202
202
|
* Sort order of a column
|
|
203
203
|
*
|
|
204
|
-
* @version 1.
|
|
204
|
+
* @version 1.111.1
|
|
205
205
|
* @enum {string}
|
|
206
206
|
* @public
|
|
207
207
|
*/
|
|
@@ -224,7 +224,7 @@ sap.ui.define(['sap/ui/core/Core', 'sap/ui/model/TreeAutoExpandMode',
|
|
|
224
224
|
/**
|
|
225
225
|
* VisibleRowCountMode of the table
|
|
226
226
|
*
|
|
227
|
-
* @version 1.
|
|
227
|
+
* @version 1.111.1
|
|
228
228
|
* @enum {string}
|
|
229
229
|
* @public
|
|
230
230
|
*/
|
|
@@ -255,7 +255,7 @@ sap.ui.define(['sap/ui/core/Core', 'sap/ui/model/TreeAutoExpandMode',
|
|
|
255
255
|
*
|
|
256
256
|
* Contains IDs of shared DOM references, which should be accessible to inheriting controls via getDomRef() function.
|
|
257
257
|
*
|
|
258
|
-
* @version 1.
|
|
258
|
+
* @version 1.111.1
|
|
259
259
|
* @enum {string}
|
|
260
260
|
* @public
|
|
261
261
|
*/
|
|
@@ -353,7 +353,7 @@ sap.ui.define(['sap/ui/core/Core', 'sap/ui/model/TreeAutoExpandMode',
|
|
|
353
353
|
*
|
|
354
354
|
* This is an alias for {@link sap.ui.model.TreeAutoExpandMode} and kept for compatibility reasons.
|
|
355
355
|
*
|
|
356
|
-
* @version 1.
|
|
356
|
+
* @version 1.111.1
|
|
357
357
|
* @typedef {sap.ui.model.TreeAutoExpandMode}
|
|
358
358
|
* @public
|
|
359
359
|
*/
|
|
@@ -22,7 +22,7 @@ sap.ui.define([
|
|
|
22
22
|
*
|
|
23
23
|
* @class Implements the selection methods for TreeTable and AnalyticalTable
|
|
24
24
|
* @extends sap.ui.table.plugins.SelectionPlugin
|
|
25
|
-
* @version 1.
|
|
25
|
+
* @version 1.111.1
|
|
26
26
|
* @constructor
|
|
27
27
|
* @private
|
|
28
28
|
* @alias sap.ui.table.plugins.BindingSelection
|
|
@@ -175,7 +175,7 @@ sap.ui.define([
|
|
|
175
175
|
|
|
176
176
|
if (!oBinding) {
|
|
177
177
|
return 0;
|
|
178
|
-
} else if (oBinding.
|
|
178
|
+
} else if (oBinding.isA("sap.ui.model.analytics.AnalyticalBinding")) {
|
|
179
179
|
var oRootNode = oBinding.getGrandTotalContextInfo();
|
|
180
180
|
return oRootNode ? oRootNode.totalNumberOfLeafs : 0;
|
|
181
181
|
} else {
|
|
@@ -329,7 +329,15 @@ sap.ui.define([
|
|
|
329
329
|
*/
|
|
330
330
|
BindingSelection.prototype._getHighestSelectableIndex = function() {
|
|
331
331
|
var oBinding = this.getTableBinding();
|
|
332
|
-
|
|
332
|
+
|
|
333
|
+
if (!oBinding) {
|
|
334
|
+
return -1;
|
|
335
|
+
} else if (oBinding.isA("sap.ui.model.analytics.AnalyticalBinding")) {
|
|
336
|
+
var bHasGrandTotal = oBinding.providesGrandTotal() && oBinding.hasTotaledMeasures();
|
|
337
|
+
return oBinding.getLength() - (bHasGrandTotal ? 2 : 1);
|
|
338
|
+
} else {
|
|
339
|
+
return oBinding.getLength() - 1;
|
|
340
|
+
}
|
|
333
341
|
};
|
|
334
342
|
|
|
335
343
|
/**
|
|
@@ -352,7 +352,7 @@ sap.ui.define([
|
|
|
352
352
|
}
|
|
353
353
|
}
|
|
354
354
|
|
|
355
|
-
return
|
|
355
|
+
return loadContexts(oPlugin.getTableBinding(), iGetContextsStartIndex, iGetContextsLength).then(function() {
|
|
356
356
|
return {indexFrom: iIndexFrom, indexTo: iIndexTo};
|
|
357
357
|
});
|
|
358
358
|
}
|
|
@@ -557,33 +557,18 @@ sap.ui.define([
|
|
|
557
557
|
this._oNotificationPopover.close();
|
|
558
558
|
};
|
|
559
559
|
|
|
560
|
-
function
|
|
561
|
-
return new Promise(function(resolve) {
|
|
562
|
-
loadContexts(oBinding, iStartIndex, iLength, resolve);
|
|
563
|
-
});
|
|
564
|
-
}
|
|
565
|
-
|
|
566
|
-
function loadContexts(oBinding, iStartIndex, iLength, fResolve) {
|
|
560
|
+
function loadContexts(oBinding, iStartIndex, iLength) {
|
|
567
561
|
var aContexts = oBinding.getContexts(iStartIndex, iLength, 0, true);
|
|
568
|
-
var
|
|
562
|
+
var bContextsAvailable = aContexts.length === Math.min(iLength, oBinding.getLength()) && !aContexts.includes(undefined);
|
|
569
563
|
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
bLoadItems = true;
|
|
573
|
-
break;
|
|
574
|
-
}
|
|
575
|
-
}
|
|
576
|
-
if (!bLoadItems && !aContexts.dataRequested) {
|
|
577
|
-
fResolve(aContexts);
|
|
578
|
-
return;
|
|
564
|
+
if (bContextsAvailable) {
|
|
565
|
+
return Promise.resolve(aContexts);
|
|
579
566
|
}
|
|
580
567
|
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
}
|
|
585
|
-
loadContexts(oBinding, iStartIndex, iLength, fResolve);
|
|
586
|
-
}
|
|
568
|
+
return new Promise(function(resolve) {
|
|
569
|
+
oBinding.attachEventOnce("dataReceived", function() {
|
|
570
|
+
resolve(loadContexts(oBinding, iStartIndex, iLength));
|
|
571
|
+
});
|
|
587
572
|
});
|
|
588
573
|
}
|
|
589
574
|
|
|
@@ -704,7 +689,9 @@ sap.ui.define([
|
|
|
704
689
|
this.fireSelectionChange({
|
|
705
690
|
rowIndices: aRowIndices,
|
|
706
691
|
limitReached: this.isLimitReached(),
|
|
707
|
-
customPayload: typeof this._oCustomEventPayloadTmp === "object" ? this._oCustomEventPayloadTmp : null
|
|
692
|
+
customPayload: typeof this._oCustomEventPayloadTmp === "object" ? this._oCustomEventPayloadTmp : null,
|
|
693
|
+
// _internalTrigger restricted for sap.ui.comp.valuehelpdialog.ValueHelpDialog and sap.ui.mdc.valuehelp.content.MDCTable
|
|
694
|
+
_internalTrigger: oEvent.getParameter("_internalTrigger")
|
|
708
695
|
});
|
|
709
696
|
};
|
|
710
697
|
|
|
@@ -23,7 +23,7 @@ sap.ui.define([
|
|
|
23
23
|
*
|
|
24
24
|
* @class Implements the selection methods for a Table
|
|
25
25
|
* @extends sap.ui.table.plugins.SelectionPlugin
|
|
26
|
-
* @version 1.
|
|
26
|
+
* @version 1.111.1
|
|
27
27
|
* @constructor
|
|
28
28
|
* @private
|
|
29
29
|
* @alias sap.ui.table.plugins.SelectionModelSelection
|
|
@@ -313,7 +313,8 @@ sap.ui.define([
|
|
|
313
313
|
|
|
314
314
|
this.fireSelectionChange({
|
|
315
315
|
rowIndices: aRowIndices,
|
|
316
|
-
selectAll: bSelectAll
|
|
316
|
+
selectAll: bSelectAll,
|
|
317
|
+
_internalTrigger: this._bInternalTrigger
|
|
317
318
|
});
|
|
318
319
|
}
|
|
319
320
|
|
|
@@ -343,7 +344,9 @@ sap.ui.define([
|
|
|
343
344
|
// If rows are added or removed, the index-based selection of the SelectionModel is invalid and needs to be cleared.
|
|
344
345
|
// Changes from 0 are ignored for compatibility, so it is possible to select something before the initial rows update is done.
|
|
345
346
|
if (this._iTotalRowCount > 0 && this._iTotalRowCount !== iTotalRowCount) {
|
|
347
|
+
this._bInternalTrigger = true;
|
|
346
348
|
this.clearSelection();
|
|
349
|
+
delete this._bInternalTrigger;
|
|
347
350
|
}
|
|
348
351
|
|
|
349
352
|
this._iTotalRowCount = iTotalRowCount;
|
|
@@ -32,7 +32,7 @@ sap.ui.define([
|
|
|
32
32
|
* @class TODO (don't forget to document fixed row count restrictions because fixed rows are set by this plugin)
|
|
33
33
|
* @extends sap.ui.table.plugins.PluginBase
|
|
34
34
|
* @author SAP SE
|
|
35
|
-
* @version 1.
|
|
35
|
+
* @version 1.111.1
|
|
36
36
|
* @private
|
|
37
37
|
* @since 1.76
|
|
38
38
|
* @experimental
|
|
@@ -35,7 +35,7 @@ sap.ui.define([
|
|
|
35
35
|
* @ui5-restricted sap.ui.mdc
|
|
36
36
|
*
|
|
37
37
|
* @author SAP SE
|
|
38
|
-
* @version 1.
|
|
38
|
+
* @version 1.111.1
|
|
39
39
|
*/
|
|
40
40
|
var AutoRowMode = RowMode.extend("sap.ui.table.rowmodes.AutoRowMode", /** @lends sap.ui.table.rowmodes.AutoRowMode.prototype */ {
|
|
41
41
|
metadata: {
|
|
@@ -29,7 +29,7 @@ sap.ui.define([
|
|
|
29
29
|
* @ui5-restricted sap.ui.mdc
|
|
30
30
|
*
|
|
31
31
|
* @author SAP SE
|
|
32
|
-
* @version 1.
|
|
32
|
+
* @version 1.111.1
|
|
33
33
|
*
|
|
34
34
|
*/
|
|
35
35
|
var FixedRowMode = RowMode.extend("sap.ui.table.rowmodes.FixedRowMode", /** @lends sap.ui.table.rowmodes.FixedRowMode.prototype */ {
|
|
@@ -33,7 +33,7 @@ sap.ui.define([
|
|
|
33
33
|
* @ui5-restricted sap.ui.mdc
|
|
34
34
|
*
|
|
35
35
|
* @author SAP SE
|
|
36
|
-
* @version 1.
|
|
36
|
+
* @version 1.111.1
|
|
37
37
|
*
|
|
38
38
|
*/
|
|
39
39
|
var InteractiveRowMode = RowMode.extend("sap.ui.table.rowmodes.InteractiveRowMode", /** @lends sap.ui.table.rowmodes.InteractiveRowMode.prototype */ {
|
|
@@ -34,7 +34,7 @@ sap.ui.define([
|
|
|
34
34
|
* @ui5-restricted sap.ui.mdc
|
|
35
35
|
*
|
|
36
36
|
* @author SAP SE
|
|
37
|
-
* @version 1.
|
|
37
|
+
* @version 1.111.1
|
|
38
38
|
*/
|
|
39
39
|
var RowMode = Element.extend("sap.ui.table.rowmodes.RowMode", /** @lends sap.ui.table.rowmodes.RowMode.prototype */ {
|
|
40
40
|
metadata: {
|
|
@@ -716,10 +716,14 @@ sap.ui.define([
|
|
|
716
716
|
* @protected
|
|
717
717
|
*/
|
|
718
718
|
RowMode.prototype.disableNoData = function() {
|
|
719
|
-
|
|
719
|
+
if (this.isNoDataDisabled()) {
|
|
720
|
+
return;
|
|
721
|
+
}
|
|
722
|
+
|
|
723
|
+
_private(this).bNoDataDisabled = true;
|
|
720
724
|
|
|
721
|
-
|
|
722
|
-
|
|
725
|
+
var oTable = this.getTable();
|
|
726
|
+
if (oTable) {
|
|
723
727
|
oTable.invalidate();
|
|
724
728
|
}
|
|
725
729
|
};
|
|
@@ -731,10 +735,14 @@ sap.ui.define([
|
|
|
731
735
|
* @protected
|
|
732
736
|
*/
|
|
733
737
|
RowMode.prototype.enableNoData = function() {
|
|
734
|
-
|
|
738
|
+
if (!this.isNoDataDisabled()) {
|
|
739
|
+
return;
|
|
740
|
+
}
|
|
741
|
+
|
|
742
|
+
_private(this).bNoDataDisabled = false;
|
|
735
743
|
|
|
736
|
-
|
|
737
|
-
|
|
744
|
+
var oTable = this.getTable();
|
|
745
|
+
if (oTable) {
|
|
738
746
|
oTable.invalidate();
|
|
739
747
|
}
|
|
740
748
|
};
|
|
@@ -14,7 +14,7 @@ sap.ui.define([], function() {
|
|
|
14
14
|
* Note: Do not access the functions of this helper directly, but via <code>sap.ui.table.utils.TableUtils.Binding...</code>
|
|
15
15
|
*
|
|
16
16
|
* @author SAP SE
|
|
17
|
-
* @version 1.
|
|
17
|
+
* @version 1.111.1
|
|
18
18
|
* @namespace
|
|
19
19
|
* @alias sap.ui.table.utils._BindingUtils
|
|
20
20
|
* @private
|
|
@@ -18,7 +18,7 @@ sap.ui.define([
|
|
|
18
18
|
* Note: Do not access the functions of this helper directly, but via <code>sap.ui.table.utils.TableUtils.Column...</code>
|
|
19
19
|
*
|
|
20
20
|
* @author SAP SE
|
|
21
|
-
* @version 1.
|
|
21
|
+
* @version 1.111.1
|
|
22
22
|
* @namespace
|
|
23
23
|
* @alias sap.ui.table.utils._ColumnUtils
|
|
24
24
|
* @private
|
|
@@ -395,11 +395,13 @@ sap.ui.define([
|
|
|
395
395
|
* Returns true if the column can be moved to another position.
|
|
396
396
|
*
|
|
397
397
|
* @param {sap.ui.table.Column} oColumn Column of the table.
|
|
398
|
+
* @param {boolean} [bIgnoreReorderingProperty=false] Indicates whether the table's <code>enableColumnReordering</code> property
|
|
399
|
+
* should be ignored for determining a movable column, regardless of whether it is enabled or not.
|
|
398
400
|
* @returns {boolean} Whether the column can be moved to another position.
|
|
399
401
|
*/
|
|
400
|
-
isColumnMovable: function(oColumn) {
|
|
402
|
+
isColumnMovable: function(oColumn, bIgnoreReorderingProperty) {
|
|
401
403
|
var oTable = oColumn.getParent();
|
|
402
|
-
if (!oTable || !oTable.getEnableColumnReordering()) {
|
|
404
|
+
if (!oTable || (!oTable.getEnableColumnReordering() && !bIgnoreReorderingProperty)) {
|
|
403
405
|
// Column reordering is not active at all
|
|
404
406
|
return false;
|
|
405
407
|
}
|
|
@@ -453,12 +455,14 @@ sap.ui.define([
|
|
|
453
455
|
*
|
|
454
456
|
* @param {sap.ui.table.Column} oColumn Column of the table.
|
|
455
457
|
* @param {int} iNewIndex the desired new index of the column in the current table setup.
|
|
458
|
+
* @param {boolean} [bIgnoreReorderingProperty=false] Indicates whether the table's <code>enableColumnReordering</code> property
|
|
459
|
+
* should be ignored for determining a movable column, regardless of whether it is enabled or not.
|
|
456
460
|
* @returns {boolean} Whether the column can be moved to the desired position.
|
|
457
461
|
*/
|
|
458
|
-
isColumnMovableTo: function(oColumn, iNewIndex) {
|
|
462
|
+
isColumnMovableTo: function(oColumn, iNewIndex, bIgnoreReorderingProperty) {
|
|
459
463
|
var oTable = oColumn.getParent();
|
|
460
464
|
|
|
461
|
-
if (!oTable || iNewIndex === undefined || !ColumnUtils.isColumnMovable(oColumn)) {
|
|
465
|
+
if (!oTable || iNewIndex === undefined || !ColumnUtils.isColumnMovable(oColumn, bIgnoreReorderingProperty)) {
|
|
462
466
|
// Column is not movable at all
|
|
463
467
|
return false;
|
|
464
468
|
}
|
|
@@ -23,7 +23,7 @@ sap.ui.define([
|
|
|
23
23
|
* Note: Do not access the functions of this helper directly, but via <code>sap.ui.table.utils.TableUtils.Grouping...</code>
|
|
24
24
|
*
|
|
25
25
|
* @author SAP SE
|
|
26
|
-
* @version 1.
|
|
26
|
+
* @version 1.111.1
|
|
27
27
|
* @namespace
|
|
28
28
|
* @alias sap.ui.table.utils._GroupingUtils
|
|
29
29
|
* @private
|
|
@@ -22,7 +22,7 @@ sap.ui.define(["sap/ui/base/DataType"], function(DataType) {
|
|
|
22
22
|
* - There is no concept for public or protected hooks. Never expose a hook directly, only indirectly as can be seen in the examples.
|
|
23
23
|
*
|
|
24
24
|
* @author SAP SE
|
|
25
|
-
* @version 1.
|
|
25
|
+
* @version 1.111.1
|
|
26
26
|
* @namespace
|
|
27
27
|
* @alias sap.ui.table.utils._HookUtils
|
|
28
28
|
*
|
|
@@ -39,7 +39,7 @@ sap.ui.define([
|
|
|
39
39
|
* Note: Do not access the functions of this helper directly, but via <code>sap.ui.table.utils.TableUtils.Menu...</code>
|
|
40
40
|
*
|
|
41
41
|
* @author SAP SE
|
|
42
|
-
* @version 1.
|
|
42
|
+
* @version 1.111.1
|
|
43
43
|
* @namespace
|
|
44
44
|
* @alias sap.ui.table.utils._MenuUtils
|
|
45
45
|
* @private
|