[icinga-checkins] icinga.org: icinga-web/r1.8: Removed group fields from queries, will cause duplicates butfixes #3330, which is more important

git at icinga.org git at icinga.org
Mon Jan 14 13:41:51 CET 2013


Module: icinga-web
Branch: r1.8
Commit: 8fe730100e23a96c1d5c32eb5b17ab0c567bce71
URL:    https://git.icinga.org/?p=icinga-web.git;a=commit;h=8fe730100e23a96c1d5c32eb5b17ab0c567bce71

Author: Jannis Mosshammer <jannis.mosshammer at netways.de>
Date:   Wed Dec 19 16:22:37 2012 +0100

Removed group fields from queries, will cause duplicates butfixes #3330, which is more important

---

 app/modules/Api/config/views/host.xml    |    6 +-----
 app/modules/Api/config/views/service.xml |    3 ---
 2 files changed, 1 insertions(+), 8 deletions(-)

diff --git a/app/modules/Api/config/views/host.xml b/app/modules/Api/config/views/host.xml
index c6efed1..4c4f058 100755
--- a/app/modules/Api/config/views/host.xml
+++ b/app/modules/Api/config/views/host.xml
@@ -46,7 +46,7 @@
             WHERE h.config_type = '${retained_flag}'
             ]]>
             </query>
-            
+            <unique_field>h.host_object_id</unique_field>
             <credential name="UserObjectId" type="UserObjectId">
                 <parameter name="target_fields">h.host_object_id</parameter>
                 <parameter name="aggregation">or</parameter>
@@ -78,14 +78,12 @@
                 <join>h.hostgroups hg</join>
                 <join>hg.object ohg</join>
                 <select>ohg.name1 AS hostgroup_name</select>
-                <groupby>h.host_object_id</groupby>
             </filter>
             
             <filter name="hostgroup_object_id" type="dql">
                 <join>h.hostgroups hg</join>
                 <join>hg.object ohg</join>
                 <select>ohg.object_id AS hostgroup_object_id</select>
-                <groupby>h.host_object_id</groupby>                
             </filter>
             
             <filter name="servicegroup_name" type="dql">
@@ -93,7 +91,6 @@
                 <join>s.servicegroups sg</join>
                 <join>sg.object osg</join>
                 <select>osg.name1 AS servicegroup_name</select>
-                <groupby>h.host_object_id</groupby>
             </filter>
             
             <filter name="servicegroup_object_id" type="dql">
@@ -101,7 +98,6 @@
                 <join>s.servicegroups sg</join>
                 <join>sg.object osg</join>
                 <select>osg.object_id AS servicegroup_object_id</select>
-                <groupby>h.host_object_id</groupby>
             </filter>
 
 
diff --git a/app/modules/Api/config/views/service.xml b/app/modules/Api/config/views/service.xml
index 0d28ffc..c5f175c 100755
--- a/app/modules/Api/config/views/service.xml
+++ b/app/modules/Api/config/views/service.xml
@@ -84,7 +84,6 @@
                 <innerjoin>h.hostgroups hg</innerjoin>
                 <innerjoin>hg.object ohg</innerjoin>
                 <select>ohg.name1 AS hostgroup_name</select>
-                <groupby>s.service_object_id</groupby>              
             </filter>
 
             <filter name="hostgroup_object_id" type="dql">
@@ -97,14 +96,12 @@
                 <innerjoin>s.servicegroups sg</innerjoin>
                 <innerjoin>sg.object osg</innerjoin>
                 <select>osg.name1 AS servicegroup_name</select>
-                <groupby>s.service_object_id</groupby>
             </filter>
 
             <filter name="servicegroup_object_id" type="dql">
                 <innerjoin>s.servicegroups sg</innerjoin>
                 <innerjoin>sg.object osg</innerjoin>
                 <select>osg.object_id AS servicegroup_object_id</select>
-                <groupby>h.service_object_id</groupby>
             </filter>
 
             <filter name="service_is_pending" type="dql">





More information about the icinga-checkins mailing list