@sapui5/sap.ushell 1.125.0 → 1.126.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 +1 -1
- package/src/main/js/sap/ushell/.library +1 -1
- package/src/main/js/sap/ushell/Container.js +137 -62
- package/src/main/js/sap/ushell/Fiori20Adapter.js +1 -1
- package/src/main/js/sap/ushell/Fiori20AdapterTest.js +1 -1
- package/src/main/js/sap/ushell/NWBCInterface.js +1 -1
- package/src/main/js/sap/ushell/SessionHandler.js +35 -31
- package/src/main/js/sap/ushell/TechnicalParameters.js +1 -1
- package/src/main/js/sap/ushell/URLTemplateProcessor.js +1 -1
- package/src/main/js/sap/ushell/Ui5NativeServiceFactory.js +1 -1
- package/src/main/js/sap/ushell/Ui5ServiceFactory.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/DefinitionParameterSetBuilder.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/DependencyGraph.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/Functions.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/Resolvers.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/TemplateParameterParser.js +1 -1
- package/src/main/js/sap/ushell/_URLTemplateProcessor/utils.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/ClientSideTargetResolutionAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/CommonDataModelAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/ConfigurationDefaultsAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/ContainerAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/LaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/PagesCommonDataModelAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/PersonalizationAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/PersonalizationV2Adapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/Ui5ComponentLoaderAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/_LaunchPage/modifyHome.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/_LaunchPage/readCatalogs.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/_LaunchPage/readHome.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/_LaunchPage/uri.transform.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/util/AppForInbound.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/util/cdmSiteUtils.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/AdapterBase.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/FlpLaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/LaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/StaticGroupsAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readApplications.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readCatalogs.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readHome.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readPages.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readUtils.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/_LaunchPage/readVisualizations.js +1 -1
- package/src/main/js/sap/ushell/adapters/cdm/v3/utilsCdm.js +34 -0
- package/src/main/js/sap/ushell/adapters/cep/NavTargetResolutionAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cep/NavTargetResolutionInternalAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cep/SearchCEPAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/cflp/UserDefaultParameterPersistenceAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/AdapterContainer.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/AppStateAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/ClientSideTargetResolutionAdapter.js +4 -4
- package/src/main/js/sap/ushell/adapters/local/ContainerAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/FlpLaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/LaunchPageAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/NavTargetResolutionAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/NavTargetResolutionInternalAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/PageBuildingAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/PagePersistenceAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/PersonalizationAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/PersonalizationV2Adapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/SearchAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/SearchCEPAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/SupportTicketAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/Ui5ComponentLoaderAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/UserDefaultParameterPersistenceAdapter.js +1 -1
- package/src/main/js/sap/ushell/adapters/local/UserInfoAdapter.js +1 -1
- package/src/main/js/sap/ushell/api/RTA.js +14 -2
- package/src/main/js/sap/ushell/appRuntime/ui5/AppRuntime.js +5 -5
- package/src/main/js/sap/ushell/appRuntime/ui5/renderers/fiori2/RendererExtensions.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/AppConfiguration.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/AppState.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/Bookmark.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/BookmarkV2.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/CommonDataModel.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/Container.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/CrossApplicationNavigation.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/Extension/Item.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/Extension.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/FrameBoundExtension.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/LaunchPage.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/MessageBroker.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/NavTargetResolution.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/NavTargetResolutionInternal.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/Navigation.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/ReferenceResolver.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/ShellNavigation.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/ShellNavigationInternal.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/ShellUIService.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/UserInfo.js +1 -1
- package/src/main/js/sap/ushell/appRuntime/ui5/services/adapters/Ui5ComponentLoaderAdapter.js +1 -1
- package/src/main/js/sap/ushell/bootstrap/_SchedulingAgent/logger.js +1 -1
- package/src/main/js/sap/ushell/bootstrap/_SchedulingAgent/state.js +1 -1
- package/src/main/js/sap/ushell/bootstrap/common/common.configure.ui5datetimeformat.js +1 -1
- package/src/main/js/sap/ushell/bootstrap/common/common.create.configcontract.core.js +2 -1
- package/src/main/js/sap/ushell/bootstrap/sandbox2.js +3 -3
- package/src/main/js/sap/ushell/components/CatalogsManager.js +4 -1
- package/src/main/js/sap/ushell/components/HomepageManager.js +1 -0
- package/src/main/js/sap/ushell/components/_HeaderManager/ShellHeader.controller.js +1 -0
- package/src/main/js/sap/ushell/components/appfinder/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/AppLifeCycle.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/application/Application.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/application/BlueBoxHandler.js +2 -2
- package/src/main/js/sap/ushell/components/applicationIntegration/application/BlueBoxesCache.js +37 -7
- package/src/main/js/sap/ushell/components/applicationIntegration/application/PostMessageAPI.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/configuration/AppMeta.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/elements/model.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/relatedServices/RelatedServices.js +1 -1
- package/src/main/js/sap/ushell/components/applicationIntegration/relatedShellElements/RelatedShellElements.js +1 -1
- package/src/main/js/sap/ushell/components/container/ApplicationContainer.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinder/Component.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinder/controller/AppSearch.controller.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinder/controller/ContentFinderDialog.controller.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinder/controller/WidgetGallery.controller.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinder/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/contentFinderStandalone/Component.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinderStandalone/controller/ContentFinderStandalone.controller.js +1 -1
- package/src/main/js/sap/ushell/components/contentFinderStandalone/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/contentFinderStandalone/manifestAppSearch.json +1 -1
- package/src/main/js/sap/ushell/components/factsheet/Component.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/ActionMode.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/DashboardContent.view.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/DashboardGroupsBox.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/DashboardUIActions.js +1 -1
- package/src/main/js/sap/ushell/components/homepage/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/pages/ActionMode.js +1 -1
- package/src/main/js/sap/ushell/components/pages/Component.js +1 -1
- package/src/main/js/sap/ushell/components/pages/MyHomeImport.js +1 -1
- package/src/main/js/sap/ushell/components/pages/controller/PageRuntime.controller.js +2 -1
- package/src/main/js/sap/ushell/components/pages/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/runtimeSwitcher/controller/RuntimeSwitcher.controller.js +11 -3
- package/src/main/js/sap/ushell/components/runtimeSwitcher/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/shell/MenuBar/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/shell/NavigationBarMenu/controller/NavigationBarMenu.controller.js +1 -1
- package/src/main/js/sap/ushell/components/shell/NavigationBarMenu/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/shell/Notifications/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/Notifications/Notifications.controller.js +1 -2
- package/src/main/js/sap/ushell/components/shell/ProductSwitch/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/Search/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/SearchProviders/FrequentActivityProvider.js +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/SearchProviders/RecentSearchProvider.js +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/SearchProviders/SearchProvider.js +1 -1
- package/src/main/js/sap/ushell/components/shell/SearchCEP/SearchProviders/SearchServiceProvider.js +1 -1
- package/src/main/js/sap/ushell/components/shell/Settings/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/Settings/UserSettings.controller.js +10 -0
- package/src/main/js/sap/ushell/components/shell/Settings/userLanguageRegion/LanguageRegionSelector.controller.js +1 -0
- package/src/main/js/sap/ushell/components/shell/UserActionsMenu/Component.js +1 -1
- package/src/main/js/sap/ushell/components/shell/UserImage/Component.js +1 -1
- package/src/main/js/sap/ushell/components/tiles/cdm/applauncherdynamic/Component.js +3 -0
- package/src/main/js/sap/ushell/components/visualizationOrganizer/Component.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/Component.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controller/WorkPageBuilder.accessibility.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controller/WorkPageBuilder.controller.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPage.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageButton.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageCell.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageColumn.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageColumnResizer.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/controls/WorkPageRow.js +1 -1
- package/src/main/js/sap/ushell/components/workPageBuilder/manifest.json +1 -1
- package/src/main/js/sap/ushell/components/workPageRuntime/Component.js +1 -1
- package/src/main/js/sap/ushell/components/workPageRuntime/controller/WorkPageRuntime.controller.js +1 -1
- package/src/main/js/sap/ushell/components/workPageRuntime/manifest.json +1 -1
- package/src/main/js/sap/ushell/designtime/ApplicationContainer.designtime.js +1 -1
- package/src/main/js/sap/ushell/library.js +1 -1
- package/src/main/js/sap/ushell/navigationMode.js +1 -1
- package/src/main/js/sap/ushell/performance/ShellAnalytics.js +1 -1
- package/src/main/js/sap/ushell/performance/StatisticalRecord.js +1 -1
- package/src/main/js/sap/ushell/plugins/appwarmup/Component.js +1 -1
- package/src/main/js/sap/ushell/renderer/History.js +1 -2
- package/src/main/js/sap/ushell/renderer/Renderer.js +2 -2
- package/src/main/js/sap/ushell/renderer/Shell.controller.js +1 -1
- package/src/main/js/sap/ushell/renderer/resources/resources_ar.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_bg.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_ca.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_cnr.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_cs.properties +3 -3
- package/src/main/js/sap/ushell/renderer/resources/resources_cy.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_da.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_de.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_el.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_en.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_en_GB.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_en_US_saprigi.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_es.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_es_MX.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_et.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_fi.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_fr.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_fr_CA.properties +37 -37
- package/src/main/js/sap/ushell/renderer/resources/resources_hi.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_hr.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_hu.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_id.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_it.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_iw.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_ja.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_kk.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_ko.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_lt.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_lv.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_mk.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_ms.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_nl.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_no.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_pl.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_pt.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_pt_PT.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_ro.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_ru.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_sh.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_sk.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_sl.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_sr.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_sv.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_th.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_tr.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_uk.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_vi.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_zh_CN.properties +4 -4
- package/src/main/js/sap/ushell/renderer/resources/resources_zh_TW.properties +4 -4
- package/src/main/js/sap/ushell/renderer/search/searchComponent/manifest.json +1 -1
- package/src/main/js/sap/ushell/services/AppConfiguration.js +13 -11
- package/src/main/js/sap/ushell/services/AppLifeCycle.js +1 -1
- package/src/main/js/sap/ushell/services/AppState.js +1 -1
- package/src/main/js/sap/ushell/services/Bookmark.js +1 -1
- package/src/main/js/sap/ushell/services/BookmarkV2.js +1 -1
- package/src/main/js/sap/ushell/services/ClientSideTargetResolution.js +625 -750
- package/src/main/js/sap/ushell/services/CommonDataModel.js +21 -14
- package/src/main/js/sap/ushell/services/Configuration.js +1 -1
- package/src/main/js/sap/ushell/services/ConfigurationDefaults.js +1 -1
- package/src/main/js/sap/ushell/services/ContentExtensionAdapterFactory.js +1 -1
- package/src/main/js/sap/ushell/services/CrossApplicationNavigation.js +14 -3
- package/src/main/js/sap/ushell/services/DarkModeSupport.js +1 -1
- package/src/main/js/sap/ushell/services/Extension/Item.js +1 -1
- package/src/main/js/sap/ushell/services/Extension.js +1 -1
- package/src/main/js/sap/ushell/services/FlpLaunchPage.js +1 -1
- package/src/main/js/sap/ushell/services/FrameBoundExtension/FloatingContainer.js +1 -1
- package/src/main/js/sap/ushell/services/FrameBoundExtension/Footer.js +1 -1
- package/src/main/js/sap/ushell/services/FrameBoundExtension/Item.js +1 -1
- package/src/main/js/sap/ushell/services/FrameBoundExtension/SidePane.js +1 -1
- package/src/main/js/sap/ushell/services/FrameBoundExtension/ToolArea.js +1 -1
- package/src/main/js/sap/ushell/services/FrameBoundExtension.js +1 -1
- package/src/main/js/sap/ushell/services/LaunchPage.js +1 -1
- package/src/main/js/sap/ushell/services/Menu.js +1 -1
- package/src/main/js/sap/ushell/services/Message.js +1 -1
- package/src/main/js/sap/ushell/services/MessageBroker.js +1 -1
- package/src/main/js/sap/ushell/services/MessageInternal.js +1 -1
- package/src/main/js/sap/ushell/services/Navigation/compatibility.js +1 -1
- package/src/main/js/sap/ushell/services/Navigation/utils.js +1 -1
- package/src/main/js/sap/ushell/services/Navigation.js +3 -3
- package/src/main/js/sap/ushell/services/NavigationDataProvider.js +1 -1
- package/src/main/js/sap/ushell/services/PageBuilding.js +1 -1
- package/src/main/js/sap/ushell/services/PagePersistence.js +1 -1
- package/src/main/js/sap/ushell/services/PageReferencing.js +1 -1
- package/src/main/js/sap/ushell/services/Pages.js +1 -1
- package/src/main/js/sap/ushell/services/Personalization.js +1 -1
- package/src/main/js/sap/ushell/services/PersonalizationV2.js +1 -1
- package/src/main/js/sap/ushell/services/PluginManager.js +1 -1
- package/src/main/js/sap/ushell/services/ReferenceResolver.js +223 -229
- package/src/main/js/sap/ushell/services/Search.js +1 -1
- package/src/main/js/sap/ushell/services/SearchCEP.js +1 -1
- package/src/main/js/sap/ushell/services/SearchableContent.js +1 -1
- package/src/main/js/sap/ushell/services/ShellNavigation.js +1 -1
- package/src/main/js/sap/ushell/services/SmartNavigation.js +1 -1
- package/src/main/js/sap/ushell/services/SpaceContent.js +1 -1
- package/src/main/js/sap/ushell/services/UITracer.js +1 -1
- package/src/main/js/sap/ushell/services/URLShortening.js +1 -1
- package/src/main/js/sap/ushell/services/URLTemplate.js +1 -1
- package/src/main/js/sap/ushell/services/Ui5ComponentLoader.js +1 -1
- package/src/main/js/sap/ushell/services/UserDefaultParameterPersistence.js +87 -78
- package/src/main/js/sap/ushell/services/UserDefaultParameters.js +225 -271
- package/src/main/js/sap/ushell/services/UserInfo.js +1 -1
- package/src/main/js/sap/ushell/services/UserRecents.js +1 -1
- package/src/main/js/sap/ushell/services/VisualizationDataProvider.js +1 -1
- package/src/main/js/sap/ushell/services/VisualizationInstantiation.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/Formatter.js +10 -10
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/InboundIndex.js +9 -6
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/InboundProvider.js +16 -25
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/ParameterMapping.js +3 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/PrelaunchOperations.js +15 -21
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/Search.js +52 -45
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/StagedLogger.js +3 -5
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/SystemContext.js +5 -2
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/Utils.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/VirtualInbounds.js +1 -1
- package/src/main/js/sap/ushell/services/_ClientSideTargetResolution/XAppStateProcessing.js +63 -80
- package/src/main/js/sap/ushell/services/_CommonDataModel/SiteConverter.js +1 -1
- package/src/main/js/sap/ushell/services/_CommonDataModel/vizTypeDefaults/VizTypeDefaults.js +1 -1
- package/src/main/js/sap/ushell/services/_ContentExtensionAdapterFactory/ContentExtensionAdapterConfig.js +1 -1
- package/src/main/js/sap/ushell/services/_ContentExtensionAdapterFactory/FeaturedGroupConfig.js +1 -1
- package/src/main/js/sap/ushell/services/_CrossApplicationNavigation/utils.js +1 -1
- package/src/main/js/sap/ushell/services/_MessageBroker/MessageBrokerEngine.js +1 -1
- package/src/main/js/sap/ushell/services/_PageReferencing/PageReferencer.js +1 -1
- package/src/main/js/sap/ushell/services/_PluginManager/Extensions.js +1 -1
- package/src/main/js/sap/ushell/services/_PluginManager/HeaderExtensions.js +1 -1
- package/src/main/js/sap/ushell/services/_PluginManager/MenuExtensions.js +1 -1
- package/src/main/js/sap/ushell/services/_Ui5ComponentLoader/utils.js +1 -1
- package/src/main/js/sap/ushell/support/plugins/flpConfig/FlpConfigurationPlugin.js +1 -1
- package/src/main/js/sap/ushell/themes/sap_horizon/Tile.less +2 -6
- package/src/main/js/sap/ushell/ui/cards/RecentActivitiesExtension.js +1 -1
- package/src/main/js/sap/ushell/ui/footerbar/SendAsEmailButton.js +2 -2
- package/src/main/js/sap/ushell/ui/launchpad/ExtendedChangeDetection.js +1 -1
- package/src/main/js/sap/ushell/ui/launchpad/Section.js +3 -6
- package/src/main/js/sap/ushell/ui/launchpad/section/CompactArea.js +1 -1
- package/src/main/js/sap/ushell/ui/shell/ShellHeadItem.js +3 -8
- package/src/main/js/sap/ushell/ui/shell/ToolAreaItem.js +1 -2
- package/src/main/js/sap/ushell/ui/utils.js +1 -1
- package/src/main/js/sap/ushell/ui5service/ShellUIService.js +1 -1
- package/src/main/js/sap/ushell/ui5service/UserStatus.js +1 -1
- package/src/main/js/sap/ushell/utils/UrlShortening.js +1 -1
- package/src/main/js/sap/ushell/utils/WindowUtils.js +17 -0
- package/src/main/js/sap/ushell/utils/tilecard/TileCard.js +305 -305
- package/src/main/js/sap/ushell/utils/workpage/WorkPageHost.js +1 -1
- package/src/main/js/sap/ushell/utils/workpage/WorkPageService.js +22 -5
- package/src/main/js/sap/ushell/utils/workpage/WorkPageVizInstantiation.js +7 -6
- package/src/test/js/sap/ushell/bootstrap/sandbox.js +1 -1
- package/ui5.yaml +1 -1
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
* In the future, the custom resolver mechanism should be probably moved towards modifying (or only adding to the list of Inbounds),
|
|
30
30
|
* this way a single data source has to be altered to support consistently getLinks, isIntentSupported.
|
|
31
31
|
*
|
|
32
|
-
* @version 1.
|
|
32
|
+
* @version 1.126.1
|
|
33
33
|
*/
|
|
34
34
|
sap.ui.define([
|
|
35
35
|
"sap/base/Log",
|
|
@@ -74,7 +74,7 @@ sap.ui.define([
|
|
|
74
74
|
_VirtualInbounds,
|
|
75
75
|
_XAppStateProcessing,
|
|
76
76
|
TechnicalParameters,
|
|
77
|
-
|
|
77
|
+
ushellUtils,
|
|
78
78
|
UrlParsing,
|
|
79
79
|
Container
|
|
80
80
|
) {
|
|
@@ -230,24 +230,22 @@ sap.ui.define([
|
|
|
230
230
|
* @since 1.34.0
|
|
231
231
|
*/
|
|
232
232
|
ClientSideTargetResolution.prototype.resolveHashFragment = function (sHashFragment) {
|
|
233
|
-
var that = this;
|
|
234
233
|
var oDeferred = new jQuery.Deferred();
|
|
235
234
|
// NOTE: adapter may not implement fallback function
|
|
236
235
|
var fnBoundFallback = this._oAdapter.resolveHashFragmentFallback && this._oAdapter.resolveHashFragmentFallback.bind(this._oAdapter);
|
|
237
236
|
var aSegments = this._extractInboundFilter(sHashFragment);
|
|
238
237
|
|
|
239
|
-
this._oInboundProvider.getInbounds(aSegments)
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
);
|
|
238
|
+
this._oInboundProvider.getInbounds(aSegments)
|
|
239
|
+
.then((oInboundIndex) => {
|
|
240
|
+
return this._resolveHashFragment(sHashFragment, fnBoundFallback, oInboundIndex);
|
|
241
|
+
})
|
|
242
|
+
.then((oResolvedHashFragment) => {
|
|
243
|
+
oDeferred.resolve(oResolvedHashFragment);
|
|
244
|
+
})
|
|
245
|
+
.catch((oError) => {
|
|
246
|
+
oDeferred.reject(oError);
|
|
247
|
+
});
|
|
248
|
+
|
|
251
249
|
return oDeferred.promise();
|
|
252
250
|
};
|
|
253
251
|
|
|
@@ -261,22 +259,22 @@ sap.ui.define([
|
|
|
261
259
|
* @since 1.38.0
|
|
262
260
|
*/
|
|
263
261
|
ClientSideTargetResolution.prototype.resolveTileIntent = function (sHashFragment) {
|
|
264
|
-
var that = this;
|
|
265
262
|
var oDeferred = new jQuery.Deferred();
|
|
266
263
|
|
|
267
264
|
// NOTE: adapter may not implement fallback function
|
|
268
265
|
var aSegments = this._extractInboundFilter(sHashFragment);
|
|
269
266
|
|
|
270
|
-
this._oInboundProvider.getInbounds(aSegments)
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
267
|
+
this._oInboundProvider.getInbounds(aSegments)
|
|
268
|
+
.then((oInboundIndex) => {
|
|
269
|
+
return this._resolveTileIntent(sHashFragment, undefined, oInboundIndex);
|
|
270
|
+
})
|
|
271
|
+
.then((oResolvedIntent) => {
|
|
272
|
+
oDeferred.resolve(oResolvedIntent);
|
|
273
|
+
})
|
|
274
|
+
.catch((oError) => {
|
|
275
|
+
oDeferred.reject(oError);
|
|
276
|
+
});
|
|
277
|
+
|
|
280
278
|
return oDeferred.promise();
|
|
281
279
|
};
|
|
282
280
|
|
|
@@ -297,15 +295,17 @@ sap.ui.define([
|
|
|
297
295
|
);
|
|
298
296
|
|
|
299
297
|
this._resolveTileIntent(sHashFragment, undefined /* fnBoundFallback */, oInboundIndex)
|
|
300
|
-
.
|
|
301
|
-
|
|
298
|
+
.then((oResolvedTileIntent) => {
|
|
299
|
+
oDeferred.resolve(oResolvedTileIntent);
|
|
300
|
+
})
|
|
301
|
+
.catch((oError) => {
|
|
302
|
+
oDeferred.reject(oError);
|
|
303
|
+
});
|
|
302
304
|
|
|
303
305
|
return oDeferred.promise();
|
|
304
306
|
};
|
|
305
307
|
|
|
306
|
-
ClientSideTargetResolution.prototype._resolveHashFragment = function (sHashFragment, fnBoundFallback, oInboundIndex) {
|
|
307
|
-
var that = this;
|
|
308
|
-
var oDeferred = new jQuery.Deferred();
|
|
308
|
+
ClientSideTargetResolution.prototype._resolveHashFragment = async function (sHashFragment, fnBoundFallback, oInboundIndex) {
|
|
309
309
|
var sFixedHashFragment = sHashFragment.indexOf("#") === 0 ? sHashFragment : "#" + sHashFragment;
|
|
310
310
|
var oShellHash = UrlParsing.parseShellHash(sFixedHashFragment);
|
|
311
311
|
|
|
@@ -313,58 +313,44 @@ sap.ui.define([
|
|
|
313
313
|
Log.error("Could not parse shell hash '" + sHashFragment + "'",
|
|
314
314
|
"please specify a valid shell hash",
|
|
315
315
|
"sap.ushell.services.ClientSideTargetResolution");
|
|
316
|
-
|
|
316
|
+
throw new Error(`Could not parse shell hash '${sHashFragment}'please specify a valid shell hash`);
|
|
317
317
|
}
|
|
318
318
|
|
|
319
|
-
oShellHash.formFactor =
|
|
319
|
+
oShellHash.formFactor = ushellUtils.getFormFactor();
|
|
320
320
|
|
|
321
|
-
this._getMatchingInbounds(oShellHash, oInboundIndex, { bExcludeTileInbounds: true })
|
|
322
|
-
.fail(function (sError) {
|
|
323
|
-
Log.error("Could not resolve " + sHashFragment,
|
|
324
|
-
"_getMatchingInbounds promise rejected with: " + sError,
|
|
325
|
-
"sap.ushell.services.ClientSideTargetResolution");
|
|
326
|
-
oDeferred.reject(sError);
|
|
327
|
-
})
|
|
328
|
-
.done(function (aMatchingTargets) {
|
|
329
|
-
var oMatchingTarget;
|
|
330
|
-
|
|
331
|
-
if (aMatchingTargets.length === 0) {
|
|
332
|
-
Log.warning(
|
|
333
|
-
"Could not resolve " + sHashFragment,
|
|
334
|
-
"rejecting promise",
|
|
335
|
-
"sap.ushell.services.ClientSideTargetResolution"
|
|
336
|
-
);
|
|
337
|
-
oDeferred.reject("Could not resolve navigation target");
|
|
338
|
-
return;
|
|
339
|
-
}
|
|
321
|
+
let aMatchingTargets = await this._getMatchingInbounds(oShellHash, oInboundIndex, { bExcludeTileInbounds: true });
|
|
340
322
|
|
|
341
|
-
|
|
323
|
+
if (aMatchingTargets.length === 0) {
|
|
324
|
+
Log.warning(
|
|
325
|
+
"Could not resolve " + sHashFragment,
|
|
326
|
+
"rejecting promise",
|
|
327
|
+
"sap.ushell.services.ClientSideTargetResolution"
|
|
328
|
+
);
|
|
329
|
+
throw new Error(`Could not resolve ${sHashFragment}`);
|
|
330
|
+
}
|
|
342
331
|
|
|
343
|
-
|
|
332
|
+
aMatchingTargets = this._applySapNavigationScopeFilter(aMatchingTargets, oShellHash);
|
|
344
333
|
|
|
345
|
-
|
|
346
|
-
// replacer for JSON.stringify to show undefined values
|
|
347
|
-
var fnUndefinedReplacer = function (sKey, vVal) {
|
|
348
|
-
return (this[sKey] === undefined) ? "<undefined>" : vVal;
|
|
349
|
-
};
|
|
350
|
-
var fnReplacer = function (key, value) {
|
|
351
|
-
return (key === "_original") ? undefined : fnUndefinedReplacer.call(this, key, value);
|
|
352
|
-
};
|
|
353
|
-
var sMatchedTarget = JSON.stringify(oMatchingTarget, fnReplacer, " ");
|
|
334
|
+
const oMatchingTarget = aMatchingTargets[0];
|
|
354
335
|
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
336
|
+
if (Log.getLevel() >= Log.Level.DEBUG) {
|
|
337
|
+
// replacer for JSON.stringify to show undefined values
|
|
338
|
+
var fnUndefinedReplacer = function (sKey, vVal) {
|
|
339
|
+
return (this[sKey] === undefined) ? "<undefined>" : vVal;
|
|
340
|
+
};
|
|
341
|
+
var fnReplacer = function (key, value) {
|
|
342
|
+
return (key === "_original") ? undefined : fnUndefinedReplacer.call(this, key, value);
|
|
343
|
+
};
|
|
344
|
+
var sMatchedTarget = JSON.stringify(oMatchingTarget, fnReplacer, " ");
|
|
361
345
|
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
346
|
+
Log.debug(
|
|
347
|
+
"The following target will now be resolved",
|
|
348
|
+
sMatchedTarget,
|
|
349
|
+
"sap.ushell.services.ClientSideTargetResolution"
|
|
350
|
+
);
|
|
351
|
+
}
|
|
366
352
|
|
|
367
|
-
return
|
|
353
|
+
return this._resolveSingleMatchingTarget(oMatchingTarget, fnBoundFallback, sFixedHashFragment);
|
|
368
354
|
};
|
|
369
355
|
|
|
370
356
|
/**
|
|
@@ -394,9 +380,7 @@ sap.ui.define([
|
|
|
394
380
|
return aFilteredResults.length > 0 ? aFilteredResults : aMatchResults;
|
|
395
381
|
};
|
|
396
382
|
|
|
397
|
-
ClientSideTargetResolution.prototype._resolveSingleMatchingTarget = function (oMatchingTarget, fnBoundFallback, sFixedHashFragment) {
|
|
398
|
-
var that = this;
|
|
399
|
-
var oDeferred = new jQuery.Deferred();
|
|
383
|
+
ClientSideTargetResolution.prototype._resolveSingleMatchingTarget = async function (oMatchingTarget, fnBoundFallback, sFixedHashFragment) {
|
|
400
384
|
var oIntent = UrlParsing.parseShellHash(sFixedHashFragment);
|
|
401
385
|
var sIntent = [oIntent.semanticObject, oIntent.action].join("-");
|
|
402
386
|
var sApplicationType = (oMatchingTarget.inbound.resolutionResult || {}).applicationType;
|
|
@@ -409,86 +393,77 @@ sap.ui.define([
|
|
|
409
393
|
var bHasUrlTemplate = !!oMatchingTarget.inbound.templateContext;
|
|
410
394
|
var fnEasyAccessMenuResolver = ApplicationType.getEasyAccessMenuResolver(sIntent, sApplicationType);
|
|
411
395
|
if (fnEasyAccessMenuResolver && !bHasUrlTemplate) {
|
|
412
|
-
fnEasyAccessMenuResolver(oIntent, oMatchingTarget, fnExternalSystemAliasResolver, ApplicationType.WDA.enableWdaCompatibilityMode)
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
},
|
|
424
|
-
function (sError) {
|
|
425
|
-
oDeferred.reject(sError);
|
|
426
|
-
}
|
|
427
|
-
);
|
|
428
|
-
return oDeferred.promise();
|
|
396
|
+
const oResolutionResult = await fnEasyAccessMenuResolver(oIntent, oMatchingTarget, fnExternalSystemAliasResolver, ApplicationType.WDA.enableWdaCompatibilityMode);
|
|
397
|
+
|
|
398
|
+
const oNavModeProperties = NavigationMode.getNavigationMode(
|
|
399
|
+
oResolutionResult,
|
|
400
|
+
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-navmode"] || [])[0],
|
|
401
|
+
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-next-navmode"] || [])[0]
|
|
402
|
+
);
|
|
403
|
+
ushellUtils.shallowMergeObject(oResolutionResult, oNavModeProperties);
|
|
404
|
+
oResolutionResult.inboundPermanentKey = oMatchingTarget.inbound.permanentKey || oMatchingTarget.inbound.id;
|
|
405
|
+
|
|
406
|
+
return oResolutionResult;
|
|
429
407
|
}
|
|
430
408
|
|
|
431
409
|
var oReservedParameters = this._getReservedParameters(oMatchingTarget);
|
|
432
410
|
|
|
433
411
|
// rename Parameters
|
|
434
412
|
_ParameterMapping.mapParameterNamesAndRemoveObjects(oMatchingTarget);
|
|
435
|
-
Container.getServiceAsync("AppState").then(function (AppStateService) {
|
|
436
|
-
_XAppStateProcessing.mixAppStateIntoResolutionResultAndRename(oMatchingTarget, AppStateService)
|
|
437
|
-
.done(function (oMatchingTarget) {
|
|
438
|
-
var fnResultProcessor = function () {
|
|
439
|
-
return that._constructFallbackResolutionResult(oMatchingTarget, fnBoundFallback, sFixedHashFragment);
|
|
440
|
-
};
|
|
441
|
-
if (ApplicationType[sApplicationType]) {
|
|
442
|
-
fnResultProcessor = ApplicationType[sApplicationType].generateResolutionResult;
|
|
443
|
-
}
|
|
444
413
|
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
delete oMatchingTarget.mappedIntentParamsPlusSimpleDefaults["sap-tag"];
|
|
448
|
-
oMatchingTarget.mappedDefaultedParamNames = oMatchingTarget.mappedDefaultedParamNames.filter(function (sParameterName) {
|
|
449
|
-
return sParameterName !== "sap-tag";
|
|
450
|
-
});
|
|
451
|
-
|
|
452
|
-
var sBaseUrl = ObjectPath.get("inbound.resolutionResult.url", oMatchingTarget);
|
|
453
|
-
|
|
454
|
-
_PrelaunchOperations.executePrelaunchOperations(oMatchingTarget, oReservedParameters["sap-prelaunch-operations"])
|
|
455
|
-
.then(function () {
|
|
456
|
-
return fnResultProcessor(oMatchingTarget, sBaseUrl, fnExternalSystemAliasResolver);
|
|
457
|
-
})
|
|
458
|
-
.then(function (oResolutionResult) {
|
|
459
|
-
var oNavModeProperties = NavigationMode.getNavigationMode(
|
|
460
|
-
oResolutionResult,
|
|
461
|
-
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-navmode"] || [])[0],
|
|
462
|
-
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-next-navmode"] || [])[0]
|
|
463
|
-
);
|
|
464
|
-
UshellUtils.shallowMergeObject(oResolutionResult, oNavModeProperties);
|
|
414
|
+
const AppState = await Container.getServiceAsync("AppState");
|
|
415
|
+
oMatchingTarget = await _XAppStateProcessing.mixAppStateIntoResolutionResultAndRename(oMatchingTarget, AppState);
|
|
465
416
|
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
"sap.ushell.services.ClientSideTargetResolution"
|
|
472
|
-
);
|
|
473
|
-
UshellUtils.shallowMergeObject(oMatchingTarget.resolutionResult, oResolutionResult);
|
|
474
|
-
oDeferred.resolve(oMatchingTarget.resolutionResult);
|
|
475
|
-
}, function (vMessage) {
|
|
476
|
-
if (typeof vMessage === "string" && vMessage.indexOf("fallback:") >= 0) {
|
|
477
|
-
that._constructFallbackResolutionResult.call(this, oMatchingTarget, fnBoundFallback, sFixedHashFragment)
|
|
478
|
-
.then(
|
|
479
|
-
function (oResolutionResult) {
|
|
480
|
-
UshellUtils.shallowMergeObject(oMatchingTarget.resolutionResult, oResolutionResult);
|
|
481
|
-
oDeferred.resolve(oMatchingTarget.resolutionResult);
|
|
482
|
-
},
|
|
483
|
-
oDeferred.reject.bind(oDeferred)
|
|
484
|
-
);
|
|
485
|
-
} else {
|
|
486
|
-
oDeferred.reject(vMessage);
|
|
487
|
-
}
|
|
488
|
-
});
|
|
489
|
-
});
|
|
417
|
+
// remove parameters that should not make it to the URL (in any case!)
|
|
418
|
+
delete oMatchingTarget.intentParamsPlusAllDefaults["sap-tag"];
|
|
419
|
+
delete oMatchingTarget.mappedIntentParamsPlusSimpleDefaults["sap-tag"];
|
|
420
|
+
oMatchingTarget.mappedDefaultedParamNames = oMatchingTarget.mappedDefaultedParamNames.filter(function (sParameterName) {
|
|
421
|
+
return sParameterName !== "sap-tag";
|
|
490
422
|
});
|
|
491
|
-
|
|
423
|
+
|
|
424
|
+
var sBaseUrl = ObjectPath.get("inbound.resolutionResult.url", oMatchingTarget);
|
|
425
|
+
|
|
426
|
+
await _PrelaunchOperations.executePrelaunchOperations(oMatchingTarget, oReservedParameters["sap-prelaunch-operations"]);
|
|
427
|
+
|
|
428
|
+
try {
|
|
429
|
+
let fnResultProcessor;
|
|
430
|
+
if (ApplicationType[sApplicationType]) {
|
|
431
|
+
fnResultProcessor = ApplicationType[sApplicationType].generateResolutionResult;
|
|
432
|
+
} else {
|
|
433
|
+
fnResultProcessor = () => {
|
|
434
|
+
return this._constructFallbackResolutionResult(oMatchingTarget, fnBoundFallback, sFixedHashFragment);
|
|
435
|
+
};
|
|
436
|
+
}
|
|
437
|
+
const oResolutionResult = await fnResultProcessor(oMatchingTarget, sBaseUrl, fnExternalSystemAliasResolver);
|
|
438
|
+
|
|
439
|
+
const oNavModeProperties = NavigationMode.getNavigationMode(
|
|
440
|
+
oResolutionResult,
|
|
441
|
+
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-navmode"] || [])[0],
|
|
442
|
+
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-next-navmode"] || [])[0]
|
|
443
|
+
);
|
|
444
|
+
ushellUtils.shallowMergeObject(oResolutionResult, oNavModeProperties);
|
|
445
|
+
|
|
446
|
+
oResolutionResult.reservedParameters = oReservedParameters;
|
|
447
|
+
oResolutionResult.inboundPermanentKey = oMatchingTarget.inbound.permanentKey || oMatchingTarget.inbound.id;
|
|
448
|
+
|
|
449
|
+
Log.debug(
|
|
450
|
+
"Intent was resolved to the following target",
|
|
451
|
+
JSON.stringify(oResolutionResult, null, 3),
|
|
452
|
+
"sap.ushell.services.ClientSideTargetResolution"
|
|
453
|
+
);
|
|
454
|
+
ushellUtils.shallowMergeObject(oMatchingTarget.resolutionResult, oResolutionResult);
|
|
455
|
+
|
|
456
|
+
return oMatchingTarget.resolutionResult;
|
|
457
|
+
} catch (vMessage) {
|
|
458
|
+
if (typeof vMessage === "string" && vMessage.indexOf("fallback:") >= 0) {
|
|
459
|
+
const oResolutionResult = await this._constructFallbackResolutionResult(oMatchingTarget, fnBoundFallback, sFixedHashFragment);
|
|
460
|
+
ushellUtils.shallowMergeObject(oMatchingTarget.resolutionResult, oResolutionResult);
|
|
461
|
+
|
|
462
|
+
return oMatchingTarget.resolutionResult;
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
throw vMessage;
|
|
466
|
+
}
|
|
492
467
|
};
|
|
493
468
|
|
|
494
469
|
/**‚
|
|
@@ -542,9 +517,7 @@ sap.ui.define([
|
|
|
542
517
|
return oReservedParameters;
|
|
543
518
|
};
|
|
544
519
|
|
|
545
|
-
ClientSideTargetResolution.prototype._resolveTileIntent = function (sHashFragment, fnBoundFallback, oInboundIndex) {
|
|
546
|
-
var that = this;
|
|
547
|
-
var oDeferred = new jQuery.Deferred();
|
|
520
|
+
ClientSideTargetResolution.prototype._resolveTileIntent = async function (sHashFragment, fnBoundFallback, oInboundIndex) {
|
|
548
521
|
var sFixedHashFragment = sHashFragment.indexOf("#") === 0 ? sHashFragment : "#" + sHashFragment;
|
|
549
522
|
var oShellHash = UrlParsing.parseShellHash(sFixedHashFragment);
|
|
550
523
|
|
|
@@ -554,45 +527,28 @@ sap.ui.define([
|
|
|
554
527
|
"please specify a valid shell hash",
|
|
555
528
|
"sap.ushell.services.ClientSideTargetResolution"
|
|
556
529
|
);
|
|
557
|
-
|
|
530
|
+
throw new Error("Cannot parse shell hash");
|
|
558
531
|
}
|
|
559
532
|
|
|
560
|
-
oShellHash.formFactor =
|
|
533
|
+
oShellHash.formFactor = ushellUtils.getFormFactor();
|
|
561
534
|
|
|
562
|
-
this._getMatchingInbounds(oShellHash, oInboundIndex, { bExcludeTileInbounds: false })
|
|
563
|
-
.fail(function (sError) {
|
|
564
|
-
Log.error(
|
|
565
|
-
"Could not resolve " + sHashFragment,
|
|
566
|
-
"_getMatchingInbounds promise rejected with: " + sError,
|
|
567
|
-
"sap.ushell.services.ClientSideTargetResolution"
|
|
568
|
-
);
|
|
569
|
-
oDeferred.reject(sError);
|
|
570
|
-
})
|
|
571
|
-
.done(function (aMatchingTargets) {
|
|
572
|
-
var oMatchingTarget;
|
|
573
|
-
|
|
574
|
-
if (aMatchingTargets.length === 0) {
|
|
575
|
-
Log.warning(
|
|
576
|
-
"Could not resolve " + sHashFragment,
|
|
577
|
-
"no matching targets were found",
|
|
578
|
-
"sap.ushell.services.ClientSideTargetResolution"
|
|
579
|
-
);
|
|
580
|
-
oDeferred.reject("No matching targets found");
|
|
581
|
-
return;
|
|
582
|
-
}
|
|
535
|
+
const aMatchingTargets = await this._getMatchingInbounds(oShellHash, oInboundIndex, { bExcludeTileInbounds: false });
|
|
583
536
|
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
537
|
+
if (aMatchingTargets.length === 0) {
|
|
538
|
+
Log.warning(
|
|
539
|
+
"Could not resolve " + sHashFragment,
|
|
540
|
+
"no matching targets were found",
|
|
541
|
+
"sap.ushell.services.ClientSideTargetResolution"
|
|
542
|
+
);
|
|
543
|
+
throw new Error("No matching targets found");
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
const oMatchingTarget = aMatchingTargets[0];
|
|
547
|
+
return this._resolveSingleMatchingTileIntent(oMatchingTarget, fnBoundFallback, sFixedHashFragment);
|
|
590
548
|
};
|
|
591
549
|
|
|
592
|
-
ClientSideTargetResolution.prototype._resolveSingleMatchingTileIntent = function (oMatchingTarget, fnBoundFallback, sFixedHashFragment) {
|
|
593
|
-
var oDeferred = new jQuery.Deferred();
|
|
550
|
+
ClientSideTargetResolution.prototype._resolveSingleMatchingTileIntent = async function (oMatchingTarget, fnBoundFallback, sFixedHashFragment) {
|
|
594
551
|
var sApplicationType = (oMatchingTarget.inbound.resolutionResult || {}).applicationType;
|
|
595
|
-
var that = this;
|
|
596
552
|
|
|
597
553
|
var fnExternalSystemAliasResolver;
|
|
598
554
|
if (this._oAdapter.resolveSystemAlias) {
|
|
@@ -601,55 +557,51 @@ sap.ui.define([
|
|
|
601
557
|
|
|
602
558
|
// rename Parameters
|
|
603
559
|
_ParameterMapping.mapParameterNamesAndRemoveObjects(oMatchingTarget);
|
|
604
|
-
Container.getServiceAsync("AppState").then(function (AppStateService) {
|
|
605
|
-
_XAppStateProcessing.mixAppStateIntoResolutionResultAndRename(oMatchingTarget, AppStateService)
|
|
606
|
-
.done(function (oMatchingTarget) {
|
|
607
|
-
var fnResultProcessor = function () {
|
|
608
|
-
return that._constructFallbackResolutionResult(oMatchingTarget, fnBoundFallback, sFixedHashFragment);
|
|
609
|
-
};
|
|
610
|
-
if (ApplicationType[sApplicationType]) {
|
|
611
|
-
fnResultProcessor = ApplicationType[sApplicationType].generateResolutionResult;
|
|
612
|
-
}
|
|
613
560
|
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
delete oMatchingTarget.mappedIntentParamsPlusSimpleDefaults["sap-tag"];
|
|
617
|
-
oMatchingTarget.mappedDefaultedParamNames = oMatchingTarget.mappedDefaultedParamNames.filter(function (sParameterName) {
|
|
618
|
-
return sParameterName !== "sap-tag";
|
|
619
|
-
});
|
|
561
|
+
const AppState = await Container.getServiceAsync("AppState");
|
|
562
|
+
oMatchingTarget = await _XAppStateProcessing.mixAppStateIntoResolutionResultAndRename(oMatchingTarget, AppState);
|
|
620
563
|
|
|
621
|
-
|
|
564
|
+
// remove parameters that should not make it to the URL (in any case!)
|
|
565
|
+
delete oMatchingTarget.intentParamsPlusAllDefaults["sap-tag"];
|
|
566
|
+
delete oMatchingTarget.mappedIntentParamsPlusSimpleDefaults["sap-tag"];
|
|
567
|
+
oMatchingTarget.mappedDefaultedParamNames = oMatchingTarget.mappedDefaultedParamNames.filter(function (sParameterName) {
|
|
568
|
+
return sParameterName !== "sap-tag";
|
|
569
|
+
});
|
|
622
570
|
|
|
623
|
-
|
|
624
|
-
function (oResolutionResult) {
|
|
625
|
-
UshellUtils.shallowMergeObject(oMatchingTarget.resolutionResult, oResolutionResult);
|
|
571
|
+
var sBaseUrl = ObjectPath.get("inbound.resolutionResult.url", oMatchingTarget);
|
|
626
572
|
|
|
627
|
-
|
|
628
|
-
var oTileResolutionResult = fnExtend({}, oMatchingTarget.inbound.tileResolutionResult);
|
|
573
|
+
let fnResultProcessor;
|
|
629
574
|
|
|
630
|
-
|
|
575
|
+
if (ApplicationType[sApplicationType]) {
|
|
576
|
+
fnResultProcessor = ApplicationType[sApplicationType].generateResolutionResult;
|
|
577
|
+
} else {
|
|
578
|
+
fnResultProcessor = () => {
|
|
579
|
+
return this._constructFallbackResolutionResult(oMatchingTarget, fnBoundFallback, sFixedHashFragment);
|
|
580
|
+
};
|
|
581
|
+
}
|
|
631
582
|
|
|
632
|
-
|
|
633
|
-
oResolutionResult,
|
|
634
|
-
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-navmode"] || [])[0],
|
|
635
|
-
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-next-navmode"] || [])[0]
|
|
636
|
-
);
|
|
637
|
-
UshellUtils.shallowMergeObject(oTileResolutionResult, oNavModeProperties);
|
|
583
|
+
const oResolutionResult = await fnResultProcessor(oMatchingTarget, sBaseUrl, fnExternalSystemAliasResolver);
|
|
638
584
|
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
585
|
+
ushellUtils.shallowMergeObject(oMatchingTarget.resolutionResult, oResolutionResult);
|
|
586
|
+
|
|
587
|
+
// beware, shallow copy of central object! only modify root properties!
|
|
588
|
+
var oTileResolutionResult = fnExtend({}, oMatchingTarget.inbound.tileResolutionResult);
|
|
589
|
+
|
|
590
|
+
oTileResolutionResult.startupParameters = oMatchingTarget.effectiveParameters;
|
|
591
|
+
|
|
592
|
+
var oNavModeProperties = NavigationMode.getNavigationMode(
|
|
593
|
+
oResolutionResult,
|
|
594
|
+
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-navmode"] || [])[0],
|
|
595
|
+
(oMatchingTarget.intentParamsPlusAllDefaults["sap-ushell-next-navmode"] || [])[0]
|
|
596
|
+
);
|
|
597
|
+
ushellUtils.shallowMergeObject(oTileResolutionResult, oNavModeProperties);
|
|
598
|
+
|
|
599
|
+
Log.debug(
|
|
600
|
+
"Tile Intent was resolved to the following target",
|
|
601
|
+
JSON.stringify(oTileResolutionResult, null, 3),
|
|
602
|
+
"sap.ushell.services.ClientSideTargetResolution"
|
|
603
|
+
);
|
|
604
|
+
return oTileResolutionResult;
|
|
653
605
|
};
|
|
654
606
|
|
|
655
607
|
/**
|
|
@@ -673,7 +625,7 @@ sap.ui.define([
|
|
|
673
625
|
* <li>inbound that matched the hash fragment</li>
|
|
674
626
|
* <li>oEffectiveParameters, the parameters to be added to the resolved url</li>
|
|
675
627
|
* </ol>
|
|
676
|
-
* This function must return a
|
|
628
|
+
* This function must return a promise that is resolved with an object like:
|
|
677
629
|
* <pre>
|
|
678
630
|
* {
|
|
679
631
|
* applicationType: ...,
|
|
@@ -689,7 +641,7 @@ sap.ui.define([
|
|
|
689
641
|
* <code>fnBoundFallback</code> parameter was undefined or failed to produce a resolution result.
|
|
690
642
|
* @private
|
|
691
643
|
*/
|
|
692
|
-
ClientSideTargetResolution.prototype._constructFallbackResolutionResult = function (oMatchingTarget, fnBoundFallback, sFixedHashFragment) {
|
|
644
|
+
ClientSideTargetResolution.prototype._constructFallbackResolutionResult = async function (oMatchingTarget, fnBoundFallback, sFixedHashFragment) {
|
|
693
645
|
// The current flow is to resolve the result with all *uncompressed* default substituted parameters and alters
|
|
694
646
|
// appState compress the url afterwards if needed (the fallback function takes care of this).
|
|
695
647
|
var oEffectiveParameters = {};
|
|
@@ -712,7 +664,7 @@ sap.ui.define([
|
|
|
712
664
|
"sap.ushell.services.ClientSideTargetResolution"
|
|
713
665
|
);
|
|
714
666
|
|
|
715
|
-
|
|
667
|
+
throw new Error("Cannot resolve hash fragment: no fallback provided.");
|
|
716
668
|
}
|
|
717
669
|
|
|
718
670
|
// fallback
|
|
@@ -723,25 +675,21 @@ sap.ui.define([
|
|
|
723
675
|
);
|
|
724
676
|
|
|
725
677
|
// NOTE: the callback function will be invoked with the effective *unmapped* parameter names! as 3rd argument
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
}
|
|
739
|
-
});
|
|
740
|
-
|
|
741
|
-
fnResolve(oResolutionResult);
|
|
742
|
-
})
|
|
743
|
-
.fail(fnReject.bind(null));
|
|
678
|
+
const oFallbackResolutionResult = await ushellUtils.promisify(fnBoundFallback(
|
|
679
|
+
sFixedHashFragment,
|
|
680
|
+
fnExtend({}, oMatchingTarget.inbound), // don't let adapters to change the inbound member
|
|
681
|
+
oEffectiveParameters
|
|
682
|
+
));
|
|
683
|
+
|
|
684
|
+
var oResolutionResult = {};
|
|
685
|
+
// propagate properties from the resolution result returned by the fallback function
|
|
686
|
+
["applicationType", "additionalInformation", "url", "applicationDependencies", "text"].forEach(function (sPropName) {
|
|
687
|
+
if (oFallbackResolutionResult.hasOwnProperty(sPropName)) {
|
|
688
|
+
oResolutionResult[sPropName] = oFallbackResolutionResult[sPropName];
|
|
689
|
+
}
|
|
744
690
|
});
|
|
691
|
+
|
|
692
|
+
return oResolutionResult;
|
|
745
693
|
};
|
|
746
694
|
|
|
747
695
|
/**
|
|
@@ -758,8 +706,8 @@ sap.ui.define([
|
|
|
758
706
|
ClientSideTargetResolution.prototype.getDistinctSemanticObjects = function () {
|
|
759
707
|
var oDeferred = new jQuery.Deferred();
|
|
760
708
|
|
|
761
|
-
this._oInboundProvider.getInbounds()
|
|
762
|
-
|
|
709
|
+
this._oInboundProvider.getInbounds()
|
|
710
|
+
.then((oInboundIndex) => {
|
|
763
711
|
var oSemanticObjects = {};
|
|
764
712
|
|
|
765
713
|
oInboundIndex.getAllInbounds().forEach(function (oInbound) {
|
|
@@ -769,14 +717,12 @@ sap.ui.define([
|
|
|
769
717
|
}
|
|
770
718
|
});
|
|
771
719
|
|
|
772
|
-
oDeferred.resolve(
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
}
|
|
779
|
-
);
|
|
720
|
+
oDeferred.resolve(Object.keys(oSemanticObjects).sort());
|
|
721
|
+
})
|
|
722
|
+
.catch((oError) => {
|
|
723
|
+
oDeferred.reject(oError);
|
|
724
|
+
});
|
|
725
|
+
|
|
780
726
|
return oDeferred.promise();
|
|
781
727
|
};
|
|
782
728
|
|
|
@@ -825,8 +771,6 @@ sap.ui.define([
|
|
|
825
771
|
* @since 1.38.0
|
|
826
772
|
*/
|
|
827
773
|
ClientSideTargetResolution.prototype.getLinks = function (oArgs) {
|
|
828
|
-
var that = this;
|
|
829
|
-
|
|
830
774
|
var oDeferred = new jQuery.Deferred();
|
|
831
775
|
var oCallArgs;
|
|
832
776
|
|
|
@@ -870,16 +814,17 @@ sap.ui.define([
|
|
|
870
814
|
return oDeferred.reject("invalid arguments for getLinks").promise();
|
|
871
815
|
}
|
|
872
816
|
|
|
873
|
-
this._oInboundProvider.getInbounds()
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
817
|
+
this._oInboundProvider.getInbounds()
|
|
818
|
+
.then((oInboundIndex) => {
|
|
819
|
+
return this._getLinks(oCallArgs, oInboundIndex);
|
|
820
|
+
})
|
|
821
|
+
.then((aLinks) => {
|
|
822
|
+
oDeferred.resolve(aLinks);
|
|
823
|
+
})
|
|
824
|
+
.catch((oError) => {
|
|
825
|
+
oDeferred.reject(oError);
|
|
826
|
+
});
|
|
827
|
+
|
|
883
828
|
return oDeferred.promise();
|
|
884
829
|
};
|
|
885
830
|
|
|
@@ -956,7 +901,7 @@ sap.ui.define([
|
|
|
956
901
|
* }
|
|
957
902
|
* </pre>
|
|
958
903
|
* @param {object} oInboundIndex An inbound index to retrieve the get semantic object links from.
|
|
959
|
-
* @returns {object[]} An array of link objects containing (at least) the following properties:
|
|
904
|
+
* @returns {Promise<object[]>} An array of link objects containing (at least) the following properties:
|
|
960
905
|
* <pre>
|
|
961
906
|
* {
|
|
962
907
|
* intent: "#AnObject-Action?A=B&C=e&C=j",
|
|
@@ -968,7 +913,7 @@ sap.ui.define([
|
|
|
968
913
|
* </pre>
|
|
969
914
|
* @private
|
|
970
915
|
*/
|
|
971
|
-
ClientSideTargetResolution.prototype._getLinks = function (oArgs, oInboundIndex) {
|
|
916
|
+
ClientSideTargetResolution.prototype._getLinks = async function (oArgs, oInboundIndex) {
|
|
972
917
|
var sSemanticObject = oArgs.semanticObject;
|
|
973
918
|
var sAction = oArgs.action;
|
|
974
919
|
var mParameters = oArgs.params;
|
|
@@ -996,12 +941,12 @@ sap.ui.define([
|
|
|
996
941
|
}
|
|
997
942
|
|
|
998
943
|
if (sErrorMessage) {
|
|
999
|
-
|
|
944
|
+
throw new Error(sErrorMessage);
|
|
1000
945
|
}
|
|
1001
946
|
|
|
1002
947
|
if (sSemanticObject === "*") {
|
|
1003
948
|
// shortcut: skip matching inbounds and return directly; it can only match "*" and we don't return it anyway
|
|
1004
|
-
return
|
|
949
|
+
return [];
|
|
1005
950
|
}
|
|
1006
951
|
|
|
1007
952
|
/**
|
|
@@ -1012,172 +957,164 @@ sap.ui.define([
|
|
|
1012
957
|
return sBusinessParams ? "?" + sBusinessParams : "";
|
|
1013
958
|
}
|
|
1014
959
|
|
|
1015
|
-
var
|
|
1016
|
-
var sFormFactor = UshellUtils.getFormFactor();
|
|
960
|
+
var sFormFactor = ushellUtils.getFormFactor();
|
|
1017
961
|
var oAllIntentParams = UrlParsing.parseParameters(fnConstructBusinessParamsString(mParameters));
|
|
1018
962
|
var oShellHash = {
|
|
1019
963
|
semanticObject: (sSemanticObject === "" ? undefined : sSemanticObject),
|
|
1020
964
|
action: sAction, // undefined: match all actions
|
|
1021
|
-
formFactor: (
|
|
1022
|
-
bIgnoreFormFactor
|
|
1023
|
-
? undefined // match any form factor
|
|
1024
|
-
: sFormFactor
|
|
1025
|
-
),
|
|
965
|
+
formFactor: (bIgnoreFormFactor ? undefined : sFormFactor), // undefined: match any form factor
|
|
1026
966
|
params: oAllIntentParams
|
|
1027
967
|
};
|
|
1028
968
|
if (bTreatTechHintAsFilter) {
|
|
1029
969
|
oShellHash.treatTechHintAsFilter = true;
|
|
1030
970
|
}
|
|
1031
971
|
|
|
1032
|
-
this._getMatchingInbounds(oShellHash, oInboundIndex, oInboundsConstraints)
|
|
1033
|
-
.done(function (aMatchingTargets) {
|
|
1034
|
-
var oUniqueIntents = {};
|
|
1035
|
-
var aResults = aMatchingTargets.map(function (oMatchResult) {
|
|
1036
|
-
var sAdjustedSemanticObject = sSemanticObject || oMatchResult.inbound.semanticObject;
|
|
1037
|
-
var sIntent = "#" + sAdjustedSemanticObject + "-" + oMatchResult.inbound.action;
|
|
1038
|
-
var oNeededParameters;
|
|
972
|
+
const aMatchingTargets = await this._getMatchingInbounds(oShellHash, oInboundIndex, oInboundsConstraints);
|
|
1039
973
|
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
974
|
+
var oUniqueIntents = {};
|
|
975
|
+
var aResults = aMatchingTargets
|
|
976
|
+
.map(function (oMatchResult) {
|
|
977
|
+
var sAdjustedSemanticObject = sSemanticObject || oMatchResult.inbound.semanticObject;
|
|
978
|
+
var sIntent = "#" + sAdjustedSemanticObject + "-" + oMatchResult.inbound.action;
|
|
979
|
+
var oNeededParameters;
|
|
1044
980
|
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
981
|
+
// we never return "*" semantic objects from getLinks as they are not parsable links
|
|
982
|
+
if (sAdjustedSemanticObject === "*") {
|
|
983
|
+
return undefined;
|
|
984
|
+
}
|
|
1049
985
|
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
986
|
+
// we never want to return "*" actions from getLinks as they are non parsable links
|
|
987
|
+
if (oMatchResult.inbound.action === "*") {
|
|
988
|
+
return undefined;
|
|
989
|
+
}
|
|
1053
990
|
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
count: 1
|
|
1058
|
-
};
|
|
991
|
+
if (oMatchResult.inbound && oMatchResult.inbound.hasOwnProperty("hideIntentLink") && oMatchResult.inbound.hideIntentLink === true) {
|
|
992
|
+
return undefined;
|
|
993
|
+
}
|
|
1059
994
|
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
}, false);
|
|
1066
|
-
} else {
|
|
1067
|
-
oNeededParameters = oAllIntentParams;
|
|
1068
|
-
}
|
|
995
|
+
if (!oUniqueIntents.hasOwnProperty(sIntent)) {
|
|
996
|
+
oUniqueIntents[sIntent] = {
|
|
997
|
+
matchingInbound: oMatchResult.inbound,
|
|
998
|
+
count: 1
|
|
999
|
+
};
|
|
1069
1000
|
|
|
1070
|
-
|
|
1001
|
+
if (oMatchResult.inbound.signature.additionalParameters === "ignored") {
|
|
1002
|
+
// in the result do not show all intent parameters, but only those mentioned by the inbound
|
|
1003
|
+
oNeededParameters = _Utils.filterObjectKeys(oAllIntentParams, function (sIntentParam) {
|
|
1004
|
+
return (sIntentParam.indexOf("sap-") === 0) || oMatchResult.inbound.signature.parameters.hasOwnProperty(sIntentParam);
|
|
1005
|
+
}, false);
|
|
1006
|
+
} else {
|
|
1007
|
+
oNeededParameters = oAllIntentParams;
|
|
1008
|
+
}
|
|
1071
1009
|
|
|
1072
|
-
|
|
1073
|
-
var bAtLeastOneNonSapParam = Object.keys(oNeededParameters).some(function (sNeededParamName) {
|
|
1074
|
-
return sNeededParamName.indexOf("sap-") !== 0;
|
|
1075
|
-
});
|
|
1076
|
-
if (!bAtLeastOneNonSapParam) {
|
|
1077
|
-
oUniqueIntents[sIntent].hideReason = "getLinks called with 'withAtLeastOneUsedParam = true', but the inbound had no business parameters defined.";
|
|
1078
|
-
return undefined;
|
|
1079
|
-
}
|
|
1080
|
-
}
|
|
1010
|
+
// --- begin of post-match reject reasons
|
|
1081
1011
|
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
);
|
|
1086
|
-
if (!
|
|
1087
|
-
oUniqueIntents[sIntent].hideReason = "
|
|
1012
|
+
if (bWithAtLeastOneUsedParam) {
|
|
1013
|
+
var bAtLeastOneNonSapParam = Object.keys(oNeededParameters).some(function (sNeededParamName) {
|
|
1014
|
+
return sNeededParamName.indexOf("sap-") !== 0;
|
|
1015
|
+
});
|
|
1016
|
+
if (!bAtLeastOneNonSapParam) {
|
|
1017
|
+
oUniqueIntents[sIntent].hideReason = "getLinks called with 'withAtLeastOneUsedParam = true', but the inbound had no business parameters defined.";
|
|
1088
1018
|
return undefined;
|
|
1089
1019
|
}
|
|
1020
|
+
}
|
|
1090
1021
|
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1022
|
+
var bSignatureMeetsParameterOptions = _Utils.inboundSignatureMeetsParameterOptions(
|
|
1023
|
+
oMatchResult.inbound.signature.parameters,
|
|
1024
|
+
oArgs.paramsOptions || []
|
|
1025
|
+
);
|
|
1026
|
+
if (!bSignatureMeetsParameterOptions) {
|
|
1027
|
+
oUniqueIntents[sIntent].hideReason = "inbound signature does not meet the requested parameter filter options";
|
|
1028
|
+
return undefined;
|
|
1029
|
+
}
|
|
1097
1030
|
|
|
1098
|
-
|
|
1099
|
-
oResult.icon = oMatchResult.inbound.icon;
|
|
1100
|
-
}
|
|
1101
|
-
if (oMatchResult.inbound.subTitle) {
|
|
1102
|
-
oResult.subTitle = oMatchResult.inbound.subTitle;
|
|
1103
|
-
}
|
|
1104
|
-
if (oMatchResult.inbound.shortTitle) {
|
|
1105
|
-
oResult.shortTitle = oMatchResult.inbound.shortTitle;
|
|
1106
|
-
}
|
|
1031
|
+
// --- end of post-match reject reasons
|
|
1107
1032
|
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1033
|
+
var oResult = {
|
|
1034
|
+
intent: sIntent + fnConstructBusinessParamsString(oNeededParameters),
|
|
1035
|
+
text: oMatchResult.inbound.title
|
|
1036
|
+
};
|
|
1112
1037
|
|
|
1113
|
-
|
|
1038
|
+
if (oMatchResult.inbound.icon) {
|
|
1039
|
+
oResult.icon = oMatchResult.inbound.icon;
|
|
1040
|
+
}
|
|
1041
|
+
if (oMatchResult.inbound.subTitle) {
|
|
1042
|
+
oResult.subTitle = oMatchResult.inbound.subTitle;
|
|
1043
|
+
}
|
|
1044
|
+
if (oMatchResult.inbound.shortTitle) {
|
|
1045
|
+
oResult.shortTitle = oMatchResult.inbound.shortTitle;
|
|
1114
1046
|
}
|
|
1115
|
-
// for debugging purposes
|
|
1116
|
-
oUniqueIntents[sIntent].count++;
|
|
1117
1047
|
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1048
|
+
var sInboundTag = ObjectPath.get("inbound.signature.parameters.sap-tag.defaultValue.value", oMatchResult);
|
|
1049
|
+
if (sInboundTag) {
|
|
1050
|
+
oResult.tags = [sInboundTag];
|
|
1051
|
+
}
|
|
1122
1052
|
|
|
1123
|
-
|
|
1124
|
-
aResults.sort(function (oGetSoLinksResult1, oGetSoLinksResult2) {
|
|
1125
|
-
return oGetSoLinksResult1[sSortProperty] < oGetSoLinksResult2[sSortProperty] ? -1 : 1;
|
|
1126
|
-
});
|
|
1053
|
+
return oResult;
|
|
1127
1054
|
}
|
|
1055
|
+
// for debugging purposes
|
|
1056
|
+
oUniqueIntents[sIntent].count++;
|
|
1128
1057
|
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
var aHiddenResultLines = [];
|
|
1135
|
-
|
|
1136
|
-
aResults.forEach(function (oResult) {
|
|
1137
|
-
var sIntent = oResult.intent.split("?")[0];
|
|
1138
|
-
|
|
1139
|
-
if (oUniqueIntents[sIntent].hideReason) {
|
|
1140
|
-
aHiddenResultLines.push([
|
|
1141
|
-
"-", sIntent + "(" + oUniqueIntents[sIntent].hideReason + ")\n",
|
|
1142
|
-
" text:", oResult.text + "\n",
|
|
1143
|
-
" full intent:", oResult.intent
|
|
1144
|
-
].join(" "));
|
|
1145
|
-
} else {
|
|
1146
|
-
aResultLines.push([
|
|
1147
|
-
"-", sIntent,
|
|
1148
|
-
oUniqueIntents[sIntent].count > 1
|
|
1149
|
-
? "(" + (oUniqueIntents[sIntent].count - 1) + " others matched)\n"
|
|
1150
|
-
: "\n",
|
|
1151
|
-
"text:", oResult.text + "\n",
|
|
1152
|
-
"full intent:", oResult.intent
|
|
1153
|
-
].join(" "));
|
|
1154
|
-
}
|
|
1155
|
-
});
|
|
1058
|
+
return undefined;
|
|
1059
|
+
})
|
|
1060
|
+
.filter(function (oSemanticObjectLink) {
|
|
1061
|
+
return typeof oSemanticObjectLink === "object";
|
|
1062
|
+
});
|
|
1156
1063
|
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1064
|
+
if (sSortProperty !== "priority") {
|
|
1065
|
+
aResults.sort(function (oGetSoLinksResult1, oGetSoLinksResult2) {
|
|
1066
|
+
return oGetSoLinksResult1[sSortProperty] < oGetSoLinksResult2[sSortProperty] ? -1 : 1;
|
|
1067
|
+
});
|
|
1068
|
+
}
|
|
1069
|
+
|
|
1070
|
+
if (aResults.length === 0) {
|
|
1071
|
+
Log.debug("_getLinks returned no results");
|
|
1072
|
+
} else if (Log.getLevel() >= Log.Level.DEBUG) {
|
|
1073
|
+
if (Log.getLevel() >= Log.Level.TRACE) {
|
|
1074
|
+
var aResultLines = [];
|
|
1075
|
+
var aHiddenResultLines = [];
|
|
1076
|
+
|
|
1077
|
+
aResults.forEach(function (oResult) {
|
|
1078
|
+
var sIntent = oResult.intent.split("?")[0];
|
|
1079
|
+
|
|
1080
|
+
if (oUniqueIntents[sIntent].hideReason) {
|
|
1081
|
+
aHiddenResultLines.push([
|
|
1082
|
+
"-", sIntent + "(" + oUniqueIntents[sIntent].hideReason + ")\n",
|
|
1083
|
+
" text:", oResult.text + "\n",
|
|
1084
|
+
" full intent:", oResult.intent
|
|
1085
|
+
].join(" "));
|
|
1168
1086
|
} else {
|
|
1169
|
-
|
|
1170
|
-
"
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1087
|
+
aResultLines.push([
|
|
1088
|
+
"-", sIntent,
|
|
1089
|
+
oUniqueIntents[sIntent].count > 1
|
|
1090
|
+
? "(" + (oUniqueIntents[sIntent].count - 1) + " others matched)\n"
|
|
1091
|
+
: "\n",
|
|
1092
|
+
"text:", oResult.text + "\n",
|
|
1093
|
+
"full intent:", oResult.intent
|
|
1094
|
+
].join(" "));
|
|
1174
1095
|
}
|
|
1175
|
-
}
|
|
1176
|
-
oDeferred.resolve(aResults);
|
|
1177
|
-
})
|
|
1178
|
-
.fail(oDeferred.reject.bind(oDeferred));
|
|
1096
|
+
});
|
|
1179
1097
|
|
|
1180
|
-
|
|
1098
|
+
Log.debug(
|
|
1099
|
+
"_getLinks filtered to the following unique intents:",
|
|
1100
|
+
"\n" + aResultLines.join("\n"),
|
|
1101
|
+
"sap.ushell.services.ClientSideTargetResolution"
|
|
1102
|
+
);
|
|
1103
|
+
|
|
1104
|
+
Log.debug(
|
|
1105
|
+
"_getLinks would have also returned the following unique intents, but something prevented this:",
|
|
1106
|
+
aHiddenResultLines.join("\n"),
|
|
1107
|
+
"sap.ushell.services.ClientSideTargetResolution"
|
|
1108
|
+
);
|
|
1109
|
+
} else {
|
|
1110
|
+
Log.debug(
|
|
1111
|
+
"_getLinks filtered to unique intents.",
|
|
1112
|
+
"Reporting histogram: \n - " + Object.keys(oUniqueIntents).join("\n - "),
|
|
1113
|
+
"sap.ushell.services.ClientSideTargetResolution"
|
|
1114
|
+
);
|
|
1115
|
+
}
|
|
1116
|
+
}
|
|
1117
|
+
return aResults;
|
|
1181
1118
|
};
|
|
1182
1119
|
|
|
1183
1120
|
/**
|
|
@@ -1208,18 +1145,17 @@ sap.ui.define([
|
|
|
1208
1145
|
* }
|
|
1209
1146
|
* </pre>
|
|
1210
1147
|
* @param {string[]} [oConstraints.tags] Tags to which the queried inbounds should belong to.
|
|
1211
|
-
* @returns {
|
|
1148
|
+
* @returns {Promise<object[]>} A sorted array of matching targets.
|
|
1212
1149
|
* A target is a matching result that in addition has a specific priority with respect to other matching targets.
|
|
1213
1150
|
* @private
|
|
1214
1151
|
* @since 1.32.0
|
|
1215
1152
|
*/
|
|
1216
|
-
ClientSideTargetResolution.prototype._getMatchingInbounds = function (oShellHash, oInboundIndex, oConstraints) {
|
|
1153
|
+
ClientSideTargetResolution.prototype._getMatchingInbounds = async function (oShellHash, oInboundIndex, oConstraints) {
|
|
1217
1154
|
var that = this;
|
|
1218
1155
|
var aTags;
|
|
1219
1156
|
var iLogId;
|
|
1220
1157
|
var bExcludeTileInbounds;
|
|
1221
1158
|
var aPreFilteredInbounds;
|
|
1222
|
-
var oDeferred = new jQuery.Deferred();
|
|
1223
1159
|
|
|
1224
1160
|
if (oConstraints) {
|
|
1225
1161
|
aTags = oConstraints.tags;
|
|
@@ -1268,6 +1204,13 @@ sap.ui.define([
|
|
|
1268
1204
|
};
|
|
1269
1205
|
});
|
|
1270
1206
|
|
|
1207
|
+
// output logs before returning
|
|
1208
|
+
function endLogger () {
|
|
1209
|
+
_StagedLogger.end(() => {
|
|
1210
|
+
return { logId: iLogId };
|
|
1211
|
+
});
|
|
1212
|
+
}
|
|
1213
|
+
|
|
1271
1214
|
var sSemanticObject = oShellHash.semanticObject;
|
|
1272
1215
|
var sAction = oShellHash.action;
|
|
1273
1216
|
this._oShellHash = oShellHash;
|
|
@@ -1292,73 +1235,60 @@ sap.ui.define([
|
|
|
1292
1235
|
}
|
|
1293
1236
|
|
|
1294
1237
|
// initial match
|
|
1295
|
-
_Search
|
|
1296
|
-
.match(oShellHash, aPreFilteredInbounds, {} /* known default */, fnGetContentProviderLookup, Log.getLevel() >= Log.Level.DEBUG)
|
|
1297
|
-
.then(function (oInitialMatchResult) {
|
|
1298
|
-
// resolve References
|
|
1238
|
+
const oInitialMatchResult = await _Search.match(oShellHash, aPreFilteredInbounds, {} /* known default */, fnGetContentProviderLookup, Log.getLevel() >= Log.Level.DEBUG);
|
|
1299
1239
|
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
})
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
var aLines = oInitialMatchResult.matchResults.map(function (oMatchResult) {
|
|
1313
|
-
return _Formatter.formatInbound(oMatchResult.inbound);
|
|
1314
|
-
});
|
|
1315
|
-
return {
|
|
1316
|
-
logId: iLogId,
|
|
1317
|
-
stage: 1,
|
|
1318
|
-
prefix: aLines.length > 0
|
|
1319
|
-
? "\u2705" // green checkmark
|
|
1320
|
-
: "\u2718", // heavy black X
|
|
1321
|
-
lines: aLines.length > 0
|
|
1322
|
-
? aLines
|
|
1323
|
-
: ["No inbound was matched"]
|
|
1324
|
-
};
|
|
1325
|
-
});
|
|
1240
|
+
// ========================= Stage 1 ================================
|
|
1241
|
+
// resolve References
|
|
1242
|
+
_StagedLogger.log(function () {
|
|
1243
|
+
return {
|
|
1244
|
+
logId: iLogId,
|
|
1245
|
+
stage: 1,
|
|
1246
|
+
prefix: "\u2718", // heavy black X
|
|
1247
|
+
lines: Object.keys(oInitialMatchResult.noMatchReasons || {}).map(function (sInbound) {
|
|
1248
|
+
return sInbound + " " + oInitialMatchResult.noMatchReasons[sInbound];
|
|
1249
|
+
})
|
|
1250
|
+
};
|
|
1251
|
+
});
|
|
1326
1252
|
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1253
|
+
_StagedLogger.log(function () {
|
|
1254
|
+
var aLines = oInitialMatchResult.matchResults.map(function (oMatchResult) {
|
|
1255
|
+
return _Formatter.formatInbound(oMatchResult.inbound);
|
|
1256
|
+
});
|
|
1257
|
+
return {
|
|
1258
|
+
logId: iLogId,
|
|
1259
|
+
stage: 1,
|
|
1260
|
+
prefix: aLines.length > 0
|
|
1261
|
+
? "\u2705" // green checkmark
|
|
1262
|
+
: "\u2718", // heavy black X
|
|
1263
|
+
lines: aLines.length > 0
|
|
1264
|
+
? aLines
|
|
1265
|
+
: ["No inbound was matched"]
|
|
1266
|
+
};
|
|
1267
|
+
});
|
|
1335
1268
|
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1269
|
+
var oMissingReferences = {};
|
|
1270
|
+
var bNeedToResolve = false;
|
|
1271
|
+
var aContentProviders = Object.keys(oInitialMatchResult.missingReferences);
|
|
1272
|
+
aContentProviders.forEach(function (sContentProviderId) {
|
|
1273
|
+
var aReferences = Object.keys(oInitialMatchResult.missingReferences[sContentProviderId]);
|
|
1274
|
+
bNeedToResolve = bNeedToResolve || aReferences.length > 0;
|
|
1275
|
+
oMissingReferences[sContentProviderId] = aReferences;
|
|
1276
|
+
});
|
|
1343
1277
|
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
line: "No need to resolve references"
|
|
1352
|
-
};
|
|
1353
|
-
});
|
|
1278
|
+
aContentProviders = aContentProviders.filter(function (sContentProviderId) {
|
|
1279
|
+
if (oMissingReferences[sContentProviderId].length > 0) {
|
|
1280
|
+
return true;
|
|
1281
|
+
}
|
|
1282
|
+
delete oMissingReferences[sContentProviderId];
|
|
1283
|
+
return false;
|
|
1284
|
+
});
|
|
1354
1285
|
|
|
1355
|
-
return new jQuery.Deferred().resolve({
|
|
1356
|
-
matchResults: oInitialMatchResult.matchResults,
|
|
1357
|
-
referencesToInclude: null
|
|
1358
|
-
}).promise();
|
|
1359
|
-
}
|
|
1360
1286
|
|
|
1361
|
-
|
|
1287
|
+
// ========================= Stage 2 ================================
|
|
1288
|
+
// resolve references
|
|
1289
|
+
let oInitialMatchWithReferencesResult;
|
|
1290
|
+
if (bNeedToResolve) {
|
|
1291
|
+
try {
|
|
1362
1292
|
aContentProviders.forEach(function (sContentProviderId) {
|
|
1363
1293
|
_StagedLogger.log(function () {
|
|
1364
1294
|
return {
|
|
@@ -1371,161 +1301,152 @@ sap.ui.define([
|
|
|
1371
1301
|
});
|
|
1372
1302
|
});
|
|
1373
1303
|
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
}.bind(this))
|
|
1392
|
-
.then(function (aResolvedRefs) {
|
|
1393
|
-
var oResult = {
|
|
1394
|
-
matchResults: oInitialMatchResult.matchResults,
|
|
1395
|
-
referencesToInclude: {}
|
|
1396
|
-
};
|
|
1397
|
-
aContentProviders.forEach(function (sContentProviderId, iIndex) {
|
|
1398
|
-
var oResolvedRefs = aResolvedRefs[iIndex];
|
|
1399
|
-
oResult.referencesToInclude[sContentProviderId] = oResolvedRefs;
|
|
1400
|
-
if (Object.keys(oResolvedRefs).length > 0) {
|
|
1401
|
-
_StagedLogger.log(function () {
|
|
1402
|
-
return {
|
|
1403
|
-
logId: iLogId,
|
|
1404
|
-
stage: 2,
|
|
1405
|
-
line: "\u2705 resolved references with contentProviderId = \"" + sContentProviderId + "\" to the following values:",
|
|
1406
|
-
prefix: "\u2022", // bullet point
|
|
1407
|
-
lines: Object.keys(oResolvedRefs).map(function (sRefName) {
|
|
1408
|
-
return sRefName + ": '" + oResolvedRefs[sRefName] + "'";
|
|
1409
|
-
})
|
|
1410
|
-
};
|
|
1411
|
-
});
|
|
1412
|
-
}
|
|
1413
|
-
});
|
|
1414
|
-
oReadyToRematchDeferred.resolve(oResult);
|
|
1415
|
-
})
|
|
1416
|
-
.catch(function (sError) {
|
|
1304
|
+
const ReferenceResolver = await Container.getServiceAsync("ReferenceResolver");
|
|
1305
|
+
|
|
1306
|
+
const aSystemContexts = await Promise.all(aContentProviders.map((sContentProviderId) => {
|
|
1307
|
+
return this.getSystemContext(sContentProviderId);
|
|
1308
|
+
}));
|
|
1309
|
+
const aResolvedRefs = await Promise.all(aContentProviders.map(function (sContentProviderId, iIndex) {
|
|
1310
|
+
return ushellUtils.promisify(ReferenceResolver.resolveReferences(oMissingReferences[sContentProviderId], aSystemContexts[iIndex]));
|
|
1311
|
+
}));
|
|
1312
|
+
|
|
1313
|
+
var oResult = {
|
|
1314
|
+
matchResults: oInitialMatchResult.matchResults,
|
|
1315
|
+
referencesToInclude: {}
|
|
1316
|
+
};
|
|
1317
|
+
aContentProviders.forEach(function (sContentProviderId, iIndex) {
|
|
1318
|
+
var oResolvedRefs = aResolvedRefs[iIndex];
|
|
1319
|
+
oResult.referencesToInclude[sContentProviderId] = oResolvedRefs;
|
|
1320
|
+
if (Object.keys(oResolvedRefs).length > 0) {
|
|
1417
1321
|
_StagedLogger.log(function () {
|
|
1418
1322
|
return {
|
|
1419
1323
|
logId: iLogId,
|
|
1420
1324
|
stage: 2,
|
|
1421
|
-
|
|
1422
|
-
|
|
1325
|
+
line: "\u2705 resolved references with contentProviderId = \"" + sContentProviderId + "\" to the following values:",
|
|
1326
|
+
prefix: "\u2022", // bullet point
|
|
1327
|
+
lines: Object.keys(oResolvedRefs).map(function (sRefName) {
|
|
1328
|
+
return sRefName + ": '" + oResolvedRefs[sRefName] + "'";
|
|
1329
|
+
})
|
|
1423
1330
|
};
|
|
1424
1331
|
});
|
|
1425
|
-
|
|
1426
|
-
// don't continue processing, just exit with an empty result set
|
|
1427
|
-
oDeferred.resolve([]);
|
|
1428
|
-
});
|
|
1429
|
-
return oReadyToRematchDeferred.promise();
|
|
1430
|
-
}.bind(this))
|
|
1431
|
-
.then(function (oInitialMatchWithReferencesResult) {
|
|
1432
|
-
// re-match with resolved references
|
|
1433
|
-
var oReferences = oInitialMatchWithReferencesResult.referencesToInclude;
|
|
1434
|
-
|
|
1435
|
-
if (!oReferences) {
|
|
1436
|
-
_StagedLogger.log(function () {
|
|
1437
|
-
return {
|
|
1438
|
-
logId: iLogId,
|
|
1439
|
-
stage: 3,
|
|
1440
|
-
line: "rematch was skipped (no references to resolve)",
|
|
1441
|
-
prefix: "\u2705" // green checkmark
|
|
1442
|
-
};
|
|
1443
|
-
});
|
|
1444
|
-
// no references, skip re-match
|
|
1445
|
-
return new jQuery.Deferred().resolve(oInitialMatchWithReferencesResult).promise();
|
|
1446
|
-
}
|
|
1447
|
-
|
|
1448
|
-
// rematch using the set of the already matched inbounds
|
|
1449
|
-
var aMatchResults = oInitialMatchWithReferencesResult.matchResults;
|
|
1450
|
-
var aMatchingInbounds = aMatchResults.map(function (oMatchResult) {
|
|
1451
|
-
return oMatchResult.inbound;
|
|
1332
|
+
}
|
|
1452
1333
|
});
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
lines: aMatchResults.map(function (oMatchResult) {
|
|
1463
|
-
return _Formatter.formatInbound(oMatchResult.inbound);
|
|
1464
|
-
}),
|
|
1465
|
-
prefix: "\u2705" // green checkmark
|
|
1466
|
-
};
|
|
1467
|
-
}
|
|
1468
|
-
|
|
1469
|
-
return {
|
|
1470
|
-
logId: iLogId,
|
|
1471
|
-
stage: 3,
|
|
1472
|
-
line: "No inbounds re-matched",
|
|
1473
|
-
prefix: "-"
|
|
1474
|
-
};
|
|
1475
|
-
});
|
|
1476
|
-
|
|
1477
|
-
return oFinalMatchResult;
|
|
1334
|
+
oInitialMatchWithReferencesResult = oResult;
|
|
1335
|
+
} catch (sError) {
|
|
1336
|
+
_StagedLogger.log(function () {
|
|
1337
|
+
return {
|
|
1338
|
+
logId: iLogId,
|
|
1339
|
+
stage: 2,
|
|
1340
|
+
prefix: "\u274c", // red X
|
|
1341
|
+
line: "Failed to resolve references: " + sError
|
|
1342
|
+
};
|
|
1478
1343
|
});
|
|
1479
|
-
})
|
|
1480
|
-
.then(function (oFinalMatchResult) {
|
|
1481
|
-
// sorting
|
|
1482
|
-
|
|
1483
|
-
var aMatchResultsToSort = oFinalMatchResult.matchResults || [];
|
|
1484
|
-
if (aMatchResultsToSort.length <= 1) {
|
|
1485
|
-
_StagedLogger.log(function () {
|
|
1486
|
-
return {
|
|
1487
|
-
logId: iLogId,
|
|
1488
|
-
stage: 4,
|
|
1489
|
-
line: "Nothing to sort"
|
|
1490
|
-
};
|
|
1491
|
-
});
|
|
1492
1344
|
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1345
|
+
// don't continue processing, just exit with an empty result set
|
|
1346
|
+
endLogger();
|
|
1347
|
+
return [];
|
|
1348
|
+
}
|
|
1349
|
+
} else { // no references to resolve
|
|
1350
|
+
_StagedLogger.log(function () {
|
|
1351
|
+
return {
|
|
1352
|
+
logId: iLogId,
|
|
1353
|
+
stage: 2,
|
|
1354
|
+
prefix: "\u2705", // green checkmark
|
|
1355
|
+
line: "No need to resolve references"
|
|
1356
|
+
};
|
|
1357
|
+
});
|
|
1496
1358
|
|
|
1497
|
-
|
|
1359
|
+
oInitialMatchWithReferencesResult = {
|
|
1360
|
+
matchResults: oInitialMatchResult.matchResults,
|
|
1361
|
+
referencesToInclude: null
|
|
1362
|
+
};
|
|
1363
|
+
}
|
|
1498
1364
|
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1365
|
+
// ========================= Stage 3 ================================
|
|
1366
|
+
// re-match with resolved references
|
|
1367
|
+
let oFinalMatchResult;
|
|
1368
|
+
if (oInitialMatchWithReferencesResult.referencesToInclude) {
|
|
1369
|
+
// rematch using the set of the already matched inbounds
|
|
1370
|
+
var aMatchResults = oInitialMatchWithReferencesResult.matchResults;
|
|
1371
|
+
var aMatchingInbounds = aMatchResults.map(function (oMatchResult) {
|
|
1372
|
+
return oMatchResult.inbound;
|
|
1373
|
+
});
|
|
1508
1374
|
|
|
1375
|
+
oFinalMatchResult = await _Search.match(oShellHash, aMatchingInbounds, oInitialMatchWithReferencesResult.referencesToInclude, fnGetContentProviderLookup, 0 /* iDebugLevel */);
|
|
1376
|
+
_StagedLogger.log(function () {
|
|
1377
|
+
var aMatchResults = oFinalMatchResult.matchResults || [];
|
|
1378
|
+
if (aMatchResults.length >= 1) {
|
|
1509
1379
|
return {
|
|
1510
1380
|
logId: iLogId,
|
|
1511
|
-
stage:
|
|
1512
|
-
line: "
|
|
1513
|
-
lines:
|
|
1514
|
-
|
|
1515
|
-
|
|
1381
|
+
stage: 3,
|
|
1382
|
+
line: "The following inbounds re-matched:",
|
|
1383
|
+
lines: aMatchResults.map(function (oMatchResult) {
|
|
1384
|
+
return _Formatter.formatInbound(oMatchResult.inbound);
|
|
1385
|
+
}),
|
|
1386
|
+
prefix: "\u2705" // green checkmark
|
|
1516
1387
|
};
|
|
1517
|
-
}
|
|
1388
|
+
}
|
|
1518
1389
|
|
|
1519
|
-
|
|
1390
|
+
return {
|
|
1391
|
+
logId: iLogId,
|
|
1392
|
+
stage: 3,
|
|
1393
|
+
line: "No inbounds re-matched",
|
|
1394
|
+
prefix: "-"
|
|
1395
|
+
};
|
|
1396
|
+
});
|
|
1397
|
+
} else { // no references, skip re-match
|
|
1398
|
+
_StagedLogger.log(function () {
|
|
1399
|
+
return {
|
|
1400
|
+
logId: iLogId,
|
|
1401
|
+
stage: 3,
|
|
1402
|
+
line: "rematch was skipped (no references to resolve)",
|
|
1403
|
+
prefix: "\u2705" // green checkmark
|
|
1404
|
+
};
|
|
1520
1405
|
});
|
|
1406
|
+
oFinalMatchResult = oInitialMatchWithReferencesResult;
|
|
1407
|
+
}
|
|
1521
1408
|
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1409
|
+
// ========================= Stage 4 ================================
|
|
1410
|
+
// sorting
|
|
1411
|
+
var aMatchResultsToSort = oFinalMatchResult.matchResults || [];
|
|
1412
|
+
if (aMatchResultsToSort.length <= 1) {
|
|
1413
|
+
_StagedLogger.log(function () {
|
|
1414
|
+
return {
|
|
1415
|
+
logId: iLogId,
|
|
1416
|
+
stage: 4,
|
|
1417
|
+
line: "Nothing to sort"
|
|
1418
|
+
};
|
|
1526
1419
|
});
|
|
1527
|
-
|
|
1420
|
+
|
|
1421
|
+
endLogger();
|
|
1422
|
+
return aMatchResultsToSort;
|
|
1423
|
+
}
|
|
1424
|
+
|
|
1425
|
+
var aSortedMatchResults = _Search.sortMatchingResultsDeterministic(oFinalMatchResult.matchResults || []);
|
|
1426
|
+
|
|
1427
|
+
_StagedLogger.log(function () {
|
|
1428
|
+
var aLines = aSortedMatchResults.map(function (oMatchResult) {
|
|
1429
|
+
return _Formatter.formatInbound(oMatchResult.inbound || {}) +
|
|
1430
|
+
(oMatchResult.matchesVirtualInbound ? " (virtual)" : "")
|
|
1431
|
+
+ "\n[ Sort Criteria ] "
|
|
1432
|
+
+ "\n * 1 * sap-priority: '" + oMatchResult["sap-priority"] + "'"
|
|
1433
|
+
+ "\n * 2 * Sort string: '" + oMatchResult.priorityString
|
|
1434
|
+
+ "\n * 3 * Deterministic blob: '" + _Search.serializeMatchingResult(oMatchResult) + "'";
|
|
1435
|
+
});
|
|
1436
|
+
|
|
1437
|
+
return {
|
|
1438
|
+
logId: iLogId,
|
|
1439
|
+
stage: 4,
|
|
1440
|
+
line: "Sorted inbounds as follows:",
|
|
1441
|
+
lines: aLines,
|
|
1442
|
+
prefix: ".",
|
|
1443
|
+
number: true
|
|
1444
|
+
};
|
|
1528
1445
|
});
|
|
1446
|
+
|
|
1447
|
+
|
|
1448
|
+
endLogger();
|
|
1449
|
+
return aSortedMatchResults;
|
|
1529
1450
|
};
|
|
1530
1451
|
|
|
1531
1452
|
/**
|
|
@@ -1533,34 +1454,26 @@ sap.ui.define([
|
|
|
1533
1454
|
*
|
|
1534
1455
|
* @param {string} sIntent The intent to be matched.
|
|
1535
1456
|
* @param {object} oInboundIndex The index of the inbounds to be matched.
|
|
1536
|
-
* @returns {
|
|
1457
|
+
* @returns {Promise<boolean>} Resolves with a boolean if the intent is supported and rejected if not.
|
|
1537
1458
|
* The promise resolves to true if only one target matches the intent, and false if multiple targets match the intent.
|
|
1538
1459
|
* @private
|
|
1539
1460
|
* @since 1.32.0
|
|
1540
1461
|
*/
|
|
1541
|
-
ClientSideTargetResolution.prototype._isIntentSupportedOne = function (sIntent, oInboundIndex) {
|
|
1542
|
-
var oDeferred = new jQuery.Deferred();
|
|
1462
|
+
ClientSideTargetResolution.prototype._isIntentSupportedOne = async function (sIntent, oInboundIndex) {
|
|
1543
1463
|
var oShellHash = UrlParsing.parseShellHash(sIntent);
|
|
1544
1464
|
// navigation to '#' is always considered possible
|
|
1545
1465
|
if (sIntent === "#") {
|
|
1546
|
-
|
|
1547
|
-
return oDeferred.promise();
|
|
1466
|
+
return true;
|
|
1548
1467
|
}
|
|
1549
1468
|
if (oShellHash === undefined) {
|
|
1550
|
-
|
|
1469
|
+
throw new Error(`Could not parse shell hash '${sIntent}'`);
|
|
1551
1470
|
}
|
|
1552
1471
|
|
|
1553
|
-
oShellHash.formFactor =
|
|
1472
|
+
oShellHash.formFactor = ushellUtils.getFormFactor();
|
|
1554
1473
|
|
|
1555
|
-
this._getMatchingInbounds(oShellHash, oInboundIndex, { bExcludeTileInbounds: true })
|
|
1556
|
-
.done(function (aTargets) {
|
|
1557
|
-
oDeferred.resolve(aTargets.length > 0);
|
|
1558
|
-
})
|
|
1559
|
-
.fail(function () {
|
|
1560
|
-
oDeferred.reject();
|
|
1561
|
-
});
|
|
1474
|
+
const aTargets = await this._getMatchingInbounds(oShellHash, oInboundIndex, { bExcludeTileInbounds: true });
|
|
1562
1475
|
|
|
1563
|
-
return
|
|
1476
|
+
return aTargets.length > 0;
|
|
1564
1477
|
};
|
|
1565
1478
|
|
|
1566
1479
|
/**
|
|
@@ -1581,62 +1494,37 @@ sap.ui.define([
|
|
|
1581
1494
|
* @since 1.32.0
|
|
1582
1495
|
*/
|
|
1583
1496
|
ClientSideTargetResolution.prototype.isIntentSupported = function (aIntents) {
|
|
1584
|
-
var that = this;
|
|
1585
1497
|
var oDeferred = new jQuery.Deferred();
|
|
1586
1498
|
|
|
1587
|
-
this._oInboundProvider.getInbounds()
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1499
|
+
this._oInboundProvider.getInbounds()
|
|
1500
|
+
.then((oInboundIndex) => {
|
|
1501
|
+
return this._isIntentSupported(aIntents, oInboundIndex);
|
|
1502
|
+
})
|
|
1503
|
+
.then((oSupportedByIntent) => {
|
|
1504
|
+
oDeferred.resolve(oSupportedByIntent);
|
|
1505
|
+
})
|
|
1506
|
+
.catch((oError) => {
|
|
1507
|
+
oDeferred.reject(oError);
|
|
1508
|
+
});
|
|
1509
|
+
|
|
1597
1510
|
return oDeferred.promise();
|
|
1598
1511
|
};
|
|
1599
1512
|
|
|
1600
|
-
ClientSideTargetResolution.prototype._isIntentSupported = function (aIntents, oInboundIndex) {
|
|
1601
|
-
var
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
function setResult (sIntent, bSupported) {
|
|
1614
|
-
mSupportedByIntent[sIntent] = {
|
|
1615
|
-
supported: bSupported
|
|
1616
|
-
};
|
|
1617
|
-
}
|
|
1618
|
-
|
|
1619
|
-
var aRejectErrors = [];
|
|
1620
|
-
|
|
1621
|
-
aIntents.forEach(function (sIntent) {
|
|
1622
|
-
var oNextPromise = that._isIntentSupportedOne(sIntent, oInboundIndex);
|
|
1623
|
-
oNextPromise.fail(function (sErrorMessage) {
|
|
1624
|
-
aRejectErrors.push(sErrorMessage);
|
|
1625
|
-
});
|
|
1626
|
-
oNextPromise.done(function (bResult) {
|
|
1627
|
-
setResult(sIntent, bResult);
|
|
1628
|
-
});
|
|
1629
|
-
oDeferred = jQuery.when(oDeferred, oNextPromise);
|
|
1630
|
-
});
|
|
1631
|
-
|
|
1632
|
-
var oRes = new jQuery.Deferred();
|
|
1633
|
-
oDeferred.done(function () {
|
|
1634
|
-
oRes.resolve(mSupportedByIntent);
|
|
1635
|
-
}).fail(function () {
|
|
1636
|
-
oRes.reject("One or more input intents contain errors: " + aRejectErrors.join(", "));
|
|
1637
|
-
});
|
|
1513
|
+
ClientSideTargetResolution.prototype._isIntentSupported = async function (aIntents, oInboundIndex) {
|
|
1514
|
+
var oSupportedByIntent = {};
|
|
1515
|
+
|
|
1516
|
+
await Promise.all(aIntents.map(async (sIntent) => {
|
|
1517
|
+
try {
|
|
1518
|
+
const bSupported = await this._isIntentSupportedOne(sIntent, oInboundIndex);
|
|
1519
|
+
oSupportedByIntent[sIntent] = {
|
|
1520
|
+
supported: bSupported
|
|
1521
|
+
};
|
|
1522
|
+
} catch (oError) {
|
|
1523
|
+
throw new Error(`One or more input intents contain errors: ${oError}`);
|
|
1524
|
+
}
|
|
1525
|
+
}));
|
|
1638
1526
|
|
|
1639
|
-
return
|
|
1527
|
+
return oSupportedByIntent;
|
|
1640
1528
|
};
|
|
1641
1529
|
|
|
1642
1530
|
/**
|
|
@@ -1664,26 +1552,19 @@ sap.ui.define([
|
|
|
1664
1552
|
*/
|
|
1665
1553
|
ClientSideTargetResolution.prototype.getUserDefaultParameterNames = function (oSystemContext) {
|
|
1666
1554
|
// the empty objects may in future bear information like sap-system relevance
|
|
1667
|
-
var that = this;
|
|
1668
1555
|
var oDeferred = new jQuery.Deferred();
|
|
1669
1556
|
|
|
1670
|
-
this._oInboundProvider.getInbounds()
|
|
1557
|
+
this._oInboundProvider.getInbounds()
|
|
1558
|
+
.then((oInboundIndex) => {
|
|
1559
|
+
return this._getUserDefaultParameterNames(oInboundIndex.getAllInbounds(), oSystemContext);
|
|
1560
|
+
})
|
|
1561
|
+
.then((oRefs) => {
|
|
1562
|
+
oDeferred.resolve(oRefs);
|
|
1563
|
+
})
|
|
1564
|
+
.catch((oError) => {
|
|
1565
|
+
oDeferred.reject(oError);
|
|
1566
|
+
});
|
|
1671
1567
|
|
|
1672
|
-
function (oInboundIndex) {
|
|
1673
|
-
that._getUserDefaultParameterNames(oInboundIndex.getAllInbounds(), oSystemContext)
|
|
1674
|
-
.then(
|
|
1675
|
-
function (oRef) {
|
|
1676
|
-
oDeferred.resolve(oRef);
|
|
1677
|
-
},
|
|
1678
|
-
function (e) {
|
|
1679
|
-
oDeferred.reject("Cannot get user default parameters from inbounds: " + e);
|
|
1680
|
-
}
|
|
1681
|
-
);
|
|
1682
|
-
},
|
|
1683
|
-
function () {
|
|
1684
|
-
oDeferred.reject.apply(oDeferred, arguments);
|
|
1685
|
-
}
|
|
1686
|
-
);
|
|
1687
1568
|
return oDeferred.promise();
|
|
1688
1569
|
};
|
|
1689
1570
|
|
|
@@ -1779,8 +1660,8 @@ sap.ui.define([
|
|
|
1779
1660
|
if (this._oHaveEasyAccessSystemsDeferreds[sMenuType]) {
|
|
1780
1661
|
return this._oHaveEasyAccessSystemsDeferreds[sMenuType].promise();
|
|
1781
1662
|
}
|
|
1782
|
-
|
|
1783
|
-
|
|
1663
|
+
var oDeferred = new jQuery.Deferred();
|
|
1664
|
+
this._oHaveEasyAccessSystemsDeferreds[sMenuType] = oDeferred;
|
|
1784
1665
|
|
|
1785
1666
|
function isValidEasyAccessMenuInbound (oInbound, sCurrentFormFactor, oValidMenuTypeIntents) {
|
|
1786
1667
|
if (!oInbound) {
|
|
@@ -1817,62 +1698,62 @@ sap.ui.define([
|
|
|
1817
1698
|
}, {})
|
|
1818
1699
|
};
|
|
1819
1700
|
|
|
1820
|
-
this._oInboundProvider.getInbounds()
|
|
1821
|
-
|
|
1701
|
+
this._oInboundProvider.getInbounds()
|
|
1702
|
+
.then((oInboundIndex) => { // all inbounds, no segments
|
|
1822
1703
|
var oLastPriorityPerSystem = {};
|
|
1823
1704
|
|
|
1824
|
-
oInboundIndex.getAllInbounds()
|
|
1825
|
-
|
|
1826
|
-
oInbound,
|
|
1827
|
-
)
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
}
|
|
1835
|
-
|
|
1836
|
-
if (typeof sSystemAliasName === "string") {
|
|
1837
|
-
/*
|
|
1838
|
-
* Code below builds the set of easy access system that should be displayed in the sapMenu/userMenu.
|
|
1839
|
-
* In case multiple inbounds exist with a certain system,
|
|
1840
|
-
* the app type with the highest priority is used to choose the title (see oActionDefinitions above).
|
|
1841
|
-
* Note that other app types should still appear in the result set (see 'appType' in the example result from jsdoc).
|
|
1842
|
-
*/
|
|
1843
|
-
var iCurrentActionPriority = oActionDefinitions[oEasyAccessInbound.action].priority;
|
|
1844
|
-
var sCurrentActionAppType = oActionDefinitions[oEasyAccessInbound.action].appType;
|
|
1845
|
-
|
|
1846
|
-
if (!oResultEasyAccessSystemSet[sSystemAliasName]) {
|
|
1847
|
-
// provide base structure...
|
|
1848
|
-
oLastPriorityPerSystem[sSystemAliasName] = -1;
|
|
1849
|
-
oResultEasyAccessSystemSet[sSystemAliasName] = {
|
|
1850
|
-
appType: {}
|
|
1851
|
-
};
|
|
1705
|
+
oInboundIndex.getAllInbounds()
|
|
1706
|
+
.filter(function (oInbound) {
|
|
1707
|
+
return isValidEasyAccessMenuInbound(oInbound, ushellUtils.getFormFactor(), oValidMenuTypeIntents);
|
|
1708
|
+
})
|
|
1709
|
+
.forEach(function (oEasyAccessInbound) {
|
|
1710
|
+
// extract the data for the easy access system list
|
|
1711
|
+
var sSystemAliasName;
|
|
1712
|
+
if (fnIsPlainObject(oEasyAccessInbound.signature.parameters["sap-system"]) &&
|
|
1713
|
+
oEasyAccessInbound.signature.parameters["sap-system"].hasOwnProperty("filter")) {
|
|
1714
|
+
sSystemAliasName = ObjectPath.get("signature.parameters.sap-system.filter.value", oEasyAccessInbound);
|
|
1852
1715
|
}
|
|
1853
1716
|
|
|
1854
|
-
if (
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1717
|
+
if (typeof sSystemAliasName === "string") {
|
|
1718
|
+
/*
|
|
1719
|
+
* Code below builds the set of easy access system that should be displayed in the sapMenu/userMenu.
|
|
1720
|
+
* In case multiple inbounds exist with a certain system,
|
|
1721
|
+
* the app type with the highest priority is used to choose the title (see oActionDefinitions above).
|
|
1722
|
+
* Note that other app types should still appear in the result set (see 'appType' in the example result from jsdoc).
|
|
1723
|
+
*/
|
|
1724
|
+
var iCurrentActionPriority = oActionDefinitions[oEasyAccessInbound.action].priority;
|
|
1725
|
+
var sCurrentActionAppType = oActionDefinitions[oEasyAccessInbound.action].appType;
|
|
1726
|
+
|
|
1727
|
+
if (!oResultEasyAccessSystemSet[sSystemAliasName]) {
|
|
1728
|
+
// provide base structure...
|
|
1729
|
+
oLastPriorityPerSystem[sSystemAliasName] = -1;
|
|
1730
|
+
oResultEasyAccessSystemSet[sSystemAliasName] = {
|
|
1731
|
+
appType: {}
|
|
1732
|
+
};
|
|
1733
|
+
}
|
|
1859
1734
|
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1735
|
+
if (oLastPriorityPerSystem[sSystemAliasName] < iCurrentActionPriority) {
|
|
1736
|
+
// ...then populate in case
|
|
1737
|
+
oResultEasyAccessSystemSet[sSystemAliasName].text = oEasyAccessInbound.title;
|
|
1738
|
+
oLastPriorityPerSystem[sSystemAliasName] = iCurrentActionPriority;
|
|
1739
|
+
}
|
|
1740
|
+
|
|
1741
|
+
// keep track of all the app types
|
|
1742
|
+
oResultEasyAccessSystemSet[sSystemAliasName].appType[sCurrentActionAppType] = true;
|
|
1743
|
+
} else {
|
|
1744
|
+
Log.warning(
|
|
1745
|
+
"Cannot extract sap-system from easy access menu inbound: " + _Formatter.formatInbound(oEasyAccessInbound),
|
|
1746
|
+
"This parameter is supposed to be a string. Got '" + sSystemAliasName + "' instead.",
|
|
1747
|
+
"sap.ushell.services.ClientSideTargetResolution"
|
|
1748
|
+
);
|
|
1749
|
+
}
|
|
1750
|
+
});
|
|
1870
1751
|
oDeferred.resolve(oResultEasyAccessSystemSet);
|
|
1871
|
-
}
|
|
1872
|
-
|
|
1873
|
-
oDeferred.reject
|
|
1874
|
-
}
|
|
1875
|
-
|
|
1752
|
+
})
|
|
1753
|
+
.catch((oError) => {
|
|
1754
|
+
oDeferred.reject(oError);
|
|
1755
|
+
});
|
|
1756
|
+
|
|
1876
1757
|
return oDeferred.promise();
|
|
1877
1758
|
};
|
|
1878
1759
|
|
|
@@ -1893,20 +1774,14 @@ sap.ui.define([
|
|
|
1893
1774
|
* @private
|
|
1894
1775
|
* @since 1.78.0
|
|
1895
1776
|
*/
|
|
1896
|
-
ClientSideTargetResolution.prototype.getSystemContext = function (systemId) {
|
|
1777
|
+
ClientSideTargetResolution.prototype.getSystemContext = async function (systemId) {
|
|
1897
1778
|
var sSystemId = systemId === undefined ? "" : systemId;
|
|
1898
1779
|
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
resolve(oSystemContext);
|
|
1905
|
-
})
|
|
1906
|
-
.fail(function (oError) {
|
|
1907
|
-
reject(oError);
|
|
1908
|
-
});
|
|
1909
|
-
}.bind(this));
|
|
1780
|
+
const oResolvedSystemAlias = await ushellUtils.promisify(this._oAdapter.resolveSystemAlias(sSystemId));
|
|
1781
|
+
|
|
1782
|
+
const oSystemContext = _SystemContext.createSystemContextFromSystemAlias(oResolvedSystemAlias);
|
|
1783
|
+
|
|
1784
|
+
return oSystemContext;
|
|
1910
1785
|
};
|
|
1911
1786
|
|
|
1912
1787
|
ClientSideTargetResolution.hasNoAdapter = false;
|