dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #19359
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 8409: Donnot display total of records in program summary report.
------------------------------------------------------------
revno: 8409
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Sat 2012-10-06 22:13:30 +0700
message:
Donnot display total of records in program summary report.
modified:
dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateReportAction.java
dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/report.vm
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateReportAction.java'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateReportAction.java 2012-09-06 03:50:03 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/java/org/hisp/dhis/caseentry/action/report/GenerateReportAction.java 2012-10-06 15:13:30 +0000
@@ -160,6 +160,13 @@
return program;
}
+ private int total;
+
+ public int getTotal()
+ {
+ return total;
+ }
+
// -------------------------------------------------------------------------
// Action implementation
// -------------------------------------------------------------------------
@@ -193,14 +200,15 @@
else
{
orgunitIds.add( organisationUnit.getId() );
- orgunitIds.addAll( organisationUnitService.getOrganisationUnitHierarchy().getChildren( organisationUnit.getId() ) );
+ orgunitIds.addAll( organisationUnitService.getOrganisationUnitHierarchy().getChildren(
+ organisationUnit.getId() ) );
}
// ---------------------------------------------------------------------
// Program instances for the selected program
// ---------------------------------------------------------------------
- int total = programInstanceService.countProgramInstances( program, organisationUnit, sDate, eDate );
+ total = programInstanceService.countProgramInstances( program, organisationUnit, sDate, eDate );
this.paging = createPaging( total );
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/report.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/report.vm 2012-09-11 09:52:55 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/report.vm 2012-10-06 15:13:30 +0000
@@ -9,7 +9,13 @@
<td class='text-column' >$i18n.getString( "total_result" )</td>
<td> </td>
<td> </td>
- <td>$!total</td>
+ <td>
+ #if($!total)
+ $total
+ #else
+ 0
+ #end
+ </td>
</tr>
</table>
@@ -67,9 +73,8 @@
</table>
<div id="viewRecordsDiv"></div>
-#else
- <h4>$i18n.getString('no_result_found')</h4>
#end
+
<script>
var i18n_patient_details_and_history = '$encoder.jsEscape( $i18n.getString( "patient_details_and_history" ) , "'" )';
var i18n_records_for = '$encoder.jsEscape( $i18n.getString( "records_for" ) , "'" )';