diff options
author | Robert Zorko <robertz@gurucue.com> | 2015-10-15 15:31:12 +0200 |
---|---|---|
committer | Robert Zorko <robertz@gurucue.com> | 2015-10-15 15:31:12 +0200 |
commit | 6381f087edf1c078aabf6a81ff8d72ebdca64e55 (patch) | |
tree | 7629055b91e608abc961872069082192ad8ef1bf | |
parent | 06d68b825159f99ac8356782d6656f52aa9d6c73 (diff) |
fixed some bugs with the AAI login after testing
-rw-r--r-- | index.html | 2 | ||||
-rw-r--r-- | js/codeq/aaiLogin.js | 10 |
2 files changed, 7 insertions, 5 deletions
@@ -149,7 +149,7 @@ </div> <div class="container"> <div class="row" style="padding: 0; padding-top: 5px;"> - <iframe width="100%" height="850px" frameborder="0" scrolling="no" allowtransparency="true" src="https://codeq.si/Shibboleth.sso/Login?forceAuthn=1" id="aai_iframe"></iframe> + <iframe width="100%" height="850px" frameborder="0" scrolling="no" allowtransparency="true" src="" id="aai_iframe"></iframe> </div> </div> </div> diff --git a/js/codeq/aaiLogin.js b/js/codeq/aaiLogin.js index 6ea49ea..fe7bfc8 100644 --- a/js/codeq/aaiLogin.js +++ b/js/codeq/aaiLogin.js @@ -15,9 +15,6 @@ 'enter': function(){ jqDisabledOverlay.css('display', ''); - samlLoginUrl = baseSamlUrl + codeq.comms.getSid(); - jqAaiIframe.attr('src', samlLoginUrl); - jqNavigationHomeBtn.off('click');//remove the click listener of this element here jqNavBarRight.css('display','none');//hide settings etc. @@ -29,7 +26,12 @@ $('#signed-in-title').html(''); $('#screen_aai_login').css('display',''); - codeq.comms.samlLogin() + codeq.comms.connect() + .then(function(){ + samlLoginUrl = baseSamlUrl + codeq.comms.getSid(); + jqAaiIframe.attr('src', samlLoginUrl); + return codeq.comms.samlLogin(); + }) .then(function(data){ codeq.log.debug(JSON.stringify(data)); if(data.code !== 0) throw new Error('SAML login failed, code: ' + data.code + ', message: ' + data.message); |