diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 8ef0133729..96c9c01451 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,9 @@ +2014-06-05 Sergio Martin + + * operation/agentes/ver_agente.php: Fix sql error in the layer that + appears when put the mouse over a node in network map related with tags + in users without acl profiles assigned (just admin assigned) Ticket #824 + 2014-06-05 Sergio Martin * operation/search_agents.php: Change the format of the agent interval diff --git a/pandora_console/operation/agentes/ver_agente.php b/pandora_console/operation/agentes/ver_agente.php index a8d90bb220..13ff0130b7 100644 --- a/pandora_console/operation/agentes/ver_agente.php +++ b/pandora_console/operation/agentes/ver_agente.php @@ -473,8 +473,9 @@ if (is_ajax ()) { $_tags = implode(',', array_keys($_user_tags)); - $_sql_post .= ' AND tagente_modulo.id_agente_modulo IN (SELECT a.id_agente_modulo FROM tagente_modulo a, ttag_module b WHERE a.id_agente_modulo=b.id_agente_modulo AND b.id_tag IN (' . $_tags . ')) '; - + if (!empty($_tags)) { + $_sql_post .= ' AND tagente_modulo.id_agente_modulo IN (SELECT a.id_agente_modulo FROM tagente_modulo a, ttag_module b WHERE a.id_agente_modulo=b.id_agente_modulo AND b.id_tag IN (' . $_tags . ')) '; + } } $sql = sprintf ('SELECT tagente_modulo.descripcion,