cancel
Showing results for 
Search instead for 
Did you mean: 

SAP Fioir Application Json model data is not loading in Launchpad?

former_member198924
Participant
0 Kudos

Hi All,

I have created a mock json data model in SAPUI5 application webide. It is working fine in webide. But after deployed the application in launchpad. Mock Json data is not load in view. Can you please give me your valuable suggestion.

boghyon
Product and Topic Expert
Product and Topic Expert
0 Kudos

It's hard to guess what could cause the issue with 0 information. Please always provide relevant code snippets (minimal) and the folder structure when asking such questions. Please read How to create a Minimal, Complete, and Verifiable example.

Accepted Solutions (0)

Answers (3)

Answers (3)

boghyon
Product and Topic Expert
Product and Topic Expert
0 Kudos

When deploying, Web IDE starts build processes via grunt tasks. While doing that, it removes project resources that don't belong to the productive environment. One of the resources is the "test" folder.

> This ("test") folder has to be excluded when you are building a Component-preload.js. You should never reference resources of the test folder from your application, because when you deploy to a productive environment, the resource cannot be loaded. (source)

Make sure you're not including mock data or mock server in the "test" folder.

Additionally, apps deployed to FLP don't contain any HTML documents (neither index.html nor mockServer.html) but start right from the Component(-preload).js. Make sure you're not referencing mock data or mock server from those HTML documents.

former_member553417
Participant
0 Kudos

In Launchpad while define-in path we need to mention our component name alone with the path for mock data

jQuery.sap.getModulePath("com.abc.real.model","/country.json")

0 Kudos

Check in Networks , weather mock.json is loaded or not , also check console , what error is appearing. If the file is not loaded Then,

Try. jQuery.require("/model/mock.json") in the controller , you are using that model.

OR

If your fiori version is older that your developed UI5 version.

You can also check ID of your app in manifest.json.

Make sure same ID is not used for any another application in fiori