Online Tutorials & Training Materials | STechies.com
Register Login

Error: Duplicate id for SAPUI5 Fiori Application when running in SAP Fiori launchpad

|| 0

Error: Duplicate id for SAPUI5 Fiori Application when running in SAP Fiori launchpad
Stechies

When we are running the SAP Fiori launchpad on ABAP the following error is displayed in the browser console: 

Component URL defined in target mapping does not match the URL retrieved from application index. A possible reason is that the component ID is not unique.

You have User Interface Add-On 2.0 for SAP NetWeaver installed. The component id of all deployed SAPUI5 applications needs to be unique system-wide. The URL of the target mapping defined in SAP Fiori launchpad navigation content has to be the root URL of the corresponding SAPUI5 application repository. If you see this error message, the URL in the target mapping is either completely wrong (no matching SAPUI5 app installed) or there are several SAPUI5 applications with the same component id installed.

SAP delivers SAPUI5 applications with unique ids. It might be the case that your customer application unintentionally uses the same id like a SAP-delivered SAPUI5 application or another SAPUI5 application from you, e.g. as you had copied it.

see the following points

1. Error caused by wrong URL in target mapping:

Verify that the URL defined in the target mapping refers to an existing SAPUI5 application. If not, open the SAP Fiori launchpad designer and correct the target mapping.

2. Error caused by ambiguous component id:

The component id of your customer SAPUI5 application needs to be changed to a system-wide unique one.

To do this please follow the steps by assuming that the duplicate id of your app would be hcm.emp.myleaverequests and you are going to change that to com.mycompany.hcm.emp.myleaverequests to make it unique:

Get your customer SAPUI5 application from the ABAP server by doing one of the following:

  • Use report /UI5/UI5_REPOSITORY_LOAD on the ABAP server with Download option
  • Use SAPUI5 ABAP Team Provider in Eclipse to retrieve your application from the ABAP server
  • Use SAP Web IDE via File -> Import -> Application from SAPUI5 ABAP Repository

In your complete project (all files and folders) search for hcm.emp.myleaverequests and replace it by com.mycompany.hcm.emp.myleaverequests

In your complete project (all files and folders) search for hcm/emp/myleaverequests and replace it by com/mycompany/hcm/emp/myleaverequests
Store your customer SAPUI5 application on the ABAP server by doing one of the following (depending on what you did in step 1.):

  • Use report /UI5/UI5_REPOSITORY_LOAD on the ABAP server with Upload option
  • Use SAPUI5 ABAP Team Provider in Eclipse to submit your application to the ABAP server
  • Use SAP Web IDE via context menu Deploy -> Deploy to SAPUI5 ABAP Repository and choosing "Update an existing application"

Adopt your customizing for the SAP Fiori launchpad for your target mapping by exchanging the hcm.emp.myleaverequests by your new component id com.mycompany.hcm.emp.myleaverequests


Related Articles