dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #10723
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 2940: Fix bug: Dataset report deletes non-numeric data elements from table datasetmembers.
------------------------------------------------------------
revno: 2940
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2011-03-01 13:02:22 +0700
message:
Fix bug: Dataset report deletes non-numeric data elements from table datasetmembers.
modified:
dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/datasetreport/impl/DefaultDataSetReportService.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/datasetreport/impl/DefaultDataSetReportService.java'
--- dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/datasetreport/impl/DefaultDataSetReportService.java 2011-01-07 11:37:47 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/java/org/hisp/dhis/datasetreport/impl/DefaultDataSetReportService.java 2011-03-01 06:02:22 +0000
@@ -27,6 +27,7 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
+import java.util.ArrayList;
import java.util.Collection;
import java.util.Map;
import java.util.TreeMap;
@@ -103,13 +104,13 @@
{
String aggregationStrategy = (String) systemSettingManager.getSystemSetting( KEY_AGGREGATION_STRATEGY, DEFAULT_AGGREGATION_STRATEGY );
- Collection<DataElement> dataElements = dataSet.getDataElements();
+ Collection<DataElement> dataElements = new ArrayList<DataElement>( dataSet.getDataElements());
FilterUtils.filter( dataElements, new AggregatableDataElementFilter() );
Map<String, String> map = new TreeMap<String,String>();
- for ( DataElement dataElement : dataSet.getDataElements() )
+ for ( DataElement dataElement : dataElements )
{
DataElementCategoryCombo categoryCombo = dataElement.getCategoryCombo();