implement admin-access with OAuth

This commit is contained in:
Min RK
2017-03-30 19:15:43 +02:00
parent ff6a68112e
commit 4bb8e47f3b
7 changed files with 18 additions and 25 deletions

View File

@@ -77,17 +77,7 @@ require(["jquery", "bootstrap", "moment", "jhapi", "utils"], function ($, bs, mo
var el = $(this);
var row = get_row(el);
var user = row.data('user');
var w = window.open();
api.admin_access(user, {
async: false,
success: function () {
w.location = utils.url_path_join(prefix, 'user', user);
},
error: function (xhr, err) {
w.close();
console.error("Failed to gain access to server", err);
}
});
var w = window.open(utils.url_path_join(prefix, 'user', user));
});
$(".start-server").click(function () {