dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #13753
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 4494: Codestyle
------------------------------------------------------------
revno: 4494
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2011-08-31 22:12:31 +0200
message:
Codestyle
modified:
dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/reporttable/impl/DefaultReportTableService.java
--
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-services/dhis-service-reporting/src/main/java/org/hisp/dhis/reporttable/impl/DefaultReportTableService.java'
--- dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/reporttable/impl/DefaultReportTableService.java 2011-07-21 03:29:35 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/reporttable/impl/DefaultReportTableService.java 2011-08-31 20:12:31 +0000
@@ -464,19 +464,14 @@
// Headers
// ---------------------------------------------------------------------
- for ( String column : reportTable.getIndexColumns() )
+ for ( String column : reportTable.getIndexColumns() ) // Index columns
{
- grid
- .addHeader( new GridHeader( PRETTY_COLUMNS.get( column ), column, Integer.class.getName(), true, true ) ); // Index
- // columns
+ grid.addHeader( new GridHeader( PRETTY_COLUMNS.get( column ), column, Integer.class.getName(), true, true ) );
}
- for ( String column : reportTable.getIndexNameColumns() )
+ for ( String column : reportTable.getIndexNameColumns() ) // Index name columns
{
- grid
- .addHeader( new GridHeader( PRETTY_COLUMNS.get( column ), column, String.class.getName(), false, true ) ); // Index
- // name
- // columns
+ grid.addHeader( new GridHeader( PRETTY_COLUMNS.get( column ), column, String.class.getName(), false, true ) );
}
grid.addHeader( new GridHeader( PRETTY_COLUMNS.get( REPORTING_MONTH_COLUMN_NAME ), REPORTING_MONTH_COLUMN_NAME,
@@ -515,23 +510,23 @@
{
grid.addRow();
- for ( IdentifiableObject object : row )
+ for ( IdentifiableObject object : row ) // Index columns
{
- grid.addValue( object.getId() ); // Index columns
+ grid.addValue( object.getId() );
}
- for ( NameableObject object : row )
+ for ( NameableObject object : row ) // Index name columns
{
- grid.addValue( object.getShortName() ); // Index name columns
+ grid.addValue( object.getShortName() );
}
grid.addValue( reportTable.getReportingMonthName() );
grid.addValue( reportTable.getOrganisationUnitName() );
grid.addValue( isCurrentParent( row ) ? YES : NO );
- for ( List<NameableObject> column : reportTable.getColumns() )
+ for ( List<NameableObject> column : reportTable.getColumns() ) // Values
{
- grid.addValue( map.get( getIdentifier( row, column ) ) ); // Values
+ grid.addValue( map.get( getIdentifier( row, column ) ) );
}
if ( reportTable.doSubTotals() )
@@ -545,18 +540,12 @@
if ( reportTable.doTotal() )
{
- grid.addValue( map.get( getIdentifier( row ) ) ); // Only
- // category
- // option
- // combo is
- // crosstab
- // when
- // total,
- // row
- // identifier
- // will
- // return
- // total
+ // -------------------------------------------------------------
+ // Only category option combo is crosstab when total, row
+ // identifier will return total
+ // -------------------------------------------------------------
+
+ grid.addValue( map.get( getIdentifier( row ) ) );
}
}