mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-29 16:55:05 +02:00
Fixed the force network modules execution. TICKET #1288
This commit is contained in:
parent
d58e077868
commit
ad23e19a98
@ -32,10 +32,18 @@ if (! check_acl ($config['id_user'], 0, "AR")) {
|
|||||||
// Made it a subquery, much faster on both the database and server side
|
// Made it a subquery, much faster on both the database and server side
|
||||||
if (isset ($_GET["update_netgroup"])) {
|
if (isset ($_GET["update_netgroup"])) {
|
||||||
$group = get_parameter_get ("update_netgroup", 0);
|
$group = get_parameter_get ("update_netgroup", 0);
|
||||||
|
|
||||||
if (check_acl ($config['id_user'], $group, "AW")) {
|
if (check_acl ($config['id_user'], $group, "AW")) {
|
||||||
$where = array('id_agente' => 'ANY(SELECT id_agente FROM tagente WHERE id_grupo = ' . $group . ')');
|
if ($group == 0) {
|
||||||
|
db_process_sql_update('tagente_modulo', array('flag' => 1));
|
||||||
db_process_sql_update('tagente_modulo', array('flag' => 1), $where);
|
}
|
||||||
|
else {
|
||||||
|
db_process_sql("UPDATE `tagente_modulo`
|
||||||
|
SET `flag` = 1
|
||||||
|
WHERE `id_agente` = ANY(SELECT id_agente
|
||||||
|
FROM tagente
|
||||||
|
WHERE id_grupo = " . $group . ")");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
db_pandora_audit("ACL Violation", "Trying to set flag for groups");
|
db_pandora_audit("ACL Violation", "Trying to set flag for groups");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user