------------------------------------------------------------
revno: 13287
committer: Lars Helge Ă˜verland <[email protected]>
branch nick: dhis2
timestamp: Tue 2013-12-17 20:50:35 +0100
message:
  Data entry, replacing mergeWith call with copying certain properties for data 
set copy used for rendering data sets without any sections as section forms. 
Caused tons of db requests when org units and more were copied.
modified:
  
dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/LoadFormAction.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-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/LoadFormAction.java'
--- dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/LoadFormAction.java	2013-12-17 19:18:45 +0000
+++ dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/LoadFormAction.java	2013-12-17 19:50:35 +0000
@@ -318,9 +318,12 @@
 
         if ( displayMode.equals( DataSet.TYPE_DEFAULT ) )
         {
-            DataSet newDataSet = new DataSet();
-            newDataSet.mergeWith( dataSet );
-            dataSet = newDataSet;
+            DataSet dataSetCopy = new DataSet();
+            dataSetCopy.setName( dataSet.getName() );
+            dataSetCopy.setShortName( dataSet.getShortName() );
+            dataSetCopy.setRenderAsTabs( dataSet.isRenderAsTabs() );
+            dataSetCopy.setRenderHorizontally( dataSet.isRenderHorizontally() );
+            dataSet = dataSetCopy;
 
             for ( int i = 0; i < orderedCategoryCombos.size(); i++ )
             {

_______________________________________________
Mailing list: https://launchpad.net/~dhis2-devs
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp

Reply via email to