Skip to content
Snippets Groups Projects
Commit dbc8e9d2 authored by Till Brehm's avatar Till Brehm
Browse files

Merge branch 'feature/allow-updating-sysuser-modules-through-remoting' into 'stable-3.1'

Allow updating sysuser modules through remoting

See merge request ispconfig/ispconfig3!984
parents 7c67b8e5 b9cd2f66
No related branches found
No related tags found
No related merge requests found
......@@ -309,6 +309,7 @@ class remoting_lib extends tform_base {
$username = $params["username"];
$clear_password = $params["password"];
$language = $params['language'];
$modules = $params['modules'];
$client_id = $app->functions->intval($client_id);
if(!isset($params['_ispconfig_pw_crypted']) || $params['_ispconfig_pw_crypted'] != 1) $password = $app->auth->crypt_password(stripslashes($clear_password));
......@@ -327,8 +328,14 @@ class remoting_lib extends tform_base {
$params[] = $language;
}
$modulesstring = '';
if (!empty($modules)) {
$modulesstring = ', modules = ?';
$params[] = $modules;
}
$params[] = $client_id;
$sql = "UPDATE sys_user set username = ? $pwstring $langstring WHERE client_id = ?";
$sql = "UPDATE sys_user set username = ? $pwstring $langstring $modulesstring WHERE client_id = ?";
$app->db->query($sql, true, $params);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment