dashboard: preserve path when relogin is required

This commit is contained in:
Johannes Zellner
2024-04-29 15:22:01 +02:00
parent 67c1b2cb71
commit 3df7b74f65
2 changed files with 8 additions and 1 deletions
+2
View File
@@ -2742,6 +2742,8 @@ angular.module('Application').service('Client', ['$http', '$interval', '$timeout
Client.prototype.login = function () {
this.setToken(null);
localStorage.setItem('redirectToHash', window.location.hash);
// start oidc flow
window.location.href = this.apiOrigin + '/openid/auth?client_id=' + ('<%= apiOrigin %>' ? TOKEN_TYPES.ID_DEVELOPMENT : TOKEN_TYPES.ID_WEBADMIN) + '&scope=openid email profile&response_type=code token&redirect_uri=' + window.location.origin + '/authcallback.html';
};