dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #02592
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 872: remove un-used paramater
------------------------------------------------------------
revno: 872
committer: Tran Thanh Tri <Tran Thanh Tri@compaq>
branch nick: trunk
timestamp: Fri 2009-10-16 16:22:36 +0700
message:
remove un-used paramater
modified:
dhis-2/dhis-api/src/main/java/org/hisp/dhis/reportexcel/ReportExcel.java
dhis-2/dhis-web/dhis-web-excel-reporting/pom.xml
dhis-2/dhis-web/dhis-web-excel-reporting/src/main/java/org/hisp/dhis/reportexcel/dataentrystatus/action/DefaultDataEntryStatusAction.java
dhis-2/dhis-web/dhis-web-excel-reporting/src/main/resources/struts.xml
dhis-2/dhis-web/pom.xml
--
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-api/src/main/java/org/hisp/dhis/reportexcel/ReportExcel.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/reportexcel/ReportExcel.java 2009-09-25 06:10:21 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/reportexcel/ReportExcel.java 2009-10-16 09:22:36 +0000
@@ -28,8 +28,8 @@
import java.util.HashSet;
import java.util.Set;
+
import org.hisp.dhis.organisationunit.OrganisationUnit;
-import org.hisp.dhis.user.UserAuthorityGroup;
/**
* @author Tran Thanh Tri
@@ -66,22 +66,6 @@
super();
}
- public ReportExcel( String name, String excelTemplateFile, int periodRow, int periodColumn, int organisationRow,
- int organisationColumn, Set<ReportExcelItem> reportExcelItems, Set<OrganisationUnit> organisationAssocitions,
- Set<UserAuthorityGroup> userRoles, String group )
- {
- super();
- this.name = name;
- this.excelTemplateFile = excelTemplateFile;
- this.periodRow = periodRow;
- this.periodColumn = periodColumn;
- this.organisationRow = organisationRow;
- this.organisationColumn = organisationColumn;
- this.reportExcelItems = reportExcelItems;
- this.organisationAssocitions = organisationAssocitions;
- this.group = group;
- }
-
public ReportExcelItem getReportExcelItem( String name )
{
for ( ReportExcelItem reportExcelItem : this.reportExcelItems )
=== modified file 'dhis-2/dhis-web/dhis-web-excel-reporting/pom.xml'
--- dhis-2/dhis-web/dhis-web-excel-reporting/pom.xml 2009-09-19 11:00:10 +0000
+++ dhis-2/dhis-web/dhis-web-excel-reporting/pom.xml 2009-10-16 09:22:36 +0000
@@ -10,7 +10,7 @@
</parent>
<artifactId>dhis-web-excel-reporting</artifactId>
- <packaging>war</packaging>
+ <packaging>jar</packaging>
<name>DHIS Web Excel Reporting</name>
<build>
=== modified file 'dhis-2/dhis-web/dhis-web-excel-reporting/src/main/java/org/hisp/dhis/reportexcel/dataentrystatus/action/DefaultDataEntryStatusAction.java'
--- dhis-2/dhis-web/dhis-web-excel-reporting/src/main/java/org/hisp/dhis/reportexcel/dataentrystatus/action/DefaultDataEntryStatusAction.java 2009-09-17 15:02:10 +0000
+++ dhis-2/dhis-web/dhis-web-excel-reporting/src/main/java/org/hisp/dhis/reportexcel/dataentrystatus/action/DefaultDataEntryStatusAction.java 2009-10-16 09:22:36 +0000
@@ -40,6 +40,7 @@
import org.hisp.dhis.dataset.DataSet;
import org.hisp.dhis.dataset.DataSetService;
import org.hisp.dhis.i18n.I18nFormat;
+import org.hisp.dhis.organisationunit.OrganisationUnit;
import org.hisp.dhis.ouwt.manager.OrganisationUnitSelectionManager;
import org.hisp.dhis.period.Period;
import org.hisp.dhis.period.PeriodService;
@@ -92,6 +93,8 @@
private List<DataSet> dataSets;
+ private OrganisationUnit organisationUnit;
+
// -------------------------------------------------
// Getter & Setter
// -------------------------------------------------
@@ -101,6 +104,11 @@
this.dataSetService = dataSetService;
}
+ public OrganisationUnit getOrganisationUnit()
+ {
+ return organisationUnit;
+ }
+
public void setFormat( I18nFormat format )
{
this.format = format;
@@ -160,14 +168,13 @@
public String execute()
throws Exception
{
+ this.organisationUnit = selectionManager.getSelectedOrganisationUnit();
- if ( selectionManager.getSelectedOrganisationUnit() != null )
+ if ( organisationUnit != null )
{
TimeUtils.start();
- dataSets = new ArrayList<DataSet>( dataSetService.getDataSetsBySource( selectionManager
- .getSelectedOrganisationUnit() ) );
- TimeUtils.markHMS( "datasets" );
- TimeUtils.stop();
+ dataSets = new ArrayList<DataSet>( dataSetService.getDataSetsBySource( organisationUnit ) );
+
if ( !currentUserService.currentUserIsSuper() )
{
UserCredentials userCredentials = userStore.getUserCredentials( currentUserService.getCurrentUser() );
@@ -182,8 +189,7 @@
dataSets.retainAll( dataSetUserAuthorityGroups );
}
- dataStatus = new ArrayList<DataEntryStatus>( reportService
- .getDataEntryStatusDefaultByDataSets( dataSets ) );
+ dataStatus = new ArrayList<DataEntryStatus>( reportService.getDataEntryStatusDefaultByDataSets( dataSets ) );
maps = new HashMap<DataSet, List<DataEntryStatus>>();
@@ -207,11 +213,10 @@
dataStatusNew.setPeriod( p );
dataStatusNew.setNumberOfDataElement( d.getNumberOfDataElement() );
dataStatusNew.setNumberOfDataValue( reportService.countDataValueOfDataSet( d.getDataSet(),
- selectionManager.getSelectedOrganisationUnit(), p ) );
+ organisationUnit, p ) );
CompleteDataSetRegistration completeDataSetRegistration = completeDataSetRegistrationService
- .getCompleteDataSetRegistration( d.getDataSet(), p, selectionManager
- .getSelectedOrganisationUnit() );
+ .getCompleteDataSetRegistration( d.getDataSet(), p, organisationUnit );
dataStatusNew.setCompleted( (completeDataSetRegistration == null ? false : true) );
=== modified file 'dhis-2/dhis-web/dhis-web-excel-reporting/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-excel-reporting/src/main/resources/struts.xml 2009-10-16 07:19:35 +0000
+++ dhis-2/dhis-web/dhis-web-excel-reporting/src/main/resources/struts.xml 2009-10-16 09:22:36 +0000
@@ -530,7 +530,7 @@
<result name="success" type="velocity">/main.vm</result>
<param name="page">/dhis-web-excel-reporting/dataSetCompleteReportSelect.vm</param>
<param name="menu">/dhis-web-excel-reporting/menuWithTree.vm</param>
- <param name="menuTreeHeight">400</param>
+ <param name="menuTreeHeight">220</param>
<param name="javascripts">../dhis-web-commons/ouwt/ouwt.js,javascript/dataSetCompleted.js</param>
</action>
=== modified file 'dhis-2/dhis-web/pom.xml'
--- dhis-2/dhis-web/pom.xml 2009-09-26 05:31:47 +0000
+++ dhis-2/dhis-web/pom.xml 2009-10-16 09:22:36 +0000
@@ -25,8 +25,8 @@
<module>dhis-web-reporting</module>
<module>dhis-web-mapping</module>
<module>dhis-web-dashboard-integration</module>
- <module>dhis-web-excel-reporting</module>
- <module>dhis-web-portal</module>
+ <module>dhis-web-excel-reporting</module>
+ <!--<module>dhis-web-portal</module>-->
</modules>
<distributionManagement>