fix #6311: ui: prevent consent text from showing twice for oidc

Signed-off-by: Thomas Skinner <thomas@atskinner.net>
Tested-by: Gabriel Goller <g.goller@proxmox.com>
Link: https://lore.proxmox.com/20250414021836.1469242-2-thomas@atskinner.net
This commit is contained in:
Thomas Skinner 2025-04-13 21:18:36 -05:00 committed by Thomas Lamprecht
parent 2a5fa54a85
commit 1d3ff80fe5

View File

@ -22,6 +22,8 @@ Ext.define('PVE.window.LoginWindow', {
init: async function() { init: async function() {
if (Proxmox.ConsentText) { if (Proxmox.ConsentText) {
let oidc_auth_redirect = Proxmox.Utils.getOpenIDRedirectionAuthorization();
if (oidc_auth_redirect === undefined) {
Ext.create("Proxmox.window.ConsentModal", { Ext.create("Proxmox.window.ConsentModal", {
autoShow: true, autoShow: true,
consent: Proxmox.Markdown.parse( consent: Proxmox.Markdown.parse(
@ -29,6 +31,7 @@ Ext.define('PVE.window.LoginWindow', {
), ),
}); });
} }
}
}, },
onLogon: async function() { onLogon: async function() {