WebEnq

Online surveys and reporting

This project is maintained by Nivocer

Report generator

The management GUI consists of two parts:

Jrxml layout

Each reportElement is included as a subreport <subreportExpression>

Questions to be included are gathered in datasourceExpression.

<dataSourceExpression><![CDATA[new it.bisi.report.jasper.datasource.XformJRDataSource($P{DATA_LOCATION},$P{XFORM_LOCATION},$P{FORM_NAME} ,"g3-Opmerkingen",null, $P{SPLIT_QUESTION_ID}, $P{SPLIT_QUESTION_VALUE}).getRecords()]]></dataSourceExpression>
In addition to the parameters in the expression above, Zend adds parameters report_question_ids and group_question_id.

Example jrxml code

<subreport>

<reportElement positionType="Float" x="0" y="0" width="555" height="20" isRemoveLineWhenBlank="true"/>
<subreportParameter name="CUSTOMER">
<subreportParameterExpression><![CDATA[$P{CUSTOMER}]]></subreportParameterExpression>
</subreportParameter>
<subreportParameter name="DEFAULT_STYLE_FILE">
<subreportParameterExpression><![CDATA[$P{DEFAULT_STYLE_FILE}]]></subreportParameterExpression>
</subreportParameter>
<subreportParameter name="REPORT_RESOURCE_BUNDLE">
<subreportParameterExpression><![CDATA[$P{REPORT_RESOURCE_BUNDLE}]]></subreportParameterExpression>
</subreportParameter>
<subreportParameter name="Q_TEXT">
<subreportParameterExpression><![CDATA["<h1>Hi</h1><p>This is a <b>test</b></p><p>You can also use a report parameter: "+$P{CUSTOMER}]]>
</subreportParameterExpression>
</subreportParameter>
</subreport>
<dataSourceExpression><![CDATA[new net.sf.jasperreports.engine.JREmptyDataSource()]]></dataSourceExpression>
<subreportExpression><![CDATA[$P{SUBREPORT_DIR}+"report5-text.jasper"]]></subreportExpression>

Report characteristics

Report part characteristics

general

text

used for titles, introduction,

list answers (open)

a list of the answers given on one question

frequency/cross table

frequency table of the answers given on one question. If a grouping variable is set, for each group in that variable the frequencies (percentage) of the answer is displayed and a total is added

note: general info gives values and labels, data gives values.

mean table

Set of at least one question. The set has a title which is displayed above the table. The average of the (valid) answers are calculated. If a grouping variable is set, for each group in that variable the average of the answer is displayed and a total is added.

barchart mean

Set of questions presented in three columns: question text, bar chart graph and mean. The set has a title displayed above the table.