Expand my Community achievements bar.

Lazy Loading fragment is not displaying data

Avatar

Level 2

I'm trying to Lazy Load the fragments on my form, but the data tables are not displaying the data. All the data cells are blank. All fields have been set as Global

According to the guides I need to implement:

  • Use panel reset feature to reset everything visible on the panel by using the following click expression.
    guideBridge.resolveNode(guideBridge.getFocus({“focusOption”: “navigablePanel”})).resetData()

Where do I trigger this? The panel with the fragment that has the lazy loading doesn't have a 'on-click' option in the rules.

Do I simply copy this into the "initialize" rule? This doesn't help, the data still does not display.

There is a previous question like this that doesn't have an answer (no I cannot test it with a later service pack). I am really desperate. The client is refusing to even start testing as the form takes too long to load.

2 Replies

Avatar

Level 2

When copying it from the website the wrong quotes were pasted (curly quotes “ instead of straight quotes " )

Code should read:

guideBridge.resolveNode(guideBridge.getFocus({"focusOption": "navigablePanel"})).resetData();

 

Avatar

Level 2

Changing the quotes actually did not resolve the issue, (I had unticked Lazy Loading whilst testing that is why the data displayed)

I am still no wiser how to implement this script as it does not appear to work on Initialise of the fragment. It doesn't even fire when I click the tab to display the lazy loaded fragment. It only gets fired when the entire form initially loads and even then it results in an error as part of the getFocus function:
TypeError: Cannot read properties of null (reading '_lastFocussedPanelForNonActionFields')