Solve issue and added correct headers
This commit is contained in:
parent
0ec39bd135
commit
579b8d4965
|
@ -2125,6 +2125,8 @@ function get_group_alerts(
|
||||||
$disabled = $filter;
|
$disabled = $filter;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$filter .= ' AND talert_template_modules.disabled = 0 ';
|
||||||
|
|
||||||
switch ($disabled) {
|
switch ($disabled) {
|
||||||
case 'notfired':
|
case 'notfired':
|
||||||
$filter .= ' AND times_fired = 0 AND talert_template_modules.disabled = 0';
|
$filter .= ' AND times_fired = 0 AND talert_template_modules.disabled = 0';
|
||||||
|
@ -2181,7 +2183,7 @@ function get_group_alerts(
|
||||||
if (empty($id_group)) {
|
if (empty($id_group)) {
|
||||||
$subQuery = 'SELECT id_agente_modulo
|
$subQuery = 'SELECT id_agente_modulo
|
||||||
FROM tagente_modulo
|
FROM tagente_modulo
|
||||||
WHERE 1 = 0';
|
WHERE 1 = 0';
|
||||||
} else {
|
} else {
|
||||||
$subQuery = 'SELECT id_agente_modulo
|
$subQuery = 'SELECT id_agente_modulo
|
||||||
FROM tagente_modulo
|
FROM tagente_modulo
|
||||||
|
@ -2190,7 +2192,8 @@ function get_group_alerts(
|
||||||
FROM tagente ta
|
FROM tagente ta
|
||||||
LEFT JOIN tagent_secondary_group tasg
|
LEFT JOIN tagent_secondary_group tasg
|
||||||
ON ta.id_agente = tasg.id_agent
|
ON ta.id_agente = tasg.id_agent
|
||||||
WHERE
|
WHERE ta.disable = 0
|
||||||
|
AND
|
||||||
id_grupo IN ('.implode(',', $id_group).')
|
id_grupo IN ('.implode(',', $id_group).')
|
||||||
OR id_group IN ('.implode(',', $id_group).'))';
|
OR id_group IN ('.implode(',', $id_group).'))';
|
||||||
}
|
}
|
||||||
|
@ -2199,7 +2202,7 @@ function get_group_alerts(
|
||||||
FROM tagente_modulo
|
FROM tagente_modulo
|
||||||
WHERE delete_pending = 0
|
WHERE delete_pending = 0
|
||||||
AND id_agente IN (SELECT id_agente
|
AND id_agente IN (SELECT id_agente
|
||||||
FROM tagente WHERE id_grupo = '.$idGroup.')';
|
FROM tagente WHERE id_grupo = '.$idGroup.' AND tagente.disabled = 0)';
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// ALL GROUP
|
// ALL GROUP
|
||||||
|
|
|
@ -1,16 +1,46 @@
|
||||||
<?php
|
<?php
|
||||||
|
/**
|
||||||
|
* Tactical view functions script
|
||||||
|
*
|
||||||
|
* @category Functions
|
||||||
|
* @package Pandora FMS
|
||||||
|
* @subpackage Tactical View
|
||||||
|
* @version 1.0.0
|
||||||
|
* @license See below
|
||||||
|
*
|
||||||
|
* ______ ___ _______ _______ ________
|
||||||
|
* | __ \.-----.--.--.--| |.-----.----.-----. | ___| | | __|
|
||||||
|
* | __/| _ | | _ || _ | _| _ | | ___| |__ |
|
||||||
|
* |___| |___._|__|__|_____||_____|__| |___._| |___| |__|_|__|_______|
|
||||||
|
*
|
||||||
|
* ============================================================================
|
||||||
|
* Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
||||||
|
* Please see http://pandorafms.org for full contribution list
|
||||||
|
* This program is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU General Public License
|
||||||
|
* as published by the Free Software Foundation for version 2.
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
* ============================================================================
|
||||||
|
*/
|
||||||
|
|
||||||
// Pandora FMS - http://pandorafms.com
|
// Begin.
|
||||||
// ==================================================
|
|
||||||
// Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
|
||||||
// Please see http://pandorafms.org for full contribution list
|
/**
|
||||||
// This program is free software; you can redistribute it and/or
|
* Undocumented function
|
||||||
// modify it under the terms of the GNU Lesser General Public License
|
*
|
||||||
// as published by the Free Software Foundation; version 2
|
* @param boolean $id_user
|
||||||
// This program is distributed in the hope that it will be useful,
|
* @param boolean $user_strict
|
||||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
* @param [type] $acltags
|
||||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
* @param boolean $returnAllGroup
|
||||||
// GNU General Public License for more details.
|
* @param string $mode
|
||||||
|
* @param array $agent_filter
|
||||||
|
* @param array $module_filter
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
function tactical_get_data($id_user=false, $user_strict=false, $acltags, $returnAllGroup=false, $mode='group', $agent_filter=[], $module_filter=[])
|
function tactical_get_data($id_user=false, $user_strict=false, $acltags, $returnAllGroup=false, $mode='group', $agent_filter=[], $module_filter=[])
|
||||||
{
|
{
|
||||||
global $config;
|
global $config;
|
||||||
|
@ -368,7 +398,7 @@ function tactical_get_data($id_user=false, $user_strict=false, $acltags, $return
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case AGENT_MODULE_STATUS_NORMAL_ALERT:
|
case AGENT_MODULE_STATUS_NORMAL_ALERT:
|
||||||
|
// Do nothing.
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case AGENT_MODULE_STATUS_NORMAL:
|
case AGENT_MODULE_STATUS_NORMAL:
|
||||||
|
|
|
@ -1,16 +1,32 @@
|
||||||
<?php
|
<?php
|
||||||
|
/**
|
||||||
|
* Alerts Status functions script
|
||||||
|
*
|
||||||
|
* @category Functions
|
||||||
|
* @package Pandora FMS
|
||||||
|
* @subpackage Alert Status
|
||||||
|
* @version 1.0.0
|
||||||
|
* @license See below
|
||||||
|
*
|
||||||
|
* ______ ___ _______ _______ ________
|
||||||
|
* | __ \.-----.--.--.--| |.-----.----.-----. | ___| | | __|
|
||||||
|
* | __/| _ | | _ || _ | _| _ | | ___| |__ |
|
||||||
|
* |___| |___._|__|__|_____||_____|__| |___._| |___| |__|_|__|_______|
|
||||||
|
*
|
||||||
|
* ============================================================================
|
||||||
|
* Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
||||||
|
* Please see http://pandorafms.org for full contribution list
|
||||||
|
* This program is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU General Public License
|
||||||
|
* as published by the Free Software Foundation for version 2.
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
* ============================================================================
|
||||||
|
*/
|
||||||
|
|
||||||
// Pandora FMS - http://pandorafms.com
|
// Begin.
|
||||||
// ==================================================
|
|
||||||
// Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
|
||||||
// Please see http://pandorafms.org for full contribution list
|
|
||||||
// This program is free software; you can redistribute it and/or
|
|
||||||
// modify it under the terms of the GNU General Public License
|
|
||||||
// as published by the Free Software Foundation for version 2.
|
|
||||||
// This program is distributed in the hope that it will be useful,
|
|
||||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
// GNU General Public License for more details.
|
|
||||||
function forceExecution($id_group)
|
function forceExecution($id_group)
|
||||||
{
|
{
|
||||||
global $config;
|
global $config;
|
||||||
|
|
|
@ -1,16 +1,31 @@
|
||||||
<?php
|
<?php
|
||||||
|
/**
|
||||||
|
* Alerts Status
|
||||||
|
*
|
||||||
|
* @category Alerts
|
||||||
|
* @package Pandora FMS
|
||||||
|
* @subpackage Alert Status View
|
||||||
|
* @version 1.0.0
|
||||||
|
* @license See below
|
||||||
|
*
|
||||||
|
* ______ ___ _______ _______ ________
|
||||||
|
* | __ \.-----.--.--.--| |.-----.----.-----. | ___| | | __|
|
||||||
|
* | __/| _ | | _ || _ | _| _ | | ___| |__ |
|
||||||
|
* |___| |___._|__|__|_____||_____|__| |___._| |___| |__|_|__|_______|
|
||||||
|
*
|
||||||
|
* ============================================================================
|
||||||
|
* Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
||||||
|
* Please see http://pandorafms.org for full contribution list
|
||||||
|
* This program is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU General Public License
|
||||||
|
* as published by the Free Software Foundation for version 2.
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
* ============================================================================
|
||||||
|
*/
|
||||||
|
|
||||||
// Pandora FMS - http://pandorafms.com
|
|
||||||
// ==================================================
|
|
||||||
// Copyright (c) 2005-2021 Artica Soluciones Tecnologicas
|
|
||||||
// Please see http://pandorafms.org for full contribution list
|
|
||||||
// This program is free software; you can redistribute it and/or
|
|
||||||
// modify it under the terms of the GNU General Public License
|
|
||||||
// as published by the Free Software Foundation for version 2.
|
|
||||||
// This program is distributed in the hope that it will be useful,
|
|
||||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
// GNU General Public License for more details.
|
|
||||||
global $config;
|
global $config;
|
||||||
|
|
||||||
// Login check
|
// Login check
|
||||||
|
|
Loading…
Reference in New Issue