2012-06-08 Dario Rodriguez <dario.rodriguez@artica.es>

* operation/tree.php: Improved performance of
	sub tree for policies tree view.

	MERGED FROM 4.0.2



git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6464 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
darode 2012-06-08 15:13:19 +00:00
parent f7cf115f07
commit 9284e6130f
2 changed files with 8 additions and 7 deletions

View File

@ -1,3 +1,10 @@
2012-06-08 Dario Rodriguez <dario.rodriguez@artica.es>
* operation/tree.php: Improved performance of
sub tree for policies tree view.
MERGED FROM 4.0.2
2012-06-08 Dario Rodriguez <dario.rodriguez@artica.es> 2012-06-08 Dario Rodriguez <dario.rodriguez@artica.es>
* operation/tree.php: Improved performance of tree * operation/tree.php: Improved performance of tree

View File

@ -322,6 +322,7 @@ if (is_ajax ())
switch ($type) { switch ($type) {
case 'group': case 'group':
case 'os': case 'os':
case 'policies':
$agent_info["monitor_alertsfired"] = agents_get_alerts_fired ($row["id_agente"]); $agent_info["monitor_alertsfired"] = agents_get_alerts_fired ($row["id_agente"]);
$agent_info["monitor_critical"] = agents_monitor_critical ($row["id_agente"]); $agent_info["monitor_critical"] = agents_monitor_critical ($row["id_agente"]);
@ -341,13 +342,6 @@ if (is_ajax ())
case 'module_group': case 'module_group':
$agent_info = reporting_get_agent_module_info ($row["id_agente"], ' id_module_group = ' . $id); $agent_info = reporting_get_agent_module_info ($row["id_agente"], ' id_module_group = ' . $id);
break; break;
case 'policies':
$whereQuery = '';
if ($id_father != 0)
$whereQuery = ' id_modulo IN
(SELECT id_module FROM tpolicy_modules WHERE id_policy = ' . $id_father . ')';
$agent_info = reporting_get_agent_module_info ($row["id_agente"], $whereQuery);
break;
case 'module': case 'module':
switch ($config["dbtype"]) { switch ($config["dbtype"]) {
case "mysql": case "mysql":