@sapui5/sap.suite.ui.generic.template 1.122.2 → 1.123.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.
Files changed (147) hide show
  1. package/package.json +1 -1
  2. package/src/sap/suite/ui/generic/template/.library +1 -1
  3. package/src/sap/suite/ui/generic/template/AnalyticalListPage/controller/ControllerImplementation.js +19 -24
  4. package/src/sap/suite/ui/generic/template/AnalyticalListPage/manifest.json +1 -1
  5. package/src/sap/suite/ui/generic/template/Canvas/manifest.json +1 -1
  6. package/src/sap/suite/ui/generic/template/ListReport/controller/ControllerImplementation.js +22 -21
  7. package/src/sap/suite/ui/generic/template/ListReport/controller/MultipleViewsHandler.js +8 -3
  8. package/src/sap/suite/ui/generic/template/ListReport/manifest.json +1 -1
  9. package/src/sap/suite/ui/generic/template/ListReport/view/fragments/MultiEditDialog.fragment.xml +12 -1
  10. package/src/sap/suite/ui/generic/template/ObjectPage/controller/ControllerImplementation.js +25 -151
  11. package/src/sap/suite/ui/generic/template/ObjectPage/controller/PasteHandler.js +357 -0
  12. package/src/sap/suite/ui/generic/template/ObjectPage/controller/SectionTitleHandler.js +8 -8
  13. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n.properties +12 -0
  14. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ar.properties +8 -0
  15. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_bg.properties +8 -0
  16. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ca.properties +8 -0
  17. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_cnr.properties +8 -0
  18. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_cs.properties +8 -0
  19. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_cy.properties +8 -0
  20. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_da.properties +8 -0
  21. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_de.properties +8 -0
  22. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_el.properties +8 -0
  23. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_en.properties +8 -0
  24. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_en_GB.properties +8 -0
  25. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_en_US_saprigi.properties +8 -0
  26. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_es.properties +8 -0
  27. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_es_MX.properties +8 -0
  28. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_et.properties +8 -0
  29. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_fi.properties +8 -0
  30. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_fr.properties +8 -0
  31. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_fr_CA.properties +17 -9
  32. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_hi.properties +8 -0
  33. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_hr.properties +8 -0
  34. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_hu.properties +8 -0
  35. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_id.properties +8 -0
  36. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_it.properties +8 -0
  37. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_iw.properties +8 -0
  38. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ja.properties +8 -0
  39. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_kk.properties +8 -0
  40. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ko.properties +8 -0
  41. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_lt.properties +8 -0
  42. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_lv.properties +8 -0
  43. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_mk.properties +8 -0
  44. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ms.properties +8 -0
  45. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_nl.properties +8 -0
  46. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_no.properties +8 -0
  47. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_pl.properties +8 -0
  48. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_pt.properties +8 -0
  49. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_pt_PT.properties +8 -0
  50. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ro.properties +8 -0
  51. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_ru.properties +8 -0
  52. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sh.properties +8 -0
  53. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sk.properties +8 -0
  54. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sl.properties +8 -0
  55. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sr.properties +8 -0
  56. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_sv.properties +8 -0
  57. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_th.properties +8 -0
  58. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_tr.properties +8 -0
  59. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_uk.properties +8 -0
  60. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_vi.properties +8 -0
  61. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_zh_CN.properties +8 -0
  62. package/src/sap/suite/ui/generic/template/ObjectPage/i18n/i18n_zh_TW.properties +8 -0
  63. package/src/sap/suite/ui/generic/template/ObjectPage/manifest.json +1 -1
  64. package/src/sap/suite/ui/generic/template/ObjectPage/templateSpecificPreparationHelper.js +1 -5
  65. package/src/sap/suite/ui/generic/template/ObjectPage/view/fragments/Actions.fragment.xml +12 -0
  66. package/src/sap/suite/ui/generic/template/ObjectPage/view/fragments/ExtensionFacetLayout.fragment.xml +2 -1
  67. package/src/sap/suite/ui/generic/template/ObjectPage/view/fragments/SmartTable.fragment.xml +2 -0
  68. package/src/sap/suite/ui/generic/template/QuickCreate/manifest.json +1 -1
  69. package/src/sap/suite/ui/generic/template/QuickCreate/view/QuickCreate.controller.js +2 -7
  70. package/src/sap/suite/ui/generic/template/QuickView/manifest.json +1 -1
  71. package/src/sap/suite/ui/generic/template/designtime/ObjectPage.designtime.js +3 -0
  72. package/src/sap/suite/ui/generic/template/fragments/CreateWithDialog.fragment.xml +12 -1
  73. package/src/sap/suite/ui/generic/template/fragments/SmartControlContextMenu.fragment.xml +7 -1
  74. package/src/sap/suite/ui/generic/template/fragments/SmartTableResponsiveTableCommons.fragment.xml +0 -2
  75. package/src/sap/suite/ui/generic/template/fragments/SmartTableUiTableCommons.fragment.xml +3 -3
  76. package/src/sap/suite/ui/generic/template/genericUtilities/filterHelper.js +47 -28
  77. package/src/sap/suite/ui/generic/template/genericUtilities/metadataAnalyser.js +20 -0
  78. package/src/sap/suite/ui/generic/template/js/AnnotationHelper.js +32 -25
  79. package/src/sap/suite/ui/generic/template/lib/AdaptiveCardHelper.js +27 -13
  80. package/src/sap/suite/ui/generic/template/lib/AppComponent.js +21 -5
  81. package/src/sap/suite/ui/generic/template/lib/Application.js +4 -1
  82. package/src/sap/suite/ui/generic/template/lib/CommonUtils.js +5 -5
  83. package/src/sap/suite/ui/generic/template/lib/ComponentUtils.js +0 -1
  84. package/src/sap/suite/ui/generic/template/lib/ContextMenuHandler.js +257 -60
  85. package/src/sap/suite/ui/generic/template/lib/MessageUtils.js +28 -0
  86. package/src/sap/suite/ui/generic/template/lib/PageLeaveHandler.js +0 -1
  87. package/src/sap/suite/ui/generic/template/lib/ShareUtils.js +197 -67
  88. package/src/sap/suite/ui/generic/template/lib/StableIdDefinition.js +3 -0
  89. package/src/sap/suite/ui/generic/template/lib/i18n/i18n.properties +5 -5
  90. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ar.properties +3 -3
  91. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_bg.properties +3 -3
  92. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ca.properties +3 -3
  93. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_cnr.properties +3 -3
  94. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_cs.properties +3 -3
  95. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_cy.properties +3 -3
  96. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_da.properties +3 -3
  97. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_de.properties +3 -3
  98. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_el.properties +3 -3
  99. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en.properties +3 -3
  100. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en_GB.properties +3 -3
  101. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en_US_saprigi.properties +3 -3
  102. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_es.properties +3 -3
  103. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_es_MX.properties +3 -3
  104. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_et.properties +3 -3
  105. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_fi.properties +3 -3
  106. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_fr.properties +3 -3
  107. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_fr_CA.properties +14 -14
  108. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_hi.properties +3 -3
  109. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_hr.properties +3 -3
  110. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_hu.properties +3 -3
  111. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_id.properties +3 -3
  112. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_it.properties +3 -3
  113. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_iw.properties +3 -3
  114. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ja.properties +3 -3
  115. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_kk.properties +3 -3
  116. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ko.properties +3 -3
  117. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_lt.properties +3 -3
  118. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_lv.properties +3 -3
  119. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_mk.properties +3 -3
  120. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ms.properties +3 -3
  121. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_nl.properties +3 -3
  122. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_no.properties +3 -3
  123. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_pl.properties +3 -3
  124. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_pt.properties +3 -3
  125. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_pt_PT.properties +3 -3
  126. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ro.properties +3 -3
  127. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ru.properties +3 -3
  128. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sh.properties +3 -3
  129. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sk.properties +3 -3
  130. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sl.properties +3 -3
  131. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sr.properties +3 -3
  132. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sv.properties +3 -3
  133. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_th.properties +3 -3
  134. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_tr.properties +3 -3
  135. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_uk.properties +3 -3
  136. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_vi.properties +3 -3
  137. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_zh_CN.properties +3 -3
  138. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_zh_TW.properties +3 -3
  139. package/src/sap/suite/ui/generic/template/lib/insights/InsightsFECardProvider.js +10 -3
  140. package/src/sap/suite/ui/generic/template/lib/insights/InsightsHandler.js +2 -1
  141. package/src/sap/suite/ui/generic/template/lib/multipleViews/MultipleTablesModeHelper.js +4 -3
  142. package/src/sap/suite/ui/generic/template/lib/multipleViews/MultipleViewsHandler.js +6 -14
  143. package/src/sap/suite/ui/generic/template/lib/multipleViews/SingleTableModeHelper.js +13 -5
  144. package/src/sap/suite/ui/generic/template/lib/navigation/NavigationController.js +1 -1
  145. package/src/sap/suite/ui/generic/template/lib/presentationControl/SmartTableHandler.js +46 -2
  146. package/src/sap/suite/ui/generic/template/library.js +1 -1
  147. package/src/sap/suite/ui/generic/template/listTemplates/controller/MultipleViewsHandler.js +8 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sapui5/sap.suite.ui.generic.template",
