mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-07 05:31:22 +00:00
Add missing "connection group creation" permission.
This commit is contained in:
@@ -465,23 +465,37 @@ GuacAdmin.UserEditor = function(name, parameters) {
|
|||||||
if (user_perms.create_connection)
|
if (user_perms.create_connection)
|
||||||
create_connections.checked = true;
|
create_connections.checked = true;
|
||||||
|
|
||||||
|
// Add create connection group permission checkbox
|
||||||
|
var create_connection_groups = GuacUI.createChildElement(
|
||||||
|
GuacUI.createTabulatedContainer(permission_table, "Create new connection groups:"),
|
||||||
|
"input");
|
||||||
|
create_connection_groups.setAttribute("type", "checkbox");
|
||||||
|
create_connection_groups.setAttribute("value", "create_connection_group");
|
||||||
|
|
||||||
|
// Check if set
|
||||||
|
if (user_perms.create_connection_group)
|
||||||
|
create_connection_groups.checked = true;
|
||||||
|
|
||||||
// Update system permissions when changed
|
// Update system permissions when changed
|
||||||
is_admin.onclick = create_users.onclick =
|
is_admin.onclick =
|
||||||
create_connections.onclick = function() {
|
create_users.onclick =
|
||||||
|
create_connections.onclick =
|
||||||
|
create_connection_groups.onclick =
|
||||||
|
function() {
|
||||||
|
|
||||||
// Update permission deltas for ADDED permission
|
// Update permission deltas for ADDED permission
|
||||||
if (this.checked) {
|
if (this.checked) {
|
||||||
added_perms[this.value] = true;
|
added_perms[this.value] = true;
|
||||||
removed_perms[this.value] = false;
|
removed_perms[this.value] = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update permission deltas for REMOVED permission
|
// Update permission deltas for REMOVED permission
|
||||||
else {
|
else {
|
||||||
added_perms[this.value] = false;
|
added_perms[this.value] = false;
|
||||||
removed_perms[this.value] = true;
|
removed_perms[this.value] = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user