=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java 2011-12-22 09:50:44 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/RelativePeriods.java 2011-12-24 14:34:46 +0000
@@ -513,7 +513,7 @@
{
relatives.setLast12Months( true );
relatives.setLast4Quarters( true );
- relatives.setLastYear( true );
+ relatives.setThisYear( true );
}
else
{
@@ -521,7 +521,7 @@
relatives.setLast6BiMonths( periodTypes.contains( BiMonthlyPeriodType.NAME ) );
relatives.setLast4Quarters( periodTypes.contains( QuarterlyPeriodType.NAME ) );
relatives.setLast2SixMonths( periodTypes.contains( SixMonthlyPeriodType.NAME ) );
- relatives.setLastYear( periodTypes.contains( YearlyPeriodType.NAME ) );
+ relatives.setThisYear( periodTypes.contains( YearlyPeriodType.NAME ) );
}
return relatives;
=== modified file 'dhis-2/dhis-services/dhis-service-reporting/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-services/dhis-service-reporting/src/main/resources/META-INF/dhis/beans.xml 2011-12-22 17:28:35 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/resources/META-INF/dhis/beans.xml 2011-12-24 14:34:46 +0000
@@ -270,6 +270,7 @@
+
=== modified file 'dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/scheduling/DataMartTask.java'
--- dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/scheduling/DataMartTask.java 2011-12-19 14:21:03 +0000
+++ dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/scheduling/DataMartTask.java 2011-12-24 14:34:46 +0000
@@ -48,6 +48,8 @@
import org.hisp.dhis.indicator.IndicatorService;
import org.hisp.dhis.options.SystemSettingManager;
import org.hisp.dhis.organisationunit.OrganisationUnit;
+import org.hisp.dhis.organisationunit.OrganisationUnitGroup;
+import org.hisp.dhis.organisationunit.OrganisationUnitGroupService;
import org.hisp.dhis.organisationunit.OrganisationUnitService;
import org.hisp.dhis.period.Cal;
import org.hisp.dhis.period.Period;
@@ -76,6 +78,8 @@
private PeriodService periodService;
private OrganisationUnitService organisationUnitService;
+
+ private OrganisationUnitGroupService organisationUnitGroupService;
private DataSetService dataSetService;
@@ -97,7 +101,8 @@
public DataMartTask( DataMartService dataMartService, DataSetCompletenessService completenessService,
DataElementService dataElementService, IndicatorService indicatorService, PeriodService periodService,
- OrganisationUnitService organisationUnitService, DataSetService dataSetService, SystemSettingManager systemSettingManager )
+ OrganisationUnitService organisationUnitService, OrganisationUnitGroupService organisationUnitGroupService,
+ DataSetService dataSetService, SystemSettingManager systemSettingManager )
{
this.dataMartService = dataMartService;
this.completenessService = completenessService;
@@ -105,6 +110,7 @@
this.indicatorService = indicatorService;
this.periodService = periodService;
this.organisationUnitService = organisationUnitService;
+ this.organisationUnitGroupService = organisationUnitGroupService;
this.dataSetService = dataSetService;
this.systemSettingManager = systemSettingManager;
}
@@ -115,8 +121,9 @@
{
Collection dataElementIds = ConversionUtils.getIdentifiers( DataElement.class, dataElementService.getAllDataElements() );
Collection indicatorIds = ConversionUtils.getIdentifiers( Indicator.class, indicatorService.getAllIndicators() );
+ Collection dataSetIds = ConversionUtils.getIdentifiers( DataSet.class, dataSetService.getAllDataSets() );
Collection organisationUnitIds = ConversionUtils.getIdentifiers( OrganisationUnit.class, organisationUnitService.getAllOrganisationUnits() );
- Collection dataSetIds = ConversionUtils.getIdentifiers( DataSet.class, dataSetService.getAllDataSets() );
+ Collection organisationUnitGroupIds = ConversionUtils.getIdentifiers( OrganisationUnitGroup.class, organisationUnitGroupService.getOrganisationUnitGroupsWithGroupSets() );
Set periodTypes = (Set) systemSettingManager.getSystemSetting( KEY_SCHEDULED_PERIOD_TYPES, DEFAULT_SCHEDULED_PERIOD_TYPES );
@@ -149,7 +156,7 @@
Collection periodIds = ConversionUtils.getIdentifiers( Period.class, periodService.reloadPeriods( periods ) );
- dataMartService.export( dataElementIds, indicatorIds, periodIds, organisationUnitIds, null, null, true );
+ dataMartService.export( dataElementIds, indicatorIds, periodIds, organisationUnitIds, organisationUnitGroupIds, null, true );
completenessService.exportDataSetCompleteness( dataSetIds, periodIds, organisationUnitIds );
}
}