比较好用的一个jaspereport模板 生成html页面模板

<?xml version="1.0" encoding="UTF-8"?>
<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="groupOpenReport" pageWidth="759" pageHeight="566" orientation="Landscape" whenNoDataType="AllSectionsNoDetail" columnWidth="759" leftMargin="0" rightMargin="0" topMargin="0" bottomMargin="0" resourceBundle="ApplicationResources" isIgnorePagination="true">
 <property name="ireport.scriptlethandling" value="0"/>
 <property name="ireport.encoding" value="UTF-8"/>
 <import value="java.util.*"/>
 <import value="net.sf.jasperreports.engine.*"/>
 <import value="net.sf.jasperreports.engine.data.*"/>
 <field name="monthTotal" class="java.lang.String">
  <fieldDescription><![CDATA[monthTotal]]></fieldDescription>
 </field>
 <field name="addGroupTotal" class="java.lang.String">
  <fieldDescription><![CDATA[addGroupTotal]]></fieldDescription>
 </field>
 <field name="addUserTotal" class="java.lang.String">
  <fieldDescription><![CDATA[addUserTotal]]></fieldDescription>
 </field>
 <field name="groupTotal" class="java.lang.String">
  <fieldDescription><![CDATA[groupTotal]]></fieldDescription>
 </field>
 <field name="userTotal" class="java.lang.String">
  <fieldDescription><![CDATA[userTotal]]></fieldDescription>
 </field>
 <background>
  <band/>
 </background>
 <title>
  <band/>
 </title>
 <pageHeader>
  <band/>
 </pageHeader>
 <columnHeader>
  <band height="20">
   <textField isBlankWhenNull="false">
    <reportElement key="textField-1" stretchType="RelativeToBandHeight" mode="Opaque" x="0" y="0" width="138" height="20" forecolor="#165E9E" backcolor="#E2EDF6"/>
    <box>
     <pen lineWidth="0.0" lineColor="#99CCFF"/>
     <topPen lineWidth="0.25" lineColor="#99CCFF"/>
     <leftPen lineWidth="0.25" lineColor="#99CCFF"/>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.25" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$R{adc.group.open.report.date}]]></textFieldExpression>
   </textField>
   <textField isBlankWhenNull="false">
    <reportElement key="textField-2" stretchType="RelativeToBandHeight" mode="Opaque" x="138" y="0" width="139" height="20" forecolor="#165E9E" backcolor="#E2EDF6"/>
    <box>
     <topPen lineWidth="0.75" lineColor="#99CCFF"/>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.75" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$R{adc.group.open.report.group.total}]]></textFieldExpression>
   </textField>
   <textField isBlankWhenNull="false">
    <reportElement key="textField-3" stretchType="RelativeToBandHeight" mode="Opaque" x="277" y="0" width="163" height="20" forecolor="#165E9E" backcolor="#E2EDF6"/>
    <box>
     <pen lineWidth="0.25"/>
     <topPen lineWidth="0.25" lineColor="#99CCFF"/>
     <leftPen lineWidth="0.0"/>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.25" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$R{adc.group.open.report.user.total}]]></textFieldExpression>
   </textField>
   <textField isStretchWithOverflow="true" isBlankWhenNull="false">
    <reportElement key="textField-4" stretchType="RelativeToBandHeight" mode="Opaque" x="440" y="0" width="164" height="20" forecolor="#165E9E" backcolor="#E2EDF6"/>
    <box>
     <topPen lineWidth="0.25" lineColor="#99CCFF"/>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.25" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$R{adc.group.open.report.add.group.num}]]></textFieldExpression>
   </textField>
   <textField isStretchWithOverflow="true" isBlankWhenNull="false">
    <reportElement key="textField-5" stretchType="RelativeToBandHeight" mode="Opaque" x="604" y="0" width="155" height="20" forecolor="#165E9E" backcolor="#E2EDF6"/>
    <box>
     <topPen lineWidth="0.25" lineColor="#99CCFF"/>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.25" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$R{adc.group.open.report.add.user.num}]]></textFieldExpression>
   </textField>
  </band>
 </columnHeader>
 <detail>
  <band height="20">
   <textField isBlankWhenNull="false">
    <reportElement key="textField" x="0" y="0" width="138" height="20"/>
    <box>
     <pen lineWidth="0.0" lineColor="#99CCFF"/>
     <topPen lineWidth="0.0" lineColor="#99CCFF"/>
     <leftPen lineWidth="0.25" lineColor="#99CCFF"/>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.25" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$F{monthTotal}]]></textFieldExpression>
   </textField>
   <textField isStretchWithOverflow="true" isBlankWhenNull="false">
    <reportElement key="textField" stretchType="RelativeToBandHeight" x="440" y="0" width="164" height="20"/>
    <box>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.25" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$F{addGroupTotal}]]></textFieldExpression>
   </textField>
   <textField isStretchWithOverflow="true" isBlankWhenNull="false">
    <reportElement key="textField" stretchType="RelativeToBandHeight" x="604" y="0" width="155" height="20"/>
    <box>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.25" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$F{addUserTotal}]]></textFieldExpression>
   </textField>
   <textField isBlankWhenNull="false">
    <reportElement key="textField" x="138" y="0" width="139" height="20"/>
    <box>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.25" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$F{groupTotal}]]></textFieldExpression>
   </textField>
   <textField isStretchWithOverflow="true" isBlankWhenNull="false">
    <reportElement key="textField" stretchType="RelativeToBandHeight" x="277" y="0" width="163" height="20"/>
    <box>
     <bottomPen lineWidth="0.25" lineColor="#99CCFF"/>
     <rightPen lineWidth="0.25" lineColor="#99CCFF"/>
    </box>
    <textElement textAlignment="Center">
     <font fontName="宋体" size="12"/>
    </textElement>
    <textFieldExpression class="java.lang.String"><![CDATA[$F{userTotal}]]></textFieldExpression>
   </textField>
  </band>
 </detail>
 <columnFooter>
  <band/>
 </columnFooter>
 <pageFooter>
  <band/>
 </pageFooter>
 <summary>
  <band/>
 </summary>
</jasperReport>

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值