mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-29 08:45:12 +02:00
Merge branch 'ent-5509-Resumen-erroneo-de-borrado-en-OPERACIONES-MASIVAS' into 'develop'
Ent 5509 resumen erroneo de borrado en operaciones masivas See merge request artica/pandorafms!3085
This commit is contained in:
commit
1dddb6d81a
@ -101,10 +101,17 @@ function process_manage_delete($id_alert_template, $id_agents, $module_names)
|
|||||||
|
|
||||||
$module_selection_mode = get_parameter('modules_selection_mode');
|
$module_selection_mode = get_parameter('modules_selection_mode');
|
||||||
|
|
||||||
|
$alert_list = db_get_all_rows_filter('talert_template_modules', ['id_alert_template' => $id_alert_template], 'id_agent_module');
|
||||||
|
|
||||||
foreach ($module_names as $module) {
|
foreach ($module_names as $module) {
|
||||||
foreach ($id_agents as $id_agent) {
|
foreach ($id_agents as $id_agent) {
|
||||||
$module_id = modules_get_agentmodule_id($module, $id_agent);
|
$module_id = modules_get_agentmodule_id($module, $id_agent);
|
||||||
$modules_id[] = $module_id['id_agente_modulo'];
|
// The module can exist in several of the selected agents, but we have to check if it has an alert.
|
||||||
|
foreach ($alert_list as $alert) {
|
||||||
|
if ($alert['id_agent_module'] == $module_id['id_agente_modulo']) {
|
||||||
|
$modules_id[] = $module_id['id_agente_modulo'];
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user