mirror of
https://github.com/ACSPRI/queXS
synced 2024-04-02 12:12:16 +00:00
Fix issue with admin permissions not propogating to Limesurvey
This commit is contained in:
@@ -72,7 +72,11 @@ if (isset($_POST['submit']))
|
|||||||
SET users_name = " . $db->qstr($_POST['username']) . ",
|
SET users_name = " . $db->qstr($_POST['username']) . ",
|
||||||
email = " . $db->qstr($_POST['email']) . ",
|
email = " . $db->qstr($_POST['email']) . ",
|
||||||
full_name = " . $db->qstr($_POST['firstName']) . ",
|
full_name = " . $db->qstr($_POST['firstName']) . ",
|
||||||
superadmin = $superadmin";
|
superadmin = $superadmin,
|
||||||
|
create_survey = $superadmin,
|
||||||
|
configurator = $superadmin,
|
||||||
|
manage_template = $superadmin,
|
||||||
|
manage_label = $superadmin";
|
||||||
|
|
||||||
if (!empty($_POST['password']))
|
if (!empty($_POST['password']))
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -118,8 +118,8 @@ if (isset($_POST['operator']) && isset($_POST['adduser']))
|
|||||||
include_once("../include/limesurvey/admin/classes/core/sha256.php");
|
include_once("../include/limesurvey/admin/classes/core/sha256.php");
|
||||||
|
|
||||||
//Insert into lime_users
|
//Insert into lime_users
|
||||||
$sql = "INSERT INTO " . LIME_PREFIX . "users (`users_name`,`password`,`full_name`,`parent_id`,`superadmin`,`email`,`lang`)
|
$sql = "INSERT INTO " . LIME_PREFIX . "users (`users_name`,`password`,`full_name`,`parent_id`,`superadmin`,`create_survey`,`configurator`,`manage_template`,`manage_label`,`email`,`lang`)
|
||||||
VALUES ($operator, '" . SHA256::hashing($_POST['password']) . "',$firstname,1,$admin,$email,'auto')";
|
VALUES ($operator, '" . SHA256::hashing($_POST['password']) . "',$firstname,1,$admin,$admin,$admin,$admin,$admin,$email,'auto')";
|
||||||
|
|
||||||
$db->Execute($sql);
|
$db->Execute($sql);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user