@sapui5/sap.suite.ui.generic.template 1.139.0 → 1.141.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 (149) 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 +7 -9
  4. package/src/sap/suite/ui/generic/template/AnalyticalListPage/extensionAPI/ExtensionAPI.js +4 -1
  5. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_ar.properties +0 -2
  6. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_bg.properties +0 -2
  7. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_ca.properties +0 -2
  8. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_cnr.properties +0 -2
  9. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_cs.properties +0 -2
  10. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_cy.properties +0 -2
  11. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_da.properties +0 -2
  12. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_de.properties +0 -2
  13. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_el.properties +0 -2
  14. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_en.properties +0 -2
  15. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_en_GB.properties +0 -2
  16. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_en_US_saprigi.properties +0 -2
  17. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_es.properties +0 -2
  18. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_es_MX.properties +0 -2
  19. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_et.properties +0 -2
  20. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_fi.properties +0 -2
  21. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_fr.properties +0 -2
  22. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_fr_CA.properties +0 -2
  23. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_hi.properties +0 -2
  24. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_hr.properties +0 -2
  25. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_hu.properties +0 -2
  26. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_id.properties +0 -2
  27. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_it.properties +0 -2
  28. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_iw.properties +0 -2
  29. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_ja.properties +0 -2
  30. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_kk.properties +0 -2
  31. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_ko.properties +0 -2
  32. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_lt.properties +0 -2
  33. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_lv.properties +0 -2
  34. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_mk.properties +0 -2
  35. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_ms.properties +0 -2
  36. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_nl.properties +0 -2
  37. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_no.properties +0 -2
  38. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_pl.properties +0 -2
  39. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_pt.properties +0 -2
  40. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_pt_PT.properties +0 -2
  41. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_ro.properties +0 -2
  42. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_ru.properties +0 -2
  43. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_sh.properties +0 -2
  44. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_sk.properties +0 -2
  45. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_sl.properties +0 -2
  46. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_sr.properties +0 -2
  47. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_sv.properties +0 -2
  48. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_th.properties +0 -2
  49. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_tr.properties +0 -2
  50. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_uk.properties +0 -2
  51. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_vi.properties +0 -2
  52. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_zh_CN.properties +0 -2
  53. package/src/sap/suite/ui/generic/template/AnalyticalListPage/i18n/i18n_zh_TW.properties +0 -2
  54. package/src/sap/suite/ui/generic/template/AnalyticalListPage/manifest.json +1 -1
  55. package/src/sap/suite/ui/generic/template/Canvas/extensionAPI/ExtensionAPI.js +4 -1
  56. package/src/sap/suite/ui/generic/template/Canvas/manifest.json +1 -1
  57. package/src/sap/suite/ui/generic/template/ListReport/controller/IappStateHandler.js +34 -33
  58. package/src/sap/suite/ui/generic/template/ListReport/extensionAPI/ExtensionAPI.js +4 -1
  59. package/src/sap/suite/ui/generic/template/ListReport/manifest.json +1 -1
  60. package/src/sap/suite/ui/generic/template/ListReport/view/fragments/SmartTable.fragment.xml +1 -0
  61. package/src/sap/suite/ui/generic/template/ObjectPage/annotationHelpers/AnnotationHelperActionButtons.js +49 -5
  62. package/src/sap/suite/ui/generic/template/ObjectPage/annotationHelpers/AnnotationHelperActionButtons.qunit.js +27 -0
  63. package/src/sap/suite/ui/generic/template/ObjectPage/controller/ControllerImplementation.js +65 -23
  64. package/src/sap/suite/ui/generic/template/ObjectPage/controller/RelatedAppsHandler.js +3 -1
  65. package/src/sap/suite/ui/generic/template/ObjectPage/controller/SectionTitleHandler.js +17 -13
  66. package/src/sap/suite/ui/generic/template/ObjectPage/controllerFrameworkExtensions.js +285 -270
  67. package/src/sap/suite/ui/generic/template/ObjectPage/extensionAPI/ExtensionAPI.js +4 -1
  68. package/src/sap/suite/ui/generic/template/ObjectPage/manifest.json +1 -1
  69. package/src/sap/suite/ui/generic/template/ObjectPage/view/Details.view.xml +2 -3
  70. package/src/sap/suite/ui/generic/template/ObjectPage/view/fragments/Actions.fragment.xml +18 -2
  71. package/src/sap/suite/ui/generic/template/ObjectPage/view/fragments/CRUDActionButtons.fragment.xml +31 -24
  72. package/src/sap/suite/ui/generic/template/ObjectPage/view/fragments/SmartForm.fragment.xml +1 -0
  73. package/src/sap/suite/ui/generic/template/ObjectPage/view/fragments/SmartTable.fragment.xml +1 -0
  74. package/src/sap/suite/ui/generic/template/QuickCreate/manifest.json +1 -1
  75. package/src/sap/suite/ui/generic/template/QuickView/manifest.json +1 -1
  76. package/src/sap/suite/ui/generic/template/designtime/controls/DynamicPage.designtime.js +2 -2
  77. package/src/sap/suite/ui/generic/template/designtime/controls/ObjectPageLayout.designtime.js +2 -2
  78. package/src/sap/suite/ui/generic/template/designtime/controls/SmartFilterBar.designtime.js +2 -2
  79. package/src/sap/suite/ui/generic/template/designtime/controls/SmartTable.designtime.js +2 -2
  80. package/src/sap/suite/ui/generic/template/designtime/utils/designtimeUtils.js +6 -1
  81. package/src/sap/suite/ui/generic/template/fragments/AINotice.fragment.xml +24 -0
  82. package/src/sap/suite/ui/generic/template/fragments/ToolbarButton.fragment.xml +1 -0
  83. package/src/sap/suite/ui/generic/template/genericUtilities/polyFill.js +6 -7
  84. package/src/sap/suite/ui/generic/template/js/AnnotationHelper.js +120 -0
  85. package/src/sap/suite/ui/generic/template/lib/AppComponent.js +3 -2
  86. package/src/sap/suite/ui/generic/template/lib/CRUDManager.js +97 -14
  87. package/src/sap/suite/ui/generic/template/lib/CommonEventHandlers.js +4 -2
  88. package/src/sap/suite/ui/generic/template/lib/CommonUtils.js +23 -14
  89. package/src/sap/suite/ui/generic/template/lib/ai/EasyFill/EasyFillHandler.js +407 -0
  90. package/src/sap/suite/ui/generic/template/lib/ai/EasyFill/fragments/EasyFillDialog.fragment.xml +82 -0
  91. package/src/sap/suite/ui/generic/template/lib/ai/EasyFill/fragments/EasyFillNonUpdatableSmartForm.fragment.xml +18 -0
  92. package/src/sap/suite/ui/generic/template/lib/ai/EasyFill/fragments/EasyFillUpdatebleSmartForm.fragment.xml +15 -0
  93. package/src/sap/suite/ui/generic/template/lib/ai/EasyFilterBarHandler.js +40 -5
  94. package/src/sap/suite/ui/generic/template/lib/ai/FioriAIHandler.js +2 -1
  95. package/src/sap/suite/ui/generic/template/lib/i18n/i18n.properties +72 -0
  96. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ar.properties +48 -0
  97. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_bg.properties +48 -0
  98. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ca.properties +48 -0
  99. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_cnr.properties +48 -0
  100. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_cs.properties +48 -0
  101. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_cy.properties +48 -0
  102. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_da.properties +48 -0
  103. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_de.properties +48 -0
  104. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_el.properties +48 -0
  105. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en.properties +48 -0
  106. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en_GB.properties +48 -0
  107. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_en_US_saprigi.properties +48 -0
  108. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_es.properties +48 -0
  109. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_es_MX.properties +48 -0
  110. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_et.properties +48 -0
  111. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_fi.properties +48 -0
  112. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_fr.properties +48 -0
  113. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_fr_CA.properties +48 -0
  114. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_hi.properties +48 -0
  115. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_hr.properties +48 -0
  116. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_hu.properties +48 -0
  117. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_id.properties +51 -3
  118. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_it.properties +48 -0
  119. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_iw.properties +48 -0
  120. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ja.properties +48 -0
  121. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_kk.properties +48 -0
  122. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ko.properties +49 -1
  123. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_lt.properties +48 -0
  124. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_lv.properties +48 -0
  125. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_mk.properties +48 -0
  126. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ms.properties +48 -0
  127. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_nl.properties +48 -0
  128. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_no.properties +48 -0
  129. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_pl.properties +48 -0
  130. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_pt.properties +48 -0
  131. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_pt_PT.properties +48 -0
  132. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ro.properties +48 -0
  133. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_ru.properties +48 -0
  134. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sh.properties +48 -0
  135. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sk.properties +48 -0
  136. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sl.properties +48 -0
  137. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sr.properties +48 -0
  138. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_sv.properties +48 -0
  139. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_th.properties +48 -0
  140. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_tr.properties +48 -0
  141. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_uk.properties +48 -0
  142. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_vi.properties +48 -0
  143. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_zh_CN.properties +48 -0
  144. package/src/sap/suite/ui/generic/template/lib/i18n/i18n_zh_TW.properties +48 -0
  145. package/src/sap/suite/ui/generic/template/lib/navigation/NavigationController.js +1 -1
  146. package/src/sap/suite/ui/generic/template/lib/presentationControl/SmartTableHandler.js +1 -1
  147. package/src/sap/suite/ui/generic/template/library.js +1 -1
  148. package/src/sap/suite/ui/generic/template/listTemplates/controller/SmartChartController.js +5 -3
  149. package/src/sap/suite/ui/generic/template/themes/base/ObjectPage.less +51 -0
@@ -643,8 +643,10 @@ sap.ui.define(["sap/ui/base/Object",
643
643
  }
644
644
  }
645
645
 
646
- function callActionImpl(mParameters, oState, fnResolve, fnReject){
647
- if (oBusyHelper.isBusy()){
646
+ async function callActionImpl(mParameters, oState, fnResolve, fnReject){
647
+ // Standardize the extension API flag access
648
+ const bInvokedByExtensionApi = mParameters.bInvokedByExtensionApi || false;
649
+ if (oBusyHelper.isBusy() && !bInvokedByExtensionApi) {
648
650
  fnReject();
649
651
  return;
650
652
  }
@@ -656,6 +658,7 @@ sap.ui.define(["sap/ui/base/Object",
656
658
  var aWarningIndex = [];
657
659
  var aCurrentContexts = mParameters.contexts || [];
658
660
  var oSourceControlHandler = mParameters.sourceControlHandler;
661
+ let bCallerSuppliedContexts = aCurrentContexts.length > 0;
659
662
  // Code to support context Independent actions with parameter
660
663
  // If the context is not present then a new context will be created.
661
664
  if (aCurrentContexts.length === 0 && oSourceControlHandler) {
@@ -670,10 +673,12 @@ sap.ui.define(["sap/ui/base/Object",
670
673
  var fnCleanUpContext = function(){
671
674
  // remove pending request from the last change of the model
672
675
  // actually, this should rather be done by ActionUtil itself
673
- if (aCurrentContexts[0]){
674
- var oModel = aCurrentContexts[0].oModel;
675
- if (oModel && oModel.hasPendingChanges()){
676
- oModel.resetChanges();
676
+ if (!bInvokedByExtensionApi){
677
+ if (aCurrentContexts[0]){
678
+ var oModel = aCurrentContexts[0].oModel;
679
+ if (oModel && oModel.hasPendingChanges()){
680
+ oModel.resetChanges();
681
+ }
677
682
  }
678
683
  }
679
684
  };
@@ -730,14 +735,32 @@ sap.ui.define(["sap/ui/base/Object",
730
735
  operationGrouping: sOperationGrouping,
731
736
  handleFocus: oServices.controllerServices && oServices.controllerServices.getRestoreFocusHelper
732
737
  ? oServices.controllerServices.getRestoreFocusHelper().rememberFocus
733
- : null
738
+ : null,
739
+ actionParameters: mParameters.urlParameters,
740
+ invokedByExtensionApi: bInvokedByExtensionApi
734
741
  });
735
742
  oActionProcessor.call(bIsStrict).then(function(oResult){
736
743
  var oSessionParams = {};
737
744
  oSessionParams.actionLabel = sFunctionImportLabel;
738
745
  oServices.oApplication.setNextFocus(Function.prototype);
739
- oBusyHelper.setBusy(oResult.executionPromise, null, oSessionParams);
740
- oResult.executionPromise.then(fnHandleResponse,fnHandleResponse);
746
+ // Skip busy state management for extension API-invoked actions.
747
+ // This allows extension consumers to handle their own loading states and transient message processing,
748
+ // preventing conflicts with the framework's automatic message handling.
749
+ const bShouldManageBusyState = !bInvokedByExtensionApi;
750
+ if (bShouldManageBusyState) {
751
+ oBusyHelper.setBusy(oResult.executionPromise, null, oSessionParams);
752
+ }
753
+ // Handle the result of the action execution promise:
754
+ // On success, process the response with fnHandleResponse.
755
+ // On error, also process the response, then reject the outer promise if the UI is still busy (prevents unresolved busy states).
756
+ oResult.executionPromise.then((vResponse) => {
757
+ fnHandleResponse(vResponse);
758
+ }).catch((vResponse) => {
759
+ fnHandleResponse(vResponse);
760
+ if (oBusyHelper.isBusy() && bInvokedByExtensionApi) {
761
+ fnReject();
762
+ }
763
+ });
741
764
  }, fnActionPopUpReject);
742
765
 
743
766
  var fnHandleResponse = function(vResponse) {
@@ -767,11 +790,59 @@ sap.ui.define(["sap/ui/base/Object",
767
790
  // Cache the error message to avoid duplicate display later
768
791
  MessageUtils.cacheWarningMessage(oErrorReponse.error);
769
792
  }
770
- });
793
+ });
771
794
  fnShowWarningPopupIfRequired(oParsedResult.aMessagesForUserDecision, fnDone.bind(null, aResponse));
772
795
  };
773
796
  var fnDone = function(aResponses){
774
797
  var aTotalResp = aFailed.concat(aSuccess.concat(aWarning));
798
+ if (bInvokedByExtensionApi) {
799
+ // If the action is triggered via the extension API, format the response(s) in a way expected by extension consumers.
800
+ // Helper to build the response object for each action result.
801
+ const buildResponse = (oResponse) => {
802
+ // Check if the action was executed successfully using the action processor's status
803
+ if (oActionProcessor.getExecutedSuccessfully()) {
804
+ // Create a standardized success response object containing the essential data
805
+ const oBaseResponse = {
806
+ context: oResponse.context,
807
+ response: oResponse.response,
808
+ data: oResponse.data
809
+ };
810
+ // If the caller provided specific contexts, include the actionContext in the response.
811
+ if (bCallerSuppliedContexts) {
812
+ return {
813
+ actionContext: oResponse.actionContext,
814
+ response: oBaseResponse
815
+ };
816
+ }
817
+ return { response: oBaseResponse };
818
+ } else {
819
+ // Handle error scenarios, create error response structure
820
+ const oErrorResponse = {
821
+ error: {
822
+ response: oResponse.response
823
+ }
824
+ };
825
+ // If the caller provided specific contexts, include the actionContext in the response.
826
+ if (bCallerSuppliedContexts) {
827
+ return {
828
+ actionContext: oResponse.actionContext,
829
+ ...oErrorResponse
830
+ };
831
+ }
832
+ return oErrorResponse;
833
+ }
834
+ };
835
+ let aFinalResponses = aTotalResp.map(buildResponse);
836
+ oServices.oApplication.setNextFocus(() => {
837
+ MessageUtils.clearWarningCache();
838
+ });
839
+ if (oActionProcessor.getExecutedSuccessfully()) {
840
+ fnResolve(aFinalResponses);
841
+ } else {
842
+ fnReject(aFinalResponses);
843
+ }
844
+ return;
845
+ }
775
846
  if (aTotalResp.length > 1){
776
847
  // case for multiple selection. Some of them may fail or throw warning, so show a hint if any warning occurs.
777
848
  var bWarningOccured = aWarning.length > 0;
@@ -817,7 +888,7 @@ sap.ui.define(["sap/ui/base/Object",
817
888
  oContextInfo = oServices.oApplication.registerContext(oResponseContext);
818
889
  }
819
890
 
820
- if (oResponseContext && oResponseContext !== oActionContext && oResponseContext.getPath() !== "/undefined"){
891
+ if (oResponseContext && oResponseContext !== oActionContext && oResponseContext.getPath() !== "/undefined" && mParameters.navigateToInstance !== "false"){
821
892
  oServices.oApplication.setNextFocus(function(oBeforeData, fnFallback){
822
893
  // Clear any cached error messages since the action has completed
823
894
  MessageUtils.clearWarningCache();
@@ -825,7 +896,8 @@ sap.ui.define(["sap/ui/base/Object",
825
896
  ignorePersistence: true
826
897
  });
827
898
  });
828
- oServices.oApplication.navigateToDetailContextIfPossible(oResponseContext, false, oContextInfo.bIsDraft ? 2 * (1 + oContextInfo.bIsCreate) : 1, oContextInfo);
899
+ var bIsDeterminingAction = mParameters.actionType === "determining";
900
+ oServices.oApplication.navigateToDetailContextIfPossible(oResponseContext, bIsDeterminingAction, oContextInfo.bIsDraft ? 2 * (1 + oContextInfo.bIsCreate) : 1, oContextInfo);
829
901
  } else {
830
902
  // Restore focus, because we don't navigate out
831
903
  oServices.oApplication.setNextFocus(function(oBeforeData, fnFallback){
@@ -852,7 +924,15 @@ sap.ui.define(["sap/ui/base/Object",
852
924
  }
853
925
  };
854
926
  };
855
- fnInvokeAction(true, bWithWarningDialog, aCurrentContexts);
927
+ // Determine whether to invoke the action with strict handling (412 support)
928
+ // If `mParameters.bStrict` is `undefined`, assume it's an annotation-based action and enable strict mode by default (`true`). This ensures standard behaviour.
929
+ // If `mParameters.bStrict` is explicitly defined (e.g., via extension API or other sources),
930
+ // use its value to determine whether strict mode (and thus 412 support) should be enabled.
931
+ if (mParameters.bStrict === undefined){
932
+ fnInvokeAction(true, bWithWarningDialog, aCurrentContexts);
933
+ } else {
934
+ fnInvokeAction(mParameters.bStrict, bWithWarningDialog, aCurrentContexts);
935
+ }
856
936
  }
857
937
 
858
938
  /*
@@ -871,7 +951,7 @@ sap.ui.define(["sap/ui/base/Object",
871
951
  * @public
872
952
  */
873
953
  function callAction(mParameters, oState) {
874
- var oModel = oController.getView().getModel();
954
+ var oModel = oController.getView().getModel() || mParameters.oModelFromExtensionApi;
875
955
  var oMetaModel = oModel.getMetaModel();
876
956
  var oComponent = oController.getOwnerComponent();
877
957
  var sEntitySet = oComponent.getEntitySet();
@@ -882,6 +962,9 @@ sap.ui.define(["sap/ui/base/Object",
882
962
  var oEntityType = oMetaModel.getODataEntityType(sEntityType);
883
963
  mParameters.functionImport = oFunctionImport;
884
964
  mParameters.entityType = oEntityType;
965
+ if (!mParameters?.label && oFunctionImport?.["name"]) {
966
+ mParameters.label = oFunctionImport["name"];
967
+ }
885
968
  if (sFunctionImportReturnType === sEntityType) {
886
969
  var oAppComponent = oComponent.getAppComponent();
887
970
  var oOPComponentUtils = oServices.oApplication.getComponentUtilsIfLoaded(sEntitySet); // oOPComponentUtils would differ from oComponentUtils if this instance belongs to the root page
@@ -2177,7 +2177,8 @@ sap.ui.define(["sap/ui/base/Object",
2177
2177
  sourceControl: oSourceControl,
2178
2178
  label: oCustomData.Label,
2179
2179
  operationGrouping: oCustomData.InvocationGrouping,
2180
- skipProperties: oSkipProperties
2180
+ skipProperties: oSkipProperties,
2181
+ navigateToInstance: oCustomData.IsNavigateToInstance
2181
2182
  }, oState, sEntitySet);
2182
2183
  }
2183
2184
  }
@@ -2303,7 +2304,8 @@ sap.ui.define(["sap/ui/base/Object",
2303
2304
  sourceControlHandler: oServices.oPresentationControlHandlerFactory.getPresentationControlHandler(oCommonUtils.getOwnerPresentationControl(oControl)),
2304
2305
  label: mParams.label,
2305
2306
  operationGrouping: mParams.operationGrouping,
2306
- skipProperties: mParams.skipProperties
2307
+ skipProperties: mParams.skipProperties,
2308
+ navigateToInstance: mParams.navigateToInstance
2307
2309
  }, oState).then(function(aResponses) {
2308
2310
  if (aResponses) {
2309
2311
  aResponses.some(function(oResponse){
@@ -212,8 +212,8 @@ sap.ui.define(["sap/ui/base/Object",
212
212
  }
213
213
 
214
214
  // sap.suite.ui.generic.template.lib.CommonUtils.prototype.getSelectedContexts.getDialogFragment below
215
- function getDialogFragmentAsync(sName, oFragmentController, sModel, fnOnFragmentCreated, bAlwaysGetNew) {
216
- return oServices.oApplication.getDialogFragmentForViewAsync(oController.getView(), sName, oFragmentController, sModel, fnOnFragmentCreated, bAlwaysGetNew);
215
+ function getDialogFragmentAsync(sName, oFragmentController, sModel, fnOnFragmentCreated, bAlwaysGetNew,bNoBusyAware) {
216
+ return oServices.oApplication.getDialogFragmentForViewAsync(oController.getView(), sName, oFragmentController, sModel, fnOnFragmentCreated, bAlwaysGetNew,bNoBusyAware);
217
217
  }
218
218
 
219
219
  var oResourceBundle; // initialized on first use
@@ -1511,13 +1511,19 @@ sap.ui.define(["sap/ui/base/Object",
1511
1511
  * @param {map} [mUrlParameters] The URL parameters (name-value pairs) for the function or action. This is not in oSettings for backward compatibility
1512
1512
  * @param {object} oSettings Parameters that are set for invoking Application controller's invokeActions method
1513
1513
  * @param {boolean} oSettings.bInvocationGroupingChangeSet Determines whether the common or unique changeset gets sent in batch
1514
+ * @param {string} [oSettings.sLabel=""] Optional label for the Function Import.
1515
+ * * This label is only used when action is invoked in strict mode and HTTP 412 (Precondition Failed) handling is required.
1516
+ * * If not provided, the Function Import name is used as the default label.
1517
+ * @param {boolean} [oSettings.bStrict=false] Optional flag to indicate whether the action should be invoked in strict mode. Defaults to <code>false</code>.
1514
1518
  * @returns {Promise} A <code>Promise</code> for asynchronous execution of the action, resolving to the same result as the <code>Promise</code>
1515
- * returned from {@link sap.ui.generic.app.ApplicationController}
1516
1519
  * @throws {Error} Throws an error if the OData function import does not exist or the action input parameters are invalid
1517
1520
  * @public
1518
1521
  */
1519
1522
  function fnInvokeActionsForExtensionAPI (sFunctionName, vContext, mUrlParameters, oSettings, oState) {
1520
- var aContext, mParameters = {};
1523
+ var aContext;
1524
+ let sOperationGrouping = oSettings?.bInvocationGroupingChangeSet ? "com.sap.vocabularies.UI.v1.OperationGroupingType/ChangeSet" : "";
1525
+ let sLabel = oSettings?.sLabel ?? "";
1526
+ let bStrict = oSettings?.bStrict ?? false;
1521
1527
  if (!vContext) {
1522
1528
  aContext = [];
1523
1529
  } else if (Array.isArray(vContext)) {
@@ -1525,17 +1531,19 @@ sap.ui.define(["sap/ui/base/Object",
1525
1531
  } else {
1526
1532
  aContext = [ vContext ];
1527
1533
  }
1528
- if (mUrlParameters) {
1529
- mParameters.urlParameters = mUrlParameters;
1530
- }
1531
- if (oSettings && oSettings.bInvocationGroupingChangeSet) {
1532
- mParameters.operationGrouping = "com.sap.vocabularies.UI.v1.OperationGroupingType/ChangeSet";
1533
- }
1534
- mParameters.triggerChanges = oComponentUtils.isDraftEnabled();
1535
1534
  //Execute floorplan specific logic before invokeaction is executed
1536
1535
  oComponentUtils.executeBeforeInvokeActionFromExtensionAPI(oState);
1537
- //call invokeActions method
1538
- var oPromise = oServices.oApplicationController.invokeActions(sFunctionName, aContext, mParameters);
1536
+ const oPromise = oServices.oCRUDManager.callAction({
1537
+ "contexts": aContext,
1538
+ "functionImportPath": sFunctionName,
1539
+ "label": sLabel,
1540
+ "operationGrouping": sOperationGrouping,
1541
+ "skipProperties": {},
1542
+ "urlParameters": mUrlParameters,
1543
+ "bStrict": bStrict,
1544
+ "bInvokedByExtensionApi": true,
1545
+ "oModelFromExtensionApi": oController.getOwnerComponent()?.getModel()
1546
+ }, oState);
1539
1547
  if (oSettings && oSettings.bSetBusy) {
1540
1548
  oComponentUtils.getBusyHelper().setBusy(oPromise);
1541
1549
  }
@@ -1999,7 +2007,8 @@ sap.ui.define(["sap/ui/base/Object",
1999
2007
  contexts: aContexts,
2000
2008
  sourceControlHandler: oPresentationControlHandler,
2001
2009
  label: oCustomData.Label,
2002
- operationGrouping: ""
2010
+ operationGrouping: "",
2011
+ actionType: oCustomData.ActionType
2003
2012
  }).then(function(aResponses) {
2004
2013
  if (aResponses && aResponses.length > 0) {
2005
2014
  var oResponse = aResponses[0];