Disabling Sign In Popup

3533
10
Jump to solution
12-23-2022 11:00 AM
MarkEastwood
Frequent Contributor

Hi All,

When opening an experience we are getting a popup widow asking us to sign in to ArcGIS Online. Clicking "Okay" then opens up the panel where we can enter in our credentials but we would like to bypass the initial popup.

MarkEastwood_0-1671821927646.png

In Web AppBuilder, we were able to disable the initial sign in panel by editing the ./jimu.js/tokenUtils.js file. On line 17 of the code snippet below, setting the popup parameter to false hides the sign in popup. Is there something similar in the Experience Builder code? 

registerOAuthInfo: function(portalUrl, appId){
      var validParams = portalUrl && typeof portalUrl === 'string' &&
       appId && typeof appId === 'string';
      if(!validParams){
        return null;
      }
      var oAuthInfo = esriNS.id.findOAuthInfo(portalUrl);
      if(!oAuthInfo){
        var oauthReturnUrl = window.location.protocol + "//" + window.location.host +
         require.toUrl("jimu") + "/oauth-callback.html";
        //OAuth will lose 'persist' query parameter if set expiration to two weeks exectly.
        oAuthInfo = new OAuthInfo({
          appId: appId,
          expiration: 14 * 24 * 60 - 1,
          portalUrl: portalUrl,
          authNamespace: '/',
          popup: false,
          popupCallbackUrl: oauthReturnUrl
        });
        esriNS.id.registerOAuthInfos([oAuthInfo]);
      }
      oAuthInfo.appId = appId;
      return oAuthInfo;
    },

 

10 Replies
JeffreyThompson2
MVP Frequent Contributor

https://doc.arcgis.com/en/experience-builder/latest/build-apps/general-settings.htm

There is an option as of the latest ArcGIS Online update. Go to the Gear. Then Privacy and Security.

JeffreyThompson2_0-1758565133329.png

GIS Developer
City of Arlington, Texas
0 Kudos