@sapui5/sap.ui.export 1.124.6 → 1.124.7
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/ui/export/.library +1 -1
- package/src/sap/ui/export/ExportBase.js +1 -1
- package/src/sap/ui/export/ExportHandler.js +1 -1
- package/src/sap/ui/export/ExportUtils.js +2 -2
- package/src/sap/ui/export/PortableDocument.js +1 -1
- package/src/sap/ui/export/Spreadsheet.js +3 -3
- package/src/sap/ui/export/SpreadsheetExport.js +1 -1
- package/src/sap/ui/export/library.js +2 -2
- package/src/sap/ui/export/provider/DataProviderBase.js +22 -2
- package/src/sap/ui/export/util/Filter.js +1 -1
package/package.json
CHANGED
|
@@ -27,7 +27,7 @@ sap.ui.define([
|
|
|
27
27
|
* @class The <code>sap.ui.export.ExportBase</code> class allows you to export table data from a UI5 application to certain formats. This class is an abstract class that requires specific implementations for each file format.
|
|
28
28
|
*
|
|
29
29
|
* @author SAP SE
|
|
30
|
-
* @version 1.124.
|
|
30
|
+
* @version 1.124.7
|
|
31
31
|
*
|
|
32
32
|
* @since 1.96
|
|
33
33
|
* @alias sap.ui.export.ExportBase
|
|
@@ -18,7 +18,7 @@ sap.ui.define(['./library', './ExportUtils', './ExportDialog', './util/PDFCapabi
|
|
|
18
18
|
* @class The <code>sap.ui.export.ExportHandler</code> class allows you to export table data from an SAPUI5 application.
|
|
19
19
|
*
|
|
20
20
|
* @author SAP SE
|
|
21
|
-
* @version 1.124.
|
|
21
|
+
* @version 1.124.7
|
|
22
22
|
*
|
|
23
23
|
* @since 1.102
|
|
24
24
|
* @alias sap.ui.export.ExportHandler
|
|
@@ -147,7 +147,7 @@ sap.ui.define([
|
|
|
147
147
|
* @class Utilities related to export to enable reuse in integration scenarios (e.g. tables).
|
|
148
148
|
*
|
|
149
149
|
* @author SAP SE
|
|
150
|
-
* @version 1.124.
|
|
150
|
+
* @version 1.124.7
|
|
151
151
|
*
|
|
152
152
|
* @since 1.59
|
|
153
153
|
* @alias sap.ui.export.ExportUtils
|
|
@@ -1228,7 +1228,7 @@ sap.ui.define([
|
|
|
1228
1228
|
*
|
|
1229
1229
|
* @param {object} oContext Context object
|
|
1230
1230
|
* @param {string} [oContext.application] Name of the application (default: "SAP UI5")
|
|
1231
|
-
* @param {string} [oContext.version] Application version (default: "1.124.
|
|
1231
|
+
* @param {string} [oContext.version] Application version (default: "1.124.7")
|
|
1232
1232
|
* @param {string} [oContext.title] Title that will be written to the file (NOT the filename)
|
|
1233
1233
|
* @param {string} [oContext.modifiedBy] Optional user context that will be written to the file
|
|
1234
1234
|
* @param {string} [oContext.sheetName] Name of the data sheet - Maximum length of 31 characters
|
|
@@ -24,7 +24,7 @@ sap.ui.define([
|
|
|
24
24
|
* @class The <code>sap.ui.export.PortableDocument</code> class allows you to export table data from a UI5 application to a Portable Document Format (*.PDF) file.
|
|
25
25
|
*
|
|
26
26
|
* @author SAP SE
|
|
27
|
-
* @version 1.124.
|
|
27
|
+
* @version 1.124.7
|
|
28
28
|
*
|
|
29
29
|
* @since 1.96
|
|
30
30
|
* @alias sap.ui.export.PortableDocument
|
|
@@ -85,7 +85,7 @@ sap.ui.define([
|
|
|
85
85
|
* <li><code>workbook.context</code> - Context object that will be applied to the generated file. It may contain the following fields:</li>
|
|
86
86
|
* <ul>
|
|
87
87
|
* <li><code>application</code> (string) - The application that creates the XLSX document (default: "SAP UI5")</li>
|
|
88
|
-
* <li><code>version</code> (string) - Application version that creates the XLSX document (default: "1.124.
|
|
88
|
+
* <li><code>version</code> (string) - Application version that creates the XLSX document (default: "1.124.7")</li>
|
|
89
89
|
* <li><code>title</code> (string) - Title of the XLSX document (NOT the filename)</li>
|
|
90
90
|
* <li><code>modifiedBy</code> (string) - User context for the XLSX document</li>
|
|
91
91
|
* <li><code>sheetName</code> (string) - The label of the data sheet</li>
|
|
@@ -169,7 +169,7 @@ sap.ui.define([
|
|
|
169
169
|
* columns: aColumns,
|
|
170
170
|
* context: {
|
|
171
171
|
* application: 'Debug Test Application',
|
|
172
|
-
* version: '1.124.
|
|
172
|
+
* version: '1.124.7',
|
|
173
173
|
* title: 'Some random title',
|
|
174
174
|
* modifiedBy: 'John Doe',
|
|
175
175
|
* metaSheetName: 'Custom metadata',
|
|
@@ -281,7 +281,7 @@ sap.ui.define([
|
|
|
281
281
|
* @class The <code>sap.ui.export.Spreadsheet</code> class allows you to export table data from a UI5 application to a spreadsheet file.
|
|
282
282
|
*
|
|
283
283
|
* @author SAP SE
|
|
284
|
-
* @version 1.124.
|
|
284
|
+
* @version 1.124.7
|
|
285
285
|
*
|
|
286
286
|
* @since 1.50
|
|
287
287
|
* @alias sap.ui.export.Spreadsheet
|
|
@@ -21,7 +21,7 @@ sap.ui.define(['sap/base/Log', 'sap/ui/export/ExportUtils'], function(Log, Expor
|
|
|
21
21
|
* Utility class to perform spreadsheet export.
|
|
22
22
|
*
|
|
23
23
|
* @author SAP SE
|
|
24
|
-
* @version 1.124.
|
|
24
|
+
* @version 1.124.7
|
|
25
25
|
*
|
|
26
26
|
* @alias sap.ui.export.SpreadsheetExport
|
|
27
27
|
* @private
|
|
@@ -15,7 +15,7 @@ sap.ui.define(["sap/ui/core/Lib"], function(Library) {
|
|
|
15
15
|
* @namespace
|
|
16
16
|
* @alias sap.ui.export
|
|
17
17
|
* @author SAP SE
|
|
18
|
-
* @version 1.124.
|
|
18
|
+
* @version 1.124.7
|
|
19
19
|
* @public
|
|
20
20
|
*/
|
|
21
21
|
|
|
@@ -33,7 +33,7 @@ sap.ui.define(["sap/ui/core/Lib"], function(Library) {
|
|
|
33
33
|
interfaces: [],
|
|
34
34
|
controls: [],
|
|
35
35
|
elements: [],
|
|
36
|
-
version: "1.124.
|
|
36
|
+
version: "1.124.7"
|
|
37
37
|
});
|
|
38
38
|
|
|
39
39
|
/**
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
* @param {object} mSettings Data service related part of the export configuration
|
|
25
25
|
*
|
|
26
26
|
* @author SAP SE
|
|
27
|
-
* @version 1.124.
|
|
27
|
+
* @version 1.124.7
|
|
28
28
|
*
|
|
29
29
|
* @constructor
|
|
30
30
|
* @class DataProviderBase
|
|
@@ -250,7 +250,7 @@
|
|
|
250
250
|
|
|
251
251
|
iRemainingRows = this.iTotalRows - this.iAvailableRows;
|
|
252
252
|
|
|
253
|
-
mCallbackParams.finished = iFetchedRows
|
|
253
|
+
mCallbackParams.finished = this._isFinished(iFetchedRows, sNextUrl, iRemainingRows);
|
|
254
254
|
mCallbackParams.progress = this.iTotalRows;
|
|
255
255
|
mCallbackParams.total = this.iTotalRows < this.iCount ? this.iTotalRows : this.iCount;
|
|
256
256
|
mCallbackParams.fetched = this.iAvailableRows;
|
|
@@ -264,10 +264,30 @@
|
|
|
264
264
|
.catch(this.fnOnError.bind(this));
|
|
265
265
|
}
|
|
266
266
|
|
|
267
|
+
if (iFetchedRows < this.iBatchSize && sNextUrl) {
|
|
268
|
+
this.iBatchSize = iFetchedRows;
|
|
269
|
+
}
|
|
267
270
|
mCallbackParams.rows = this.fnConvertData(aData); // Normalize data
|
|
268
271
|
this.fnProcessCallback(mCallbackParams); // Return result
|
|
269
272
|
};
|
|
270
273
|
|
|
274
|
+
/**
|
|
275
|
+
* The function returns array of columns that need special conversion for values.
|
|
276
|
+
* E.g. handling data from association/navigationProperty
|
|
277
|
+
*
|
|
278
|
+
* @param {number} iFetchedRows - Number of rows fetched
|
|
279
|
+
* @param {string} sNextUrl - Next url to fetch data
|
|
280
|
+
* @param {number} iRemainingRows - Remaining rows to fetch
|
|
281
|
+
* @returns {boolean} - True if the finish condition is met
|
|
282
|
+
*
|
|
283
|
+
* @static
|
|
284
|
+
* @private
|
|
285
|
+
*/
|
|
286
|
+
DataProviderBase.prototype._isFinished = function(iFetchedRows, sNextUrl, iRemainingRows) {
|
|
287
|
+
const bFetchedRows = !sNextUrl && ((iFetchedRows < this.iBatchSize) || iFetchedRows > this.iBatchSize);
|
|
288
|
+
return iFetchedRows === 0 || iRemainingRows <= 0 || bFetchedRows;
|
|
289
|
+
};
|
|
290
|
+
|
|
271
291
|
/**
|
|
272
292
|
* Inner function that processes request handler exceptions.
|
|
273
293
|
*
|
|
@@ -20,7 +20,7 @@ sap.ui.define(['sap/ui/base/Object'], function(BaseObject) {
|
|
|
20
20
|
* convenience functions like <code>sap.ui.export.util.Filter#setType</code> to improve the result.
|
|
21
21
|
*
|
|
22
22
|
* @author SAP SE
|
|
23
|
-
* @version 1.124.
|
|
23
|
+
* @version 1.124.7
|
|
24
24
|
*
|
|
25
25
|
* @since 1.110
|
|
26
26
|
* @alias sap.ui.export.util.Filter
|