From f1ab2a147690e4ba376b0cf850e82ff92418ba22 Mon Sep 17 00:00:00 2001 From: Dominik Csapak Date: Tue, 4 Apr 2017 13:48:42 +0200 Subject: [PATCH] add updateLoginData to PMG.Utils we need this multiple times Signed-off-by: Dominik Csapak --- js/Utils.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/js/Utils.js b/js/Utils.js index 4563388..8054249 100644 --- a/js/Utils.js +++ b/js/Utils.js @@ -227,6 +227,12 @@ Ext.define('PMG.Utils', { nw.focus(); }, + updateLoginData: function(data) { + Proxmox.CSRFPreventionToken = data.CSRFPreventionToken; + Proxmox.UserName = data.username; + Ext.util.Cookies.set('PMGAuthCookie', data.ticket, null, '/', null, true ); + }, + constructor: function() { var me = this;