1
votes

I've a custom control in my app. It runs as a standalone web application fine. But when I'm launching it from the Fiori Launchpad (FLP), it logs an error in the console. I've registered my control in my index.html file:

<script>
  sap.ui.localResources("sap.custom");
  sap.ui.localResources("sap.ui.codetools");
  sap.ui.localResources("libs");
</script>

Error

The structure of file directory is:

Directory Structure

If I remove my custom control, then I can run my app in the launchpad. Do I need to add some settings in my manifest file? What could be the reason for this error?

3

3 Answers

2
votes

The common configuration for a Fiori tile is to point to the Component file. So the index.html file is not deployed together with the app. If it's absolutely necessary to register additional module paths, do it in manifest.json instead.

{
  "sap.ui5": {
    "resourceRoots": {
      "sap.ui.codetools": "sap/ui/codetools"
    }
  }
}

Documentation: Descriptor for Applications, Components, and Libraries (See resourceRoots).

0
votes

The common configuration for a Fiori tile is to point to the Compopent.js file. So the index.html is not called. The FioriLaunchpad.html plays the role of the index.html and the ComponentContainer is defined there.

Try to register your custom control somewhere else within the app.

-2
votes

Activate the APP Node on SICF( node Name is same as App)