IFrame not working in Lightning record page in Millau version

  • 1
  • Problem
  • Updated 2 years ago
  • Not a Problem
Hi All!

We just upgraded Skuid to Millau 11.0. We are using Iframe to load a Visualforce page in Skuid, and when clicked preview button in Lightning mode, it worked well. But it does not work when we embedded to a Lightning record page, this Visualforce page cannot load.

Any help to fix will be appreciated.

Thanks.
Photo of Kevin

Kevin

  • 782 Points 500 badge 2x thumb

Posted 2 years ago

  • 1
Photo of Pat Vachon

Pat Vachon, Champion

  • 44,396 Points 20k badge 2x thumb
Check the security on the VF page to make sure Profiles for desired users have access.
Photo of Kevin

Kevin

  • 782 Points 500 badge 2x thumb
Hi Pat,

The security on VF page has already set.
In Sandbox (Brooklyn version) this issue didn't occur.

This issue only occurs after I upgraded to Millau version.

Thanks.
Photo of Mark DeSimone

Mark DeSimone, Official Rep

  • 12,066 Points 10k badge 2x thumb
Kien, do you see any error messages on the page, or in the browser console?
Photo of Kevin

Kevin

  • 782 Points 500 badge 2x thumb
Hi Mark,

In Sandbox (Brooklyn version) this issue didn't occur.

This issue only occurs after I upgraded to Millau version. I see that iframe doesn't work in Lightning page.



Thanks.
(Edited)
Photo of Mark DeSimone

Mark DeSimone, Official Rep

  • 12,066 Points 10k badge 2x thumb
Hi Kien, it looks like the VM2802_main.js and VM2820_shortcuts.js static resources actually aren't part of the Skuid package. I'm not seeing them present in the orgs I have access to. Is there another package or other component that is loading and running these resources in Lightning? And, does the Skuid page work properly when you preview it from your Page Composer?
Photo of Kevin

Kevin

  • 782 Points 500 badge 2x thumb
Hi Mark,

I only add Skuid page to Lightning record page using Lightning App Builder.
The Skuid page worked properly when I preview it from the Page Composer, but it fails when I go to record detail in Lightning mode.
Photo of Kevin

Kevin

  • 782 Points 500 badge 2x thumb
I attached 2 screenshots in Lightning record page and in a normal environment.



Photo of Josh Lewis

Josh Lewis, Alum

  • 1,218 Points 1k badge 2x thumb
Hello Kien,

I wanted to share our documentation for deploying Skuid Pages in Lightning on the off chance that they may be some pieces of information here that might help. The documentation can be found here: https://docs.skuid.com/latest/en/skuid/deploy/salesforce/lightning/index.html. You may want to investigate and confirm that the model ID is being passed in correctly as a page parameter for your Skuid Pages.

If you are unable to track down the issue after taking a look through the documentation, could you please share the xml for your page here?

Thanks,

Josh
Photo of Kevin

Kevin

  • 782 Points 500 badge 2x thumb
Hi Josh,

In previous version (Brooklyn), it worked perfectly. But the error occurred when I upgraded to Millau 11.0. I wonder whether the error came from Millau 11.0 version.

Thanks for your help.

Kien
Photo of Mark DeSimone

Mark DeSimone, Official Rep

  • 12,066 Points 10k badge 2x thumb
Official Response
Our development team has reviewed this issue, and determined that what you are experiencing is not a product defect - it is expected behavior in Skuid Millau in Lightning. Your iframes are being blocked from loading by Salesforce's Lightning Lockerservice. This wasn't happening in Skuid Brooklyn because Lockerservice wasn't being enforced as strictly (Skuid Brooklyn uses Salesforce's API 39). Since Skuid Millau is using Salesforce API 41, Lockerservice is now enforced when using Skuid in Lightning.

One possible workaround is to enclose your Skuid page in a Visualforce page, then bring that Visualforce page into your Lightning app, instead of using the Skuid Lightning component. This is a way to put all of the iframes' URLs inside one domain, but it has limitations because it's still using iframes, in the end. 

Read more here about this change in our release notes, and please see our information about iframes here