[542] | 1 | <?xml version="1.0" encoding="UTF-8"?> |
---|
| 2 | <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="reportName" language="groovy" pageWidth="842" pageHeight="595" orientation="Landscape" whenNoDataType="NoDataSection" columnWidth="782" leftMargin="30" rightMargin="30" topMargin="20" bottomMargin="20" isSummaryNewPage="true" isSummaryWithPageHeaderAndFooter="true"> |
---|
| 3 | <property name="ireport.scriptlethandling" value="0"/> |
---|
| 4 | <property name="ireport.encoding" value="UTF-8"/> |
---|
| 5 | <property name="ireport.zoom" value="1.0"/> |
---|
| 6 | <property name="ireport.x" value="0"/> |
---|
[682] | 7 | <property name="ireport.y" value="1109"/> |
---|
[544] | 8 | <import value="net.sf.jasperreports.engine.*"/> |
---|
[542] | 9 | <import value="java.util.*"/> |
---|
| 10 | <import value="net.sf.jasperreports.engine.data.*"/> |
---|
| 11 | <style name="Crosstab Data Text" isDefault="false" hAlign="Center"/> |
---|
| 12 | <style name="table" isDefault="false" fill="Solid" fontSize="12" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false"> |
---|
| 13 | <box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0"> |
---|
| 14 | <pen lineWidth="0.0" lineColor="#000000"/> |
---|
| 15 | <topPen lineWidth="0.0"/> |
---|
| 16 | <leftPen lineWidth="0.0"/> |
---|
| 17 | <bottomPen lineWidth="0.0"/> |
---|
| 18 | <rightPen lineWidth="0.0"/> |
---|
| 19 | </box> |
---|
| 20 | </style> |
---|
| 21 | <style name="table_TH" isDefault="false" mode="Opaque" backcolor="#C7C7C7" fontSize="12" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false"> |
---|
| 22 | <box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0"> |
---|
| 23 | <pen lineWidth="1.0" lineColor="#000000"/> |
---|
| 24 | <topPen lineWidth="1.0"/> |
---|
| 25 | <leftPen lineWidth="0.0"/> |
---|
| 26 | <bottomPen lineWidth="1.0"/> |
---|
| 27 | <rightPen lineWidth="0.0"/> |
---|
| 28 | </box> |
---|
| 29 | </style> |
---|
| 30 | <style name="table_CH" isDefault="false" mode="Opaque" backcolor="#FFFFFF" fontSize="12" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false"> |
---|
| 31 | <box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0"> |
---|
| 32 | <pen lineWidth="1.0" lineColor="#000000"/> |
---|
| 33 | <topPen lineWidth="0.0"/> |
---|
| 34 | <leftPen lineWidth="0.0"/> |
---|
| 35 | <bottomPen lineWidth="1.0"/> |
---|
| 36 | <rightPen lineWidth="0.0"/> |
---|
| 37 | </box> |
---|
| 38 | </style> |
---|
| 39 | <style name="table_TD" isDefault="false" mode="Opaque" backcolor="#FFFFFF" fontSize="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false"> |
---|
| 40 | <box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0"> |
---|
| 41 | <pen lineWidth="1.0" lineColor="#000000"/> |
---|
| 42 | <topPen lineWidth="1.0"/> |
---|
| 43 | <leftPen lineWidth="0.0"/> |
---|
| 44 | <bottomPen lineWidth="1.0"/> |
---|
| 45 | <rightPen lineWidth="0.0"/> |
---|
| 46 | </box> |
---|
| 47 | <conditionalStyle> |
---|
| 48 | <conditionExpression><![CDATA[new Boolean($V{REPORT_COUNT}.intValue()%2==0)]]></conditionExpression> |
---|
| 49 | <style isDefault="false" style="table_TD" backcolor="#F7F7F7"/> |
---|
| 50 | </conditionalStyle> |
---|
| 51 | </style> |
---|
| 52 | <style name="table_CF" isDefault="false" mode="Opaque" backcolor="#EDEDED" fontSize="12" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false"> |
---|
| 53 | <box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0"> |
---|
| 54 | <pen lineWidth="1.0"/> |
---|
| 55 | <topPen lineWidth="1.0"/> |
---|
| 56 | <leftPen lineWidth="0.0"/> |
---|
| 57 | <bottomPen lineWidth="1.0"/> |
---|
| 58 | <rightPen lineWidth="0.0"/> |
---|
| 59 | </box> |
---|
| 60 | </style> |
---|
| 61 | <subDataset name="dataset1"> |
---|
| 62 | <field name="id" class="java.lang.Long"/> |
---|
| 63 | <field name="name" class="java.lang.String"/> |
---|
| 64 | <field name="immediateCalloutCount" class="java.lang.Integer"/> |
---|
| 65 | <field name="downTime" class="java.lang.Integer"/> |
---|
[544] | 66 | <field name="tasks" class="java.lang.String"/> |
---|
[542] | 67 | <variable name="immediateCalloutSum" class="java.lang.Integer" calculation="Sum"> |
---|
| 68 | <variableExpression><![CDATA[$F{immediateCalloutCount}]]></variableExpression> |
---|
| 69 | </variable> |
---|
[544] | 70 | <variable name="downTimeSum" class="java.lang.Integer" calculation="Sum"> |
---|
| 71 | <variableExpression><![CDATA[$F{downTime}]]></variableExpression> |
---|
| 72 | </variable> |
---|
[542] | 73 | <group name="assetName"> |
---|
| 74 | <groupExpression><![CDATA[$F{name}]]></groupExpression> |
---|
| 75 | </group> |
---|
| 76 | </subDataset> |
---|
| 77 | <parameter name="reportTitle" class="java.lang.String"/> |
---|
| 78 | <parameter name="currentUser" class="java.lang.String"/> |
---|
| 79 | <parameter name="logoUrl" class="java.lang.String"/> |
---|
| 80 | <parameter name="startDateString" class="java.lang.String"/> |
---|
| 81 | <parameter name="endDateString" class="java.lang.String"/> |
---|
[545] | 82 | <queryString language="SQL"> |
---|
[542] | 83 | <![CDATA[]]> |
---|
| 84 | </queryString> |
---|
| 85 | <field name="taskList" class="java.util.List"/> |
---|
| 86 | <field name="summaryOfCalculationMethod" class="java.lang.String"/> |
---|
| 87 | <field name="totalAssetsOnTasksCount" class="java.lang.String"/> |
---|
| 88 | <field name="assetList" class="java.util.List"/> |
---|
[544] | 89 | <field name="totalDownTime" class="java.util.LinkedHashMap"/> |
---|
[542] | 90 | <background> |
---|
| 91 | <band splitType="Stretch"/> |
---|
| 92 | </background> |
---|
| 93 | <pageHeader> |
---|
| 94 | <band height="121" splitType="Stretch"> |
---|
| 95 | <textField> |
---|
| 96 | <reportElement key="staticText-1" x="0" y="57" width="340" height="30"/> |
---|
| 97 | <textElement textAlignment="Center" verticalAlignment="Top" markup="none"> |
---|
[682] | 98 | <font fontName="Serif" size="20"/> |
---|
[542] | 99 | </textElement> |
---|
| 100 | <textFieldExpression class="java.lang.String"><![CDATA[$P{reportTitle}]]></textFieldExpression> |
---|
| 101 | </textField> |
---|
| 102 | <image> |
---|
| 103 | <reportElement x="0" y="0" width="340" height="57"/> |
---|
| 104 | <imageExpression class="java.net.URL"><![CDATA[new URL($P{logoUrl})]]></imageExpression> |
---|
| 105 | </image> |
---|
| 106 | <textField pattern="dd-MMM-yyyy" isBlankWhenNull="true"> |
---|
| 107 | <reportElement x="0" y="87" width="340" height="20"/> |
---|
[682] | 108 | <textElement textAlignment="Center" verticalAlignment="Middle" markup="none"> |
---|
| 109 | <font fontName="Serif"/> |
---|
| 110 | </textElement> |
---|
[542] | 111 | <textFieldExpression class="java.lang.String"><![CDATA[$P{startDateString}+" to "+$P{endDateString}]]></textFieldExpression> |
---|
| 112 | </textField> |
---|
| 113 | </band> |
---|
| 114 | </pageHeader> |
---|
| 115 | <columnHeader> |
---|
| 116 | <band splitType="Stretch"/> |
---|
| 117 | </columnHeader> |
---|
| 118 | <detail> |
---|
| 119 | <band height="394" splitType="Stretch"> |
---|
| 120 | <bar3DChart> |
---|
| 121 | <chart> |
---|
[544] | 122 | <reportElement x="0" y="0" width="782" height="394"/> |
---|
| 123 | <chartTitle position="Bottom"> |
---|
| 124 | <font isUnderline="false"/> |
---|
| 125 | <titleExpression><![CDATA["Total: "+$F{totalAssetsOnTasksCount}]]></titleExpression> |
---|
| 126 | </chartTitle> |
---|
[542] | 127 | <chartSubtitle/> |
---|
| 128 | <chartLegend/> |
---|
| 129 | </chart> |
---|
| 130 | <categoryDataset> |
---|
| 131 | <dataset> |
---|
| 132 | <datasetRun subDataset="dataset1"> |
---|
| 133 | <dataSourceExpression><![CDATA[new net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{assetList})]]></dataSourceExpression> |
---|
| 134 | </datasetRun> |
---|
| 135 | </dataset> |
---|
| 136 | <categorySeries> |
---|
| 137 | <seriesExpression><![CDATA["Immediate Callouts"]]></seriesExpression> |
---|
| 138 | <categoryExpression><![CDATA[$F{name}]]></categoryExpression> |
---|
| 139 | <valueExpression><![CDATA[$F{immediateCalloutCount}]]></valueExpression> |
---|
| 140 | </categorySeries> |
---|
| 141 | </categoryDataset> |
---|
| 142 | <bar3DPlot isShowLabels="true"> |
---|
| 143 | <plot labelRotation="-60.0"/> |
---|
| 144 | <itemLabel color="#000000" backgroundColor="#FFFFFF"/> |
---|
| 145 | <categoryAxisFormat labelRotation="-60.0"> |
---|
| 146 | <axisFormat> |
---|
| 147 | <labelFont/> |
---|
| 148 | <tickLabelFont/> |
---|
| 149 | </axisFormat> |
---|
| 150 | </categoryAxisFormat> |
---|
| 151 | <valueAxisFormat> |
---|
| 152 | <axisFormat> |
---|
| 153 | <labelFont/> |
---|
| 154 | <tickLabelFont/> |
---|
| 155 | </axisFormat> |
---|
| 156 | </valueAxisFormat> |
---|
| 157 | </bar3DPlot> |
---|
| 158 | </bar3DChart> |
---|
[544] | 159 | </band> |
---|
| 160 | <band height="394"> |
---|
[542] | 161 | <bar3DChart> |
---|
| 162 | <chart> |
---|
[544] | 163 | <reportElement x="0" y="0" width="782" height="394"/> |
---|
| 164 | <chartTitle position="Bottom"> |
---|
| 165 | <font isBold="false" isUnderline="false"/> |
---|
| 166 | <titleExpression><![CDATA["Total: "+$F{totalDownTime}.total+"min"+" ("+$F{totalDownTime}.hours+"h:"+$F{totalDownTime}.minutes+"m)"]]></titleExpression> |
---|
| 167 | </chartTitle> |
---|
[542] | 168 | <chartSubtitle/> |
---|
[544] | 169 | <chartLegend position="Bottom"> |
---|
| 170 | <font isUnderline="true"/> |
---|
| 171 | </chartLegend> |
---|
[542] | 172 | </chart> |
---|
| 173 | <categoryDataset> |
---|
| 174 | <dataset> |
---|
| 175 | <datasetRun subDataset="dataset1"> |
---|
| 176 | <dataSourceExpression><![CDATA[new net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{assetList})]]></dataSourceExpression> |
---|
| 177 | </datasetRun> |
---|
| 178 | </dataset> |
---|
| 179 | <categorySeries> |
---|
[544] | 180 | <seriesExpression><![CDATA["Down Time (min)"]]></seriesExpression> |
---|
[542] | 181 | <categoryExpression><![CDATA[$F{name}]]></categoryExpression> |
---|
| 182 | <valueExpression><![CDATA[$F{downTime}]]></valueExpression> |
---|
| 183 | </categorySeries> |
---|
| 184 | </categoryDataset> |
---|
| 185 | <bar3DPlot isShowLabels="true"> |
---|
| 186 | <plot labelRotation="-60.0"> |
---|
| 187 | <seriesColor seriesOrder="0" color="#FF9900"/> |
---|
| 188 | </plot> |
---|
| 189 | <itemLabel color="#000000" backgroundColor="#FFFFFF"/> |
---|
| 190 | <categoryAxisFormat labelRotation="-60.0"> |
---|
| 191 | <axisFormat> |
---|
| 192 | <labelFont/> |
---|
| 193 | <tickLabelFont/> |
---|
| 194 | </axisFormat> |
---|
| 195 | </categoryAxisFormat> |
---|
| 196 | <valueAxisFormat> |
---|
| 197 | <axisFormat> |
---|
| 198 | <labelFont/> |
---|
| 199 | <tickLabelFont/> |
---|
| 200 | </axisFormat> |
---|
| 201 | </valueAxisFormat> |
---|
| 202 | </bar3DPlot> |
---|
| 203 | </bar3DChart> |
---|
| 204 | </band> |
---|
[544] | 205 | <band height="394"> |
---|
| 206 | <componentElement> |
---|
| 207 | <reportElement key="table 1" style="table" x="0" y="0" width="782" height="394"/> |
---|
| 208 | <jr:table xmlns:jr="http://jasperreports.sourceforge.net/jasperreports/components" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports/components http://jasperreports.sourceforge.net/xsd/components.xsd"> |
---|
| 209 | <datasetRun subDataset="dataset1"> |
---|
| 210 | <dataSourceExpression><![CDATA[new net.sf.jasperreports.engine.data.JRBeanCollectionDataSource($F{assetList})]]></dataSourceExpression> |
---|
| 211 | </datasetRun> |
---|
| 212 | <jr:column width="774"> |
---|
| 213 | <jr:groupHeader groupName="assetName"> |
---|
| 214 | <jr:cell height="30" rowSpan="1"> |
---|
| 215 | <textField> |
---|
| 216 | <reportElement x="0" y="0" width="774" height="30"/> |
---|
| 217 | <textElement verticalAlignment="Middle"> |
---|
| 218 | <font size="12" isBold="true"/> |
---|
| 219 | </textElement> |
---|
| 220 | <textFieldExpression class="java.lang.String"><![CDATA[$F{name}]]></textFieldExpression> |
---|
| 221 | </textField> |
---|
| 222 | </jr:cell> |
---|
| 223 | </jr:groupHeader> |
---|
| 224 | <jr:detailCell style="table_TD" height="40" rowSpan="1"> |
---|
| 225 | <textField isStretchWithOverflow="true"> |
---|
| 226 | <reportElement x="0" y="0" width="774" height="40"/> |
---|
| 227 | <textElement verticalAlignment="Middle"/> |
---|
| 228 | <textFieldExpression class="java.lang.String"><![CDATA[""+$F{tasks}]]></textFieldExpression> |
---|
| 229 | </textField> |
---|
| 230 | </jr:detailCell> |
---|
| 231 | </jr:column> |
---|
| 232 | </jr:table> |
---|
| 233 | </componentElement> |
---|
| 234 | </band> |
---|
[542] | 235 | </detail> |
---|
| 236 | <columnFooter> |
---|
| 237 | <band splitType="Stretch"/> |
---|
| 238 | </columnFooter> |
---|
| 239 | <pageFooter> |
---|
| 240 | <band height="40" splitType="Stretch"> |
---|
| 241 | <textField pattern="dd-MMM-yyyy"> |
---|
| 242 | <reportElement x="82" y="0" width="200" height="20"/> |
---|
[682] | 243 | <textElement> |
---|
| 244 | <font fontName="Serif"/> |
---|
| 245 | </textElement> |
---|
[542] | 246 | <textFieldExpression class="java.util.Date"><![CDATA[new java.util.Date()]]></textFieldExpression> |
---|
| 247 | </textField> |
---|
| 248 | <textField> |
---|
| 249 | <reportElement x="662" y="20" width="80" height="20"/> |
---|
[682] | 250 | <textElement textAlignment="Right"> |
---|
| 251 | <font fontName="Serif"/> |
---|
| 252 | </textElement> |
---|
[542] | 253 | <textFieldExpression class="java.lang.String"><![CDATA["Page "+$V{PAGE_NUMBER}+" of"]]></textFieldExpression> |
---|
| 254 | </textField> |
---|
| 255 | <textField evaluationTime="Report"> |
---|
| 256 | <reportElement x="742" y="20" width="40" height="20"/> |
---|
[682] | 257 | <textElement> |
---|
| 258 | <font fontName="Serif"/> |
---|
| 259 | </textElement> |
---|
[542] | 260 | <textFieldExpression class="java.lang.String"><![CDATA[" " + $V{PAGE_NUMBER}]]></textFieldExpression> |
---|
| 261 | </textField> |
---|
| 262 | <textField> |
---|
| 263 | <reportElement x="0" y="0" width="82" height="20"/> |
---|
[682] | 264 | <textElement markup="none"> |
---|
| 265 | <font fontName="Serif"/> |
---|
| 266 | </textElement> |
---|
[542] | 267 | <textFieldExpression class="java.lang.String"><![CDATA["Generated: "]]></textFieldExpression> |
---|
| 268 | </textField> |
---|
| 269 | <textField> |
---|
| 270 | <reportElement x="82" y="20" width="200" height="20"/> |
---|
[682] | 271 | <textElement markup="none"> |
---|
| 272 | <font fontName="Serif"/> |
---|
| 273 | </textElement> |
---|
[542] | 274 | <textFieldExpression class="java.lang.String"><![CDATA[$P{currentUser}]]></textFieldExpression> |
---|
| 275 | </textField> |
---|
| 276 | <textField> |
---|
| 277 | <reportElement x="0" y="20" width="82" height="20"/> |
---|
[682] | 278 | <textElement markup="none"> |
---|
| 279 | <font fontName="Serif"/> |
---|
| 280 | </textElement> |
---|
[542] | 281 | <textFieldExpression class="java.lang.String"><![CDATA["By: "]]></textFieldExpression> |
---|
| 282 | </textField> |
---|
| 283 | </band> |
---|
| 284 | </pageFooter> |
---|
| 285 | <lastPageFooter> |
---|
| 286 | <band height="40"> |
---|
| 287 | <textField evaluationTime="Report"> |
---|
| 288 | <reportElement x="742" y="20" width="40" height="20"/> |
---|
[682] | 289 | <textElement> |
---|
| 290 | <font fontName="Serif"/> |
---|
| 291 | </textElement> |
---|
[542] | 292 | <textFieldExpression class="java.lang.String"><![CDATA[" " + $V{PAGE_NUMBER}]]></textFieldExpression> |
---|
| 293 | </textField> |
---|
| 294 | <textField pattern="dd-MMM-yyyy"> |
---|
| 295 | <reportElement x="82" y="0" width="200" height="20"/> |
---|
[682] | 296 | <textElement> |
---|
| 297 | <font fontName="Serif"/> |
---|
| 298 | </textElement> |
---|
[542] | 299 | <textFieldExpression class="java.util.Date"><![CDATA[new java.util.Date()]]></textFieldExpression> |
---|
| 300 | </textField> |
---|
| 301 | <textField> |
---|
| 302 | <reportElement x="0" y="0" width="82" height="20"/> |
---|
[682] | 303 | <textElement markup="none"> |
---|
| 304 | <font fontName="Serif"/> |
---|
| 305 | </textElement> |
---|
[542] | 306 | <textFieldExpression class="java.lang.String"><![CDATA["Generated: "]]></textFieldExpression> |
---|
| 307 | </textField> |
---|
| 308 | <textField> |
---|
| 309 | <reportElement x="0" y="20" width="82" height="20"/> |
---|
[682] | 310 | <textElement markup="none"> |
---|
| 311 | <font fontName="Serif"/> |
---|
| 312 | </textElement> |
---|
[542] | 313 | <textFieldExpression class="java.lang.String"><![CDATA["By: "]]></textFieldExpression> |
---|
| 314 | </textField> |
---|
| 315 | <textField> |
---|
| 316 | <reportElement x="82" y="20" width="200" height="20"/> |
---|
[682] | 317 | <textElement markup="none"> |
---|
| 318 | <font fontName="Serif"/> |
---|
| 319 | </textElement> |
---|
[542] | 320 | <textFieldExpression class="java.lang.String"><![CDATA[$P{currentUser}]]></textFieldExpression> |
---|
| 321 | </textField> |
---|
| 322 | <textField> |
---|
| 323 | <reportElement x="662" y="20" width="80" height="20"/> |
---|
[682] | 324 | <textElement textAlignment="Right"> |
---|
| 325 | <font fontName="Serif"/> |
---|
| 326 | </textElement> |
---|
[542] | 327 | <textFieldExpression class="java.lang.String"><![CDATA["Page "+$V{PAGE_NUMBER}+" of"]]></textFieldExpression> |
---|
| 328 | </textField> |
---|
| 329 | </band> |
---|
| 330 | </lastPageFooter> |
---|
| 331 | <summary> |
---|
| 332 | <band height="369"> |
---|
| 333 | <textField> |
---|
| 334 | <reportElement key="staticText-1" x="221" y="12" width="340" height="30"/> |
---|
| 335 | <textElement textAlignment="Center" verticalAlignment="Top" markup="none"> |
---|
[682] | 336 | <font fontName="Serif" size="20"/> |
---|
[542] | 337 | </textElement> |
---|
| 338 | <textFieldExpression class="java.lang.String"><![CDATA["Summary of Calculation Method"]]></textFieldExpression> |
---|
| 339 | </textField> |
---|
| 340 | <textField> |
---|
| 341 | <reportElement x="0" y="50" width="782" height="311"/> |
---|
[682] | 342 | <textElement> |
---|
| 343 | <font fontName="Serif"/> |
---|
| 344 | </textElement> |
---|
[542] | 345 | <textFieldExpression class="java.lang.String"><![CDATA[$F{summaryOfCalculationMethod}]]></textFieldExpression> |
---|
| 346 | </textField> |
---|
| 347 | </band> |
---|
| 348 | </summary> |
---|
| 349 | <noData> |
---|
| 350 | <band height="85" splitType="Stretch"> |
---|
| 351 | <textField> |
---|
| 352 | <reportElement x="0" y="35" width="782" height="50"/> |
---|
| 353 | <textElement textAlignment="Center" markup="none"> |
---|
[682] | 354 | <font fontName="Serif" size="14" isBold="true"/> |
---|
[542] | 355 | </textElement> |
---|
| 356 | <textFieldExpression class="java.lang.String"><![CDATA["No data to display. \n"+ |
---|
| 357 | "Please run report again."]]></textFieldExpression> |
---|
| 358 | </textField> |
---|
| 359 | <textField> |
---|
| 360 | <reportElement key="staticText-1" x="0" y="0" width="782" height="35"/> |
---|
| 361 | <textElement textAlignment="Center" markup="none"> |
---|
[682] | 362 | <font fontName="Serif" size="20"/> |
---|
[542] | 363 | </textElement> |
---|
| 364 | <textFieldExpression class="java.lang.String"><![CDATA[$P{reportTitle}]]></textFieldExpression> |
---|
| 365 | </textField> |
---|
| 366 | </band> |
---|
| 367 | </noData> |
---|
| 368 | </jasperReport> |
---|