[icinga-checkins] icinga.org: icinga-reports/master: added servicegroup availability

git at icinga.org git at icinga.org
Fri Aug 24 15:11:05 CEST 2012


Module: icinga-reports
Branch: master
Commit: b2c6f33c555b30ce22ae268bf769f9c570f7b1a6
URL:    https://git.icinga.org/?p=icinga-reports.git;a=commit;h=b2c6f33c555b30ce22ae268bf769f9c570f7b1a6

Author: Bernd Erk <bernd.erk at icinga.org>
Date:   Fri Aug 24 13:33:18 2012 +0200

added servicegroup availability

---

 .../availabilityReportInGivenTime.jrxml            |   19 ++++++++++++-------
 1 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/jasperreports/templates/main/servicegroup/availabilityReportInGivenTime.jrxml b/jasperreports/templates/main/servicegroup/availabilityReportInGivenTime.jrxml
index 3349064..da8e2b7 100644
--- a/jasperreports/templates/main/servicegroup/availabilityReportInGivenTime.jrxml
+++ b/jasperreports/templates/main/servicegroup/availabilityReportInGivenTime.jrxml
@@ -2,7 +2,7 @@
 <jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="Availability report about a selected Servicegroup in a given time" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" isTitleNewPage="true">
 	<property name="ireport.zoom" value="1.0"/>
 	<property name="ireport.x" value="0"/>
-	<property name="ireport.y" value="0"/>
+	<property name="ireport.y" value="364"/>
 	<import value="org.icinga.reporting.DateHelper"/>
 	<template><![CDATA["repo:/icinga/styles/IcingaStyleBase.jrtx"]]></template>
 	<parameter name="SUBREPORT_DIR" class="java.lang.String" isForPrompting="false">
@@ -27,6 +27,7 @@
 	<queryString>
 		<![CDATA[select a.service_object_id,
   c.name1,
+  c.name2,
   b.alias
 from icinga_servicegroup_members a,
   icinga_servicegroups b,
@@ -35,6 +36,10 @@ where a.servicegroup_id   = b.servicegroup_id
 and c.object_id           = a.service_object_id
 and b.servicegroup_object_id = $P{p_servicegroup_object_id}]]>
 	</queryString>
+	<field name="service_object_id" class="java.math.BigInteger"/>
+	<field name="name2" class="java.lang.String"/>
+	<field name="alias" class="java.lang.String"/>
+	<field name="name1" class="java.lang.String"/>
 	<background>
 		<band splitType="Stretch"/>
 	</background>
@@ -215,18 +220,18 @@ and b.servicegroup_object_id = $P{p_servicegroup_object_id}]]>
 				<subreportParameter name="SUBREPORT_DIR">
 					<subreportParameterExpression><![CDATA[$P{SUBREPORT_DIR}]]></subreportParameterExpression>
 				</subreportParameter>
-				<subreportParameter name="p_object_name">
-					<subreportParameterExpression><![CDATA[$F{name1}]]></subreportParameterExpression>
-				</subreportParameter>
-				<subreportParameter name="p_host_object_id">
-					<subreportParameterExpression><![CDATA[$F{host_object_id}]]></subreportParameterExpression>
-				</subreportParameter>
 				<subreportParameter name="p_date_end">
 					<subreportParameterExpression><![CDATA[$P{p_final_date_end}]]></subreportParameterExpression>
 				</subreportParameter>
 				<subreportParameter name="p_date_start">
 					<subreportParameterExpression><![CDATA[$P{p_final_date_start}]]></subreportParameterExpression>
 				</subreportParameter>
+				<subreportParameter name="p_host_name">
+					<subreportParameterExpression><![CDATA[$F{name1}]]></subreportParameterExpression>
+				</subreportParameter>
+				<subreportParameter name="p_service_object_id">
+					<subreportParameterExpression><![CDATA[$F{service_object_id}]]></subreportParameterExpression>
+				</subreportParameter>
 				<connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression>
 				<subreportExpression><![CDATA[$P{SUBREPORT_DIR} + "service/availabilityInGivenTime"]]></subreportExpression>
 			</subreport>





More information about the icinga-checkins mailing list