3
- "version": "1.122.2",
3
+ "version": "1.123.0",
4
4
  "description": "SAPUI5 Library sap.suite.ui.generic.template",
5
5
  "keywords": [
6
6
  "sapui5",
@@ -7,7 +7,7 @@
7
7
 
8
8
  (c) Copyright 2009-2015 SAP SE. All rights reserved
9
9
  </copyright>
10
- <version>1.122.2</version>
10
+ <version>1.123.0</version>
11
11
 
12
12
  <documentation>Library with generic Suite UI templates.</documentation>
13
13
 
@@ -256,37 +256,34 @@ sap.ui.define(["sap/fe/navigation/SelectionVariant",
256
256
 
257
257
  var getFilterInfoForTilePromise = function () {
258
258
  var oPresentationControlHandler = oTemplateUtils.oServices.oPresentationControlHandlerFactory.getPresentationControlHandler(oState.oSmartChart);
259
- var oModel = oPresentationControlHandler.getModel();
260
- var oEntityType = oTemplateUtils.oCommonUtils.getMetaModelEntityType(oPresentationControlHandler.getEntitySet());
259
+ var oMetaModel = oPresentationControlHandler.getModel().getMetaModel();
260
+ var sEntityTypeName = oMetaModel.getODataEntitySet(oPresentationControlHandler.getEntitySet()).entityType;
261
+ var oTable = oState.oSmartTable.getTable();
262
+ var oBinding = oTable.getBinding("rows") || oTable.getBinding("items");
263
+ var sServiceUrl = oBinding && oBinding.getDownloadUrl();
261
264
  // - For Analytical Binding.
262
265
  // we recv. aApplicationFilter and aApplicationFilters binding both but aApplicationFilter have actual filters operator value.
263
266
  // - For List Binding.
264
267
  // we recv. only aApplicationFilters contains filter operator.
265
- var aFilters = oPresentationControlHandler.getBinding(oState).aApplicationFilter || oPresentationControlHandler.getBinding(oState).aApplicationFilters;
266
- if (!aFilters || !aFilters.length) {
267
- // case when no filters is applied
268
+ var aFilters = oBinding.aApplicationFilter || oBinding.aApplicationFilters;
269
+ // non-draft case when no filter is applied
270
+ if (!aFilters.length) {
268
271
  return Promise.resolve({
269
- bIsStatic: true,
270
- sServiceUrl: ""
272
+ sServiceUrl: sServiceUrl
271
273
  });
272
274
  }
273
275
  var oFilterData = oState.oSmartFilterbar.getFilterData();
274
- var oFilterParams = filterHelper.getFilterParams(oModel, oEntityType, aFilters, oFilterData);
275
- var oTable = oState.oSmartTable.getTable();
276
- var oBinding = oTable.getBinding("rows") || oTable.getBinding("items");
277
- var sServiceUrl = oBinding && oBinding.getDownloadUrl();
278
- //chart only mode, no data in table
279
- if (!sServiceUrl) {
276
+ var sFilterParams = filterHelper.getFilterParams(oMetaModel, sEntityTypeName, aFilters, oFilterData);
277
+ if (sFilterParams) {
278
+ sServiceUrl = oTemplateUtils.oCommonUtils.fnReplaceFiltersWithGetDownloadUrl(sServiceUrl, sFilterParams);
279
+ return Promise.resolve({
280
+ sServiceUrl: sServiceUrl
281
+ });
282
+ } else {
280
283
  return Promise.resolve({
281
- bIsStatic: true,
282
284
  sServiceUrl: ""
283
285
  });
284
286
  }
285
- sServiceUrl = oTemplateUtils.oCommonUtils.fnReplaceFiltersWithGetDownloadUrl(sServiceUrl, oFilterParams);
286
- return Promise.resolve({
287
- bIsStatic: oFilterParams.bIsStatic,
288
- sServiceUrl: sServiceUrl
289
- });
290
287
  };
291
288
 
292
289
  var oFragmentController = {
@@ -318,14 +315,12 @@ sap.ui.define(["sap/fe/navigation/SelectionVariant",
318
315
  },
319
316
 
320
317
  getServiceUrl: function () {
321
- // only create static tile, if filter for any semanticDateRangeProperty (including custom filter field) exists
322
318
  return getFilterInfoForTilePromise().then(function (oFilterInfo) {
323
- var sServiceUrl = "";
324
- if (!oFilterInfo.bIsStatic) {
325
- sServiceUrl = oFilterInfo.sServiceUrl + "&$top=0&$inlinecount=allpages";
319
+ if (oFilterInfo.sServiceUrl) {
320
+ oFilterInfo.sServiceUrl = oFilterInfo.sServiceUrl ? (oFilterInfo.sServiceUrl + "&$top=0&$inlinecount=allpages") : "";
326
321
  }
327
322
  var oShareInfo = {
328
- serviceUrl: sServiceUrl
323
+ serviceUrl: oFilterInfo.sServiceUrl
329
324
  };
330
325
  oController.onSaveAsTileExtension(oShareInfo);
331
326
  return oShareInfo.serviceUrl;
@@ -8,7 +8,7 @@
8
8
  "i18n": "i18n/i18n.properties",
9
9
  "applicationVersion": {
10
10
  "__comment": "applicationVersion oder componentversion??",
11
- "version": "1.122.2"
11
+ "version": "1.123.0"
12
12
  },
13
13
  "title": "{{TITLE}}",
14
14
  "description": "{{DESCRIPTION}}",
@@ -8,7 +8,7 @@
8
8
  "i18n": "i18n/i18n.properties",
9
9
  "applicationVersion": {
10
10
  "__comment": "applicationVersion oder componentversion??",
11
- "version": "1.122.2"
11
+ "version": "1.123.0"
12
12
  },
13
13
  "title": "Canvas",
14
14
  "description": "Canvas Page",
@@ -302,32 +302,35 @@ sap.ui.define([
302
302
  var bAreDataShownInTable = oState.oIappStateHandler.areDataShownInTable();
303
303
  if (bAreDataShownInTable) {
304
304
  var oPresentationControlHandler = oState.oPresentationControlHandler;
305
- var oModel = oPresentationControlHandler.getModel();
306
- var oEntityType = oTemplateUtils.oCommonUtils.getMetaModelEntityType(oPresentationControlHandler.getEntitySet());
305
+ var oMetaModel = oPresentationControlHandler.getModel().getMetaModel();
306
+ var sEntityTypeName = oMetaModel.getODataEntitySet(oPresentationControlHandler.getEntitySet()).entityType;
307
+ var oBinding = oPresentationControlHandler.getBinding(oState);
308
+ var sServiceUrl = oBinding.getDownloadUrl();
307
309
  // - For Analytical Binding.
308
310
  // we recv. aApplicationFilter and aApplicationFilters binding both but aApplicationFilter have actual filters operator value.
309
311
  // - For List Binding.
310
312
  // we recv. only aApplicationFilters contains filter operator.
311
- var aFilters = oPresentationControlHandler.getBinding(oState).aApplicationFilter || oPresentationControlHandler.getBinding(oState).aApplicationFilters;
312
- if (!aFilters || !aFilters.length) {
313
- // case when no filters is applied
313
+ var aFilters = oBinding.aApplicationFilter || oBinding.aApplicationFilters;
314
+ // non-draft case when no filter is applied
315
+ if (!aFilters.length) {
314
316
  return Promise.resolve({
315
- bIsStatic: true,
316
- sServiceUrl: ""
317
+ sServiceUrl: sServiceUrl
317
318
  });
318
319
  }
319
320
  var oFilterData = oState.oSmartFilterbar.getFilterData();
320
- var oFilterParams = filterHelper.getFilterParams(oModel, oEntityType, aFilters, oFilterData);
321
- var oBinding = oPresentationControlHandler.getBinding(oState);
322
- var sServiceUrl = oBinding && oBinding.getDownloadUrl();
323
- sServiceUrl = oTemplateUtils.oCommonUtils.fnReplaceFiltersWithGetDownloadUrl(sServiceUrl, oFilterParams);
324
- return Promise.resolve({
325
- bIsStatic: oFilterParams.bIsStatic,
326
- sServiceUrl: sServiceUrl
327
- });
321
+ var sFilterParams = filterHelper.getFilterParams(oMetaModel, sEntityTypeName, aFilters, oFilterData);
322
+ if (sFilterParams) {
323
+ sServiceUrl = oTemplateUtils.oCommonUtils.fnReplaceFiltersWithGetDownloadUrl(sServiceUrl, sFilterParams);
324
+ return Promise.resolve({
325
+ sServiceUrl: sServiceUrl
326
+ });
327
+ } else {
328
+ return Promise.resolve({
329
+ sServiceUrl: ""
330
+ });
331
+ }
328
332
  }
329
333
  return Promise.resolve({
330
- bIsStatic: true,
331
334
  sServiceUrl: ""
332
335
  });
333
336
  };
@@ -361,14 +364,12 @@ sap.ui.define([
361
364
  },
362
365
 
363
366
  getServiceUrl: function () {
364
- // only create static tile, if filter for any semanticDateRangeProperty (including custom filter field) exists
365
367
  return getFilterInfoForTilePromise().then(function (oFilterInfo) {
366
- var sServiceUrl = "";
367
- if (!oFilterInfo.bIsStatic) {
368
- sServiceUrl = oFilterInfo.sServiceUrl + "&$top=0&$inlinecount=allpages";
368
+ if (oFilterInfo.sServiceUrl) {
369
+ oFilterInfo.sServiceUrl = oFilterInfo.sServiceUrl ? (oFilterInfo.sServiceUrl + "&$top=0&$inlinecount=allpages") : "";
369
370
  }
370
371
  var oShareInfo = {
371
- serviceUrl: sServiceUrl
372
+ serviceUrl: oFilterInfo.sServiceUrl
372
373
  };
373
374
  oController.onSaveAsTileExtension(oShareInfo);
374
375
  return oShareInfo.serviceUrl;
@@ -242,10 +242,16 @@ sap.ui.define([
242
242
  }
243
243
 
244
244
  sMode = oQuickVariantSelectionX ? "multi" : "single";
245
+
246
+ // fixed presentation control handler in single table case:
247
+ var oPresentationControlHandler = oQuickVariantSelection && oState.oPresentationControlHandler;
248
+ // a function that provides the presentation control handler for the given key:
249
+ var fnGetPresentationControlHandler = oPresentationControlHandler ? function(){
250
+ return oPresentationControlHandler; // no need to check for the key as it is the same for all keys
251
+ } : getPresentationControlHandler;
245
252
 
246
253
  // manifestSettings: indicates whether multiple tab multiview or multiple tab single view
247
254
  // pathInTemplatePrivateModel: path of the model to be read
248
- // presentationControlHandler: presentationControlHandler instance which contains smartControl which contains table
249
255
  // getPresentationControlHandler : function which returns the presentationControlHandler instance with the given smartcontrol's key
250
256
  // switchingControl: the control which is used to switch between the views. It must possess a getItems() method.
251
257
  // smartFilterBar: smartfilterbar which contains filter values
@@ -253,8 +259,7 @@ sap.ui.define([
253
259
  mode: sMode,
254
260
  manifestSettings: oQuickVariantSelectionEffective,
255
261
  pathInTemplatePrivateModel: "/listReport/multipleViews",
256
- presentationControlHandler: oQuickVariantSelection && oState.oPresentationControlHandler, // only in single views mode a single smart control is being transfered
257
- getPresentationControlHandler: oQuickVariantSelectionX && getPresentationControlHandler,
262
+ getPresentationControlHandler: fnGetPresentationControlHandler,
258
263
  getSwitchingControlAsync: fnGetSwitchingControlAsync,
259
264
  smartFilterBar: oState.oSmartFilterbar,
260
265
  getSearchValue: function () {
@@ -8,7 +8,7 @@
8
8
  "i18n": "i18n/i18n.properties",
9
9
  "applicationVersion": {
10
10
  "__comment": "applicationVersion oder componentversion??",
11
- "version": "1.122.2"
11
+ "version": "1.123.0"
12
12
  },
13
13
  "title": "{{TITLE}}",
14
14
  "description": "{{DESCRIPTION}}",
@@ -21,6 +21,13 @@
21
21
  <sf:layout>
22
22
  <sf:Layout labelSpanM="12" labelSpanL="12" labelSpanXL="12" />
23
23
  </sf:layout>
24
+ <sf:customData>
25
+ <!-- Maintain the same default settings as the ObjectPage SmartForm -->
26
+ <core:CustomData key="defaultInputFieldDisplayBehaviour" value="descriptionAndId" />
27
+ <core:CustomData key="defaultDropDownDisplayBehaviour" value="descriptionOnly" />
28
+ <core:CustomData key="defaultTextInEditModeSource" value="ValueListNoValidation" />
29
+ <core:CustomData key="dateFormatSettings" value='\{"UTC":true,"style":"medium"\}' />
30
+ </sf:customData>
24
31
  <sf:groups>
25
32
  <sf:Group
26
33
  id="{:= ${parameter>/stableId}.getStableId({type: 'MultiEditDialog', subType: 'GroupExtension', sQuickVariantKey: ${tabItem>key}})}">
@@ -43,7 +50,11 @@
43
50
  definition (now provided as _id) - so if it should become necessary before 1.96 is out of maintenance, that defintion must be used -->
44
51
  <smartmultiedit:Field
45
52
  _id="{dataFieldId>id}"
46
- propertyName="{dataField>Value/Path}"/>
53
+ propertyName="{dataField>Value/Path}">
54
+ <smartmultiedit:customData>
55
+ <core:CustomData key="defaultTextInEditModeSource" value="{path: 'values>', formatter: 'AH.setValidationForValueList'}" />
56
+ </smartmultiedit:customData>
57
+ </smartmultiedit:Field>
47
58
  </sf:elements>
48
59
  </sf:GroupElement>
49
60
  </template:with>
@@ -31,13 +31,15 @@ sap.ui.define([
31
31
  "sap/base/util/deepExtend",
32
32
  "sap/suite/ui/generic/template/ObjectPage/controller/CtxMenuHandler",
33
33
  "sap/suite/ui/generic/template/ObjectPage/controller/inlineCreationRows/InlineCreationRowsHelper",
34
- "sap/suite/ui/generic/template/ObjectPage/controller/RelatedAppsHandler"
34
+ "sap/suite/ui/generic/template/ObjectPage/controller/RelatedAppsHandler",
35
+ "sap/ui/core/Lib",
36
+ "sap/suite/ui/generic/template/ObjectPage/controller/PasteHandler"
35
37
  ], function (ControllerExtension, MessageBox, Filter, Sorter, ManagedObjectModel, SelectionVariant, controlHelper,
36
38
  testableHelper, detailUtils, MessageSortingHandler, MessageStripHelper, SectionTitleHandler, SideContentHandler, ExtensionAPI,
37
39
  ResponsiveTable, ShareUtils, FeLogger, MultipleViewsHandler, MessageUtils, KeyCodes, merge, FilterProcessor,
38
40
  StableIdHelper, extend, isEmptyObject, FeError,
39
41
  CreateWithDialogHandler, Device, whitespaceReplacer, deepExtend, CtxMenuHandler,
40
- InlineCreationRowsHelper, RelatedAppsHandler
42
+ InlineCreationRowsHelper, RelatedAppsHandler, Lib, PasteHandler
41
43
  ) {
42
44
  "use strict";
43
45
  var sClassName = "ObjectPage.controller.ControllerImplementation";
@@ -77,6 +79,7 @@ sap.ui.define([
77
79
  //TODO: Need to see whether we need to initialize the SideContentHandler here
78
80
  var oSideContentHandler = new SideContentHandler(oController, oTemplateUtils, oTemplateUtils.oComponentUtils.stateChanged); // handles all task connected with SideContent
79
81
  var oRelatedAppsHandler = new RelatedAppsHandler(oController, oTemplateUtils); //Handle related app Case
82
+ var oPasteHandler = new PasteHandler(oController, oTemplateUtils);
80
83
  var oContextMenuHandler = new CtxMenuHandler(oController, oTemplateUtils, oState, {
81
84
  deleteEntries: function(oSmartTable, aContexts){
82
85
  var oTable = oSmartTable.getTable();
@@ -145,7 +148,6 @@ sap.ui.define([
145
148
  var oUIModel = oObjectPage.getModel("ui");
146
149
  var bCreateMode = oUIModel.getProperty("/createMode");
147
150
  oActivationPromise.then(function (oResponse) {
148
- fnDetachPasteHandlers();
149
151
  // when the message model contains at least one transient message this will be shown at the end of the busy session. Otherwise we show a generic success message.
150
152
  MessageUtils.showSuccessMessageIfRequired(oTemplateUtils.oCommonUtils.getText(bCreateMode ? "OBJECT_CREATED" : "OBJECT_SAVED"), oTemplateUtils.oServices);
151
153
  // it's not enough to set root to dirty: Scenario: subitem has been displayed (active document), then changed (draft) and shall be
@@ -662,127 +664,6 @@ sap.ui.define([
662
664
  Function.prototype);
663
665
  }
664
666
 
665
- // BEGIN - Functions related to the copy-paste from Excel
666
-
667
- function fnOnBeforeSmartTablePaste(oEvent) {
668
- var aColumnData = oEvent.getParameter("columnInfos");
669
- //Remove the ignored fields(not visible in the table and actions) from the column data
670
- var index = aColumnData && aColumnData.length - 1;
671
-
672
- while (index >= 0) {
673
- if (aColumnData[index].ignore) {
674
- aColumnData.splice(index, 1);
675
- }
676
- index -= 1;
677
- }
678
- //Using separate loops to work on the array without ignored fields.
679
- var aUnsupportedColumns = aColumnData.reduce(function (aColumns, oColumn) {
680
- // Data formats for which paste is not yet supported.
681
- if (!oColumn.type && !oColumn.customParseFunction) {
682
- aColumns.push(oColumn);
683
- }
684
- return aColumns;
685
- }, []);
686
-
687
- if (aUnsupportedColumns.length > 0) {
688
- //Appropriate messages for columns with unsupported data formats.
689
- var sUnsupportedFormatError = oTemplateUtils.oCommonUtils.getText("DATA_PASTE_UNSUPPORTED_FORMAT_MESSAGE");
690
- MessageBox.show(sUnsupportedFormatError, {
691
- icon: MessageBox.Icon.ERROR,
692
- title: oTemplateUtils.oCommonUtils.getText("ST_ERROR"),
693
- actions: [sap.m.MessageBox.Action.CLOSE]
694
- });
695
- }
696
- }
697
-
698
- // returns the Create button for the given SmartTable if it exists (otherwise a faulty value is returned)
699
- function getCreateButtonForTable(oSmartTable){
700
- var sSmartTableId = oSmartTable.getId();
701
- var sAddEntryId = sSmartTableId.split("::Table")[0] + "::addEntry";
702
- var oAddEntry = oController.byId(sAddEntryId); //Instance of the Create button
703
- return oAddEntry;
704
- }
705
-
706
- function fnOnSmartTablePaste(oEvent) {
707
- var aParsedData;
708
- var oSmartTable = oEvent.getSource();
709
- var oAddEntry = getCreateButtonForTable(oSmartTable);
710
- var sSmartTableCreationMode = fnGetSmartTableCreationMode(oSmartTable);
711
- var bIsInlineCreationRowsEnabled = ["creationRows", "creationRowsHiddenInEditMode"].includes(sSmartTableCreationMode);
712
- //Paste is allowed when an add button is present in the table (or) inline creation rows feature is enabled
713
- var bIsPasteAllowed = oAddEntry || bIsInlineCreationRowsEnabled;
714
- var oEventSource = oAddEntry || oSmartTable;
715
- if (!bIsPasteAllowed) {
716
- return;
717
- }
718
- var oResult = oEvent.getParameter("result");
719
- if (oResult) {
720
- if (oResult.errors) {
721
- var aErrorMessages = oResult.errors.map(function (oElement) {
722
- return oElement.message;
723
- });
724
- var sPasteError = oTemplateUtils.oCommonUtils.getText("DATA_PASTE_ERROR_MESSAGE", [aErrorMessages.length]);
725
- var sErrorCorrection = oTemplateUtils.oCommonUtils.getText("DATA_PASTE_ERROR_CORRECTION_MESSAGE");
726
- var sNote = oTemplateUtils.oCommonUtils.getText("DATA_PASTE_ERROR_CORRECTION_NOTE");
727
- //Push correction message and note message to the aErrorMessages
728
- aErrorMessages.unshift(""); //To show space b/w the short text and detail text
729
- aErrorMessages.unshift(sNote);
730
- aErrorMessages.unshift(sErrorCorrection);
731
- MessageBox.show(sPasteError, {
732
- icon: MessageBox.Icon.ERROR,
733
- title: oTemplateUtils.oCommonUtils.getText("ST_ERROR"),
734
- actions: [sap.m.MessageBox.Action.CLOSE],
735
- details: aErrorMessages.join("<br>")
736
- });
737
- } else if (oResult.parsedData) {
738
- aParsedData = oResult.parsedData;
739
- if (aParsedData && aParsedData.length) {
740
- var iParsedDataLength = aParsedData.length;
741
- var bIgnoreTableRefresh;
742
- var oAddEntryPromise, aAddEntryPromises = [];
743
- var DraftSavedState = sap.m.DraftIndicatorState.Saved; //Indicator for the footer
744
-
745
- for (var i = 0; i < iParsedDataLength; i++) {
746
- bIgnoreTableRefresh = i < iParsedDataLength - 1; //Flag to overcome multiple table refreshes when records are pasted.
747
- oAddEntryPromise = oTemplateUtils.oCommonEventHandlers.addEntry(oEventSource, true, undefined, aParsedData[i], bIgnoreTableRefresh);
748
- aAddEntryPromises.push(oAddEntryPromise);
749
- }
750
-
751
- Promise.all(aAddEntryPromises).then(function () {
752
- //After the records are added, show a draft saved indicator on the footer
753
- var oTemplatePrivateGlobal = oTemplateUtils.oComponentUtils.getTemplatePrivateGlobalModel();
754
- oTemplatePrivateGlobal.setProperty("/generic/draftIndicatorState", DraftSavedState);
755
- });
756
- }
757
- }
758
- }
759
- }
760
-
761
- /*
762
- Function to detach the paste handlers once the user is out of edit mode.
763
- We do not want to initialize the paste functionality when the object page is in display mode.
764
- */
765
- function fnDetachPasteHandlers() {
766
- //To-DO: Evaluate if there's a better way of doing this. Refactor if required.
767
- var oTemplatePrivateModel = oTemplateUtils.oComponentUtils.getTemplatePrivateModel();
768
- var aPasteAttachedTables = oTemplatePrivateModel.getProperty("/objectPage/aPasteAttachedTables");
769
- var index = aPasteAttachedTables.length;
770
- var sFacet;
771
- var oControl;
772
- while (index >= 0) {
773
- sFacet = aPasteAttachedTables[index];
774
- oControl = oController.byId(sFacet + "::Table");
775
- if (oControl && oControl.isA("sap.ui.comp.smarttable.SmartTable") && oControl.hasListeners("paste")) {
776
- oControl.detachBeforePaste(fnOnBeforeSmartTablePaste);
777
- oControl.detachPaste(fnOnSmartTablePaste);
778
- aPasteAttachedTables.splice(index, 1);
779
- }
780
- index -= 1;
781
- }
782
- }
783
-
784
- // END - Functions related to the copy-paste from Excel
785
-
786
667
  function onDelete() {
787
668
  oTemplateUtils.oCommonUtils.executeIfControlReady(onDeleteImpl, "delete");
788
669
  }
@@ -1510,7 +1391,7 @@ sap.ui.define([
1510
1391
  return oEditableCell;
1511
1392
  }
1512
1393
  if (oTemplateUtils.oComponentUtils.isDraftEnabled()) {
1513
- var oCreateButton = getCreateButtonForTable(oControl);
1394
+ var oCreateButton = oTemplateUtils.oCommonUtils.getCreateButtonForTable(oControl);
1514
1395
  if (oCreateButton && oCreateButton.isFocusable()){
1515
1396
  return oCreateButton;
1516
1397
  }
@@ -1954,7 +1835,7 @@ sap.ui.define([
1954
1835
  }
1955
1836
  });
1956
1837
  }
1957
-
1838
+
1958
1839
  oViewProxy.applyState = function (oState, bIsSameAsLast) {
1959
1840
  // originally, applyState was only called when HeaderData was available, as HeaderData was always used to determine bIsSameAsLast
1960
1841
  // now, in some cases bIsSameAsLast can be determined earlier, however, we don't know, whether any extensions implicitly rely on header data being available
@@ -2338,7 +2219,6 @@ sap.ui.define([
2338
2219
  oState.oSectionTitleHandler = new SectionTitleHandler(oController, oObjectPage);
2339
2220
 
2340
2221
  var oTemplatePrivateModel = oTemplateUtils.oComponentUtils.getTemplatePrivateModel();
2341
- oTemplatePrivateModel.setProperty("/objectPage/aPasteAttachedTables", []);
2342
2222
  oTemplateUtils.oComponentUtils.attach(oController, "PageDataLoaded", function (oEvent) {
2343
2223
  var aStreamEnabledAssociatedEntities = oTemplateUtils.oComponentUtils.getParameterModelForTemplating().getObject("/templateSpecific/streamEnabledAssociatedEntites");
2344
2224
  if (aStreamEnabledAssociatedEntities && aStreamEnabledAssociatedEntities.length > 0) {
@@ -2439,7 +2319,6 @@ sap.ui.define([
2439
2319
  var bStaysOnPage = !bIsEditFlowDirect && !(oObjectPage.getModel("ui").getProperty("/createMode"));
2440
2320
  var oCancelPromise = oBase.state.onCancel(oCancelButton, bStaysOnPage && fnFocusOnFirstActionButton);
2441
2321
  oCancelPromise.then(function () {
2442
- fnDetachPasteHandlers();
2443
2322
  if (!bIsDraftEnabled) {
2444
2323
  fnReturnToDisplayNonDraft();
2445
2324
  }
@@ -2486,6 +2365,16 @@ sap.ui.define([
2486
2365
  onRelatedApps: function (oEvent) {
2487
2366
  oRelatedAppsHandler.getRelatedApps(oEvent);
2488
2367
  },
2368
+
2369
+ onSummarize: function () {
2370
+ var sUrl = oTemplateUtils.oServices.oApplication.getSummarizationLibraryUrl();
2371
+ Lib.load({name: "ux.eng.fioriai.reuse", url: sUrl}).then(function() {
2372
+ sap.ui.require(["ux/eng/fioriai/reuse/library"], function(fioriaiLib) {
2373
+ fioriaiLib.summarize({view: oController.getView()});
2374
+ });
2375
+ });
2376
+ },
2377
+
2489
2378
  onEdit: function (oEvent) {
2490
2379
  var oEditButton = oController.byId("edit");
2491
2380
  if (oEditButton.data("CrossNavigation")) {
@@ -2553,7 +2442,7 @@ sap.ui.define([
2553
2442
  onChartInit: function (oEvent) {
2554
2443
  var oSmartChart = oEvent.getSource();
2555
2444
  oTemplateUtils.oInfoObjectHandler.setInformationWithControl(oSmartChart);
2556
- oState.oSectionTitleHandler.setAsTitleOwner(oSmartChart);
2445
+ oState.oSectionTitleHandler.setAsTitleOwner(oSmartChart, true);
2557
2446
  oSmartChart.getChartAsync().then(function (oChart) {
2558
2447
  // workaround for Safari browsers as described via Webkit Bug #198375
2559
2448
  if (Device.browser.safari) {
@@ -2707,7 +2596,7 @@ sap.ui.define([
2707
2596
  var oSmartTable = oEvent.getSource();
2708
2597
  var oTable = oSmartTable.getTable();
2709
2598
  var oInfoObject = oTemplateUtils.oInfoObjectHandler.setInformationWithControl(oSmartTable);
2710
- oState.oSectionTitleHandler.setAsTitleOwner(oSmartTable);
2599
+ oState.oSectionTitleHandler.setAsTitleOwner(oSmartTable, true);
2711
2600
  // TableObserver is required to get the Smart Table's editable property for Smart
2712
2601
  // MultiInput Control
2713
2602
  var oModel = new ManagedObjectModel(oSmartTable);
@@ -2749,33 +2638,18 @@ sap.ui.define([
2749
2638
  });
2750
2639
  }
2751
2640
 
2752
- var oTemplatePrivateModel = oTemplateUtils.oComponentUtils.getTemplatePrivateModel();
2753
- var aCreationModesSupportPaste = ["inline", "creationRows", "creationRowsHiddenInEditMode"];
2754
- var sSmartTableCreationMode = fnGetSmartTableCreationMode(oSmartTable);
2755
- if (aCreationModesSupportPaste.indexOf(sSmartTableCreationMode) > -1) {
2756
- oTable.addEventDelegate({
2757
- //Attach paste handlers for tables in edit mode
2758
- onAfterRendering: function (oEvent) {
2759
- var aPasteAttachedTables;
2760
- if (oSmartTable.getEditable() && !oSmartTable.hasListeners("paste")) {
2761
- oSmartTable.attachBeforePaste(fnOnBeforeSmartTablePaste);
2762
- oSmartTable.attachPaste(fnOnSmartTablePaste);
2763
- aPasteAttachedTables = oTemplatePrivateModel.getProperty("/objectPage/aPasteAttachedTables");
2764
- if (aPasteAttachedTables) {
2765
- aPasteAttachedTables.push(sCurrentFacet);
2766
- }
2767
- }
2768
- }
2769
- });
2770
- }
2771
-
2772
2641
  oTemplateUtils.oServices.oPresentationControlHandlerFactory.getPresentationControlHandler(oSmartTable).addCellSelector();
2773
2642
  },
2774
2643
  onBeforeExport: function (oExportEvent) {
2775
2644
  oTemplateUtils.oCommonEventHandlers.onBeforeExport(oExportEvent);
2776
2645
  },
2646
+ onBeforePaste: function(sSmartTableId, oEvent) {
2647
+ oPasteHandler.handleBeforePaste(sSmartTableId, oEvent);
2648
+ },
2649
+ onPaste: function(sSmartTableId, oEvent) {
2650
+ oPasteHandler.handlePaste(sSmartTableId, oEvent);
2651
+ },
2777
2652
  onSearchObjectPage: onSearchObjectPage,
2778
- onSmartTablePaste: fnOnSmartTablePaste,
2779
2653
  onUITableExpand: fnHandleUITableExpand,
2780
2654
  onSingleSectionOrSubsectionVisible: fnIsSingleSectionOrSubsectionVisible,
2781
2655
  dataStateFilter: fnDataStateFilter,