← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 2920: Add "Dataset for Mobile" page into dhis-web-maintenance-dataset: Allow admin manage DataSets (ava...

 

------------------------------------------------------------
revno: 2920
committer: Tran Ng Minh Luan <Luan@MinhLuan-PC>
branch nick: dhis2
timestamp: Fri 2011-02-25 14:08:59 +0700
message:
  Add "Dataset for Mobile" page into dhis-web-maintenance-dataset: Allow admin manage DataSets (available and for mobile) of selected Organisation Unit.
added:
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/MobileDataSetListAction.java
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/UpdateMobileDataSetAction.java
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/mobiledataset.js
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/menuWithTree.vm
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/mobileDatasetList.vm
modified:
  dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/resources/OrgUnitResource.java
  dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingService.java
  dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingServiceImpl.java
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/META-INF/dhis/beans.xml
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/org/hisp/dhis/dataset/i18n_module.properties
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/struts.xml
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/index.vm
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/menu.vm


--
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-api/src/main/java/org/hisp/dhis/web/api/resources/OrgUnitResource.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/resources/OrgUnitResource.java	2011-02-25 04:16:18 +0000
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/resources/OrgUnitResource.java	2011-02-25 07:08:59 +0000
@@ -136,62 +136,7 @@
     @Path( "updateDataSets" )
     public DataSetList checkUpdatedDataSet( DataSetList dataSetList, @HeaderParam( "accept-language" ) String locale )
     {
-        if ( DEBUG )
-            log.debug( "Checking updated datasets for org unit " + getUnit().getName() );
-        DataSetList updatedDataSetList = new DataSetList();
-        List<DataSet> dataSets = facilityReportingService.getMobileDataSetsForUnit( getUnit(), locale );
-        List<DataSet> currentDataSets = dataSetList.getCurrentDataSets();
-        // List<DataSet> copyCurrentDataSets = new
-        // ArrayList<DataSet>(currentDataSets.size());
-        // Collections.copy( copyCurrentDataSets, currentDataSets );
-        // check added dataset
-        for ( DataSet dataSet : dataSets )
-        {
-            if ( !currentDataSets.contains( dataSet ) )
-            {
-                if ( updatedDataSetList.getAddedDataSets() == null )
-                    updatedDataSetList.setAddedDataSets( new ArrayList<DataSet>() );
-                updatedDataSetList.getAddedDataSets().add( dataSet );
-                currentDataSets.add( dataSet );
-            }
-        }
-
-        // check deleted dataset
-        for ( DataSet dataSet : currentDataSets )
-        {
-            if ( !dataSets.contains( dataSet ) )
-            {
-                if ( updatedDataSetList.getDeletedDataSets() == null )
-                    updatedDataSetList.setDeletedDataSets( new ArrayList<DataSet>() );
-                updatedDataSetList.getDeletedDataSets().add( new DataSet( dataSet ) );
-            }
-        }
-        if ( updatedDataSetList.getDeletedDataSets() != null )
-        {
-            for ( DataSet dataSet : updatedDataSetList.getDeletedDataSets() )
-            {
-                currentDataSets.remove( dataSet );
-            }
-        }
-
-        // check modified dataset
-        Collections.sort( dataSets );
-        Collections.sort( currentDataSets );
-
-        for ( int i = 0; i < dataSets.size(); i++ )
-        {
-            if ( dataSets.get( i ).getVersion() != currentDataSets.get( i ).getVersion() )
-            {
-                if ( updatedDataSetList.getModifiedDataSets() == null )
-                    updatedDataSetList.setModifiedDataSets( new ArrayList<DataSet>() );
-                updatedDataSetList.getModifiedDataSets().add( dataSets.get( i ) );
-            }
-        }
-
-        if ( DEBUG )
-            log.debug( "Returning updated datasets for org unit " + getUnit().getName() );
-
-        return updatedDataSetList;
+        return facilityReportingService.getUpdatedDataSet( dataSetList, getUnit(), locale );
     }
 
     /**

=== modified file 'dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingService.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingService.java	2011-01-17 06:28:00 +0000
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingService.java	2011-02-25 07:08:59 +0000
@@ -32,6 +32,7 @@
 
 import org.hisp.dhis.organisationunit.OrganisationUnit;
 import org.hisp.dhis.web.api.model.DataSet;
+import org.hisp.dhis.web.api.model.DataSetList;
 import org.hisp.dhis.web.api.model.DataSetValue;
 
 public interface FacilityReportingService
@@ -48,5 +49,7 @@
      */
     public void saveDataSetValues( OrganisationUnit unit, DataSetValue dataSetValue )
         throws NotAllowedException;
+    
+    public DataSetList getUpdatedDataSet(DataSetList dataSetList, OrganisationUnit unit, String locale);
 
 }

=== modified file 'dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingServiceImpl.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingServiceImpl.java	2011-01-19 11:38:59 +0000
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingServiceImpl.java	2011-02-25 07:08:59 +0000
@@ -55,6 +55,7 @@
 import org.hisp.dhis.period.YearlyPeriodType;
 import org.hisp.dhis.web.api.model.DataElement;
 import org.hisp.dhis.web.api.model.DataSet;
+import org.hisp.dhis.web.api.model.DataSetList;
 import org.hisp.dhis.web.api.model.DataSetValue;
 import org.hisp.dhis.web.api.model.DataValue;
 import org.hisp.dhis.web.api.model.Section;
@@ -126,6 +127,64 @@
         return datasets;
     }
 
+    public DataSetList getUpdatedDataSet( DataSetList dataSetList, OrganisationUnit unit, String locale )
+    {
+        if ( DEBUG )
+            log.debug( "Checking updated datasets for org unit " + unit.getName() );
+        DataSetList updatedDataSetList = new DataSetList();
+        List<DataSet> dataSets = this.getMobileDataSetsForUnit( unit, locale );
+        List<DataSet> currentDataSets = dataSetList.getCurrentDataSets();
+
+        // check added dataset
+        for ( DataSet dataSet : dataSets )
+        {
+            if ( !currentDataSets.contains( dataSet ) )
+            {
+                if ( updatedDataSetList.getAddedDataSets() == null )
+                    updatedDataSetList.setAddedDataSets( new ArrayList<DataSet>() );
+                updatedDataSetList.getAddedDataSets().add( dataSet );
+                currentDataSets.add( dataSet );
+            }
+        }
+
+        // check deleted dataset
+        for ( DataSet dataSet : currentDataSets )
+        {
+            if ( !dataSets.contains( dataSet ) )
+            {
+                if ( updatedDataSetList.getDeletedDataSets() == null )
+                    updatedDataSetList.setDeletedDataSets( new ArrayList<DataSet>() );
+                updatedDataSetList.getDeletedDataSets().add( new DataSet( dataSet ) );
+            }
+        }
+        if ( updatedDataSetList.getDeletedDataSets() != null )
+        {
+            for ( DataSet dataSet : updatedDataSetList.getDeletedDataSets() )
+            {
+                currentDataSets.remove( dataSet );
+            }
+        }
+
+        // check modified dataset
+        Collections.sort( dataSets );
+        Collections.sort( currentDataSets );
+
+        for ( int i = 0; i < dataSets.size(); i++ )
+        {
+            if ( dataSets.get( i ).getVersion() != currentDataSets.get( i ).getVersion() )
+            {
+                if ( updatedDataSetList.getModifiedDataSets() == null )
+                    updatedDataSetList.setModifiedDataSets( new ArrayList<DataSet>() );
+                updatedDataSetList.getModifiedDataSets().add( dataSets.get( i ) );
+            }
+        }
+
+        if ( DEBUG )
+            log.debug( "Returning updated datasets for org unit " + unit.getName() );
+
+        return updatedDataSetList;
+    }
+
     public DataSet getDataSetForLocale( int dataSetId, Locale locale )
     {
         org.hisp.dhis.dataset.DataSet dataSet = dataSetService.getDataSet( dataSetId );
@@ -242,19 +301,20 @@
                 continue;
             }
 
-            saveValue(unit, period, dataElement, dataValue);
+            saveValue( unit, period, dataElement, dataValue );
 
         }
-        
-        CompleteDataSetRegistration registration = 
-            registrationService.getCompleteDataSetRegistration( dataSet, period, unit );
-
-        if (registration != null) {
+
+        CompleteDataSetRegistration registration = registrationService.getCompleteDataSetRegistration( dataSet, period,
+            unit );
+
+        if ( registration != null )
+        {
             registrationService.deleteCompleteDataSetRegistration( registration );
         }
-        
+
         registration = new CompleteDataSetRegistration();
-        
+
         registration.setDataSet( dataSet );
         registration.setPeriod( period );
         registration.setSource( unit );
@@ -281,20 +341,22 @@
         return dataSetService.getDataSetsBySource( unit ).contains( dataSet );
     }
 
-    private void saveValue(OrganisationUnit unit, Period period, org.hisp.dhis.dataelement.DataElement dataElement, DataValue dv) {
+    private void saveValue( OrganisationUnit unit, Period period, org.hisp.dhis.dataelement.DataElement dataElement,
+        DataValue dv )
+    {
 
         String value = dv.getValue().trim();
 
         DataElementCategoryOptionCombo cateOptCombo = categoryService.getDataElementCategoryOptionCombo( dv
             .getCategoryOptComboID() );
 
-        org.hisp.dhis.datavalue.DataValue dataValue = dataValueService.getDataValue( unit, dataElement,
-            period, cateOptCombo );
+        org.hisp.dhis.datavalue.DataValue dataValue = dataValueService.getDataValue( unit, dataElement, period,
+            cateOptCombo );
 
         if ( dataValue == null )
         {
-            dataValue = new org.hisp.dhis.datavalue.DataValue( dataElement, period, unit, value, "",
-                new Date(), "", cateOptCombo );
+            dataValue = new org.hisp.dhis.datavalue.DataValue( dataElement, period, unit, value, "", new Date(), "",
+                cateOptCombo );
             dataValueService.addDataValue( dataValue );
         }
         else
@@ -305,7 +367,7 @@
         }
 
     }
-    
+
     // -------------------------------------------------------------------------
     // Supportive method
     // -------------------------------------------------------------------------
@@ -394,5 +456,4 @@
         this.registrationService = registrationService;
     }
 
-
 }

=== added file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/MobileDataSetListAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/MobileDataSetListAction.java	1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/MobileDataSetListAction.java	2011-02-25 07:08:59 +0000
@@ -0,0 +1,72 @@
+package org.hisp.dhis.dataset.action;
+
+import java.util.Collection;
+
+import org.hisp.dhis.dataset.DataSet;
+import org.hisp.dhis.dataset.DataSetService;
+import org.hisp.dhis.organisationunit.OrganisationUnit;
+import org.hisp.dhis.ouwt.manager.OrganisationUnitSelectionManager;
+
+import com.opensymphony.xwork2.Action;
+
+public class MobileDataSetListAction
+    implements Action
+{
+    // -------------------------------------------------------------------------
+    // Dependencies
+    // -------------------------------------------------------------------------
+
+    private DataSetService dataSetService;
+
+    public void setDataSetService( DataSetService dataSetService )
+    {
+        this.dataSetService = dataSetService;
+    }
+    
+    private OrganisationUnitSelectionManager selectionManager;
+
+    public void setSelectionManager( OrganisationUnitSelectionManager selectionManager )
+    {
+        this.selectionManager = selectionManager;
+    }
+    
+    // -------------------------------------------------------------------------
+    // Getters and Setters
+    // -------------------------------------------------------------------------
+    private Collection<DataSet> dataSets;
+    
+    public void setDataSets( Collection<DataSet> dataSets )
+    {
+        this.dataSets = dataSets;
+    }
+    
+    public Collection<DataSet> getDataSets()
+    {
+        return dataSets;
+    }
+    
+    private Collection<DataSet> mobileDatasets;
+
+    public Collection<DataSet> getMobileDatasets()
+    {
+        return mobileDatasets;
+    }
+
+    public void setMobileDatasets( Collection<DataSet> mobileDatasets )
+    {
+        this.mobileDatasets = mobileDatasets;
+    }
+
+    @Override
+    public String execute()
+        throws Exception
+    {
+        OrganisationUnit selectedUnits =  selectionManager.getSelectedOrganisationUnit();
+        dataSets = dataSetService.getDataSetsBySource( selectedUnits );
+        mobileDatasets = dataSetService.getDataSetsForMobile( selectedUnits );
+        dataSets.removeAll( mobileDatasets );
+        System.out.println("Number of datasets:"+ dataSets.size());
+        return SUCCESS;
+    }
+
+}

=== added file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/UpdateMobileDataSetAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/UpdateMobileDataSetAction.java	1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/java/org/hisp/dhis/dataset/action/UpdateMobileDataSetAction.java	2011-02-25 07:08:59 +0000
@@ -0,0 +1,70 @@
+package org.hisp.dhis.dataset.action;
+
+import java.util.Collection;
+import java.util.HashSet;
+
+import org.hisp.dhis.dataset.DataSet;
+import org.hisp.dhis.dataset.DataSetService;
+
+import com.opensymphony.xwork2.Action;
+
+public class UpdateMobileDataSetAction
+    implements Action
+{
+    // -------------------------------------------------------------------------
+    // Dependencies
+    // -------------------------------------------------------------------------
+    private DataSetService dataSetService;
+
+    public void setDataSetService( DataSetService dataSetService )
+    {
+        this.dataSetService = dataSetService;
+    }
+
+    // -------------------------------------------------------------------------
+    // Input/Output
+    // -------------------------------------------------------------------------
+    private Collection<String> selectedList = new HashSet<String>();
+
+    public void setSelectedList( Collection<String> selectedList )
+    {
+        this.selectedList = selectedList;
+    }
+    
+    private Collection<String> availableList = new HashSet<String>();
+    
+    public void setAvailableList( Collection<String> availableList )
+    {
+        this.availableList = availableList;
+    }
+    
+    @Override
+    public String execute()
+        throws Exception
+    {
+        try{
+        DataSet dataset = null;
+        for(String id : selectedList){
+            dataset = dataSetService.getDataSet( Integer.parseInt( id ) );
+            if(!dataset.isMobile()){
+                System.out.println("set dataset "+ dataset.getName()+" to true");
+                dataset.setMobile( true );
+                dataSetService.updateDataSet( dataset );
+            }
+        }
+        for(String id : availableList){
+            dataset = dataSetService.getDataSet( Integer.parseInt( id ) );
+            if(dataset.isMobile()){
+                System.out.println("set dataset "+ dataset.getName()+" to false");
+                dataset.setMobile( false );
+                dataSetService.updateDataSet( dataset );
+            }
+        }
+        }
+        catch (Exception e) {
+            System.out.println(e.getMessage());
+        }
+        return SUCCESS;
+    }
+
+}

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/META-INF/dhis/beans.xml	2011-01-25 22:15:46 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/META-INF/dhis/beans.xml	2011-02-25 07:08:59 +0000
@@ -136,7 +136,26 @@
 		</property>
 	</bean>		
 	
-	<!-- DataSet -->	
+	<!-- DataSet -->
+	<bean id="org.hisp.dhis.dataset.action.MobileDataSetListAction"
+		class="org.hisp.dhis.dataset.action.MobileDataSetListAction"
+		scope="prototype">
+		<property name="dataSetService">
+			<ref bean="org.hisp.dhis.dataset.DataSetService"/>
+		</property>
+		<property name="selectionManager">
+			<ref bean="org.hisp.dhis.ouwt.manager.OrganisationUnitSelectionManager"/>
+		</property>
+	</bean>
+	
+	<bean id="org.hisp.dhis.dataset.action.UpdateMobileDataSetAction"
+		class="org.hisp.dhis.dataset.action.UpdateMobileDataSetAction"
+		scope="prototype">
+		<property name="dataSetService">
+			<ref bean="org.hisp.dhis.dataset.DataSetService"/>
+		</property>
+	</bean>	
+		
 	
 	<bean id="org.hisp.dhis.dataset.action.DefineDataSetAssociationsAction"
 		class="org.hisp.dhis.dataset.action.DefineDataSetAssociationsAction"

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/org/hisp/dhis/dataset/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/org/hisp/dhis/dataset/i18n_module.properties	2011-01-21 05:11:50 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/org/hisp/dhis/dataset/i18n_module.properties	2011-02-25 07:08:59 +0000
@@ -1,3 +1,5 @@
+intro_mobile_dataset										= Manage Dataset which is available for facility reporting on mobile.
+mobile_dataset												= Dataset for Mobile
 available_for_mobile_reporting								= Available for Mobile Reporting
 please_select_dataset										= Please select a dataset
 greying_area												= Greying area

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/struts.xml	2011-01-25 22:15:46 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/resources/struts.xml	2011-02-25 07:08:59 +0000
@@ -16,6 +16,23 @@
 	        
     <!-- Dataset -->
     
+    <action name="showMobileDataSet"
+			class="org.hisp.dhis.dataset.action.MobileDataSetListAction">
+			<result name="success" type="velocity">/main.vm</result>
+			<param name="page">/dhis-web-maintenance-dataset/mobileDatasetList.vm</param>
+			<param name="menu">/dhis-web-maintenance-dataset/menuWithTree.vm</param>
+			<param name="menuTreeHeight">300</param>
+			<param name="javascripts">
+					../dhis-web-commons/ouwt/ouwt.js,javascript/organisationUnit.js,javascript/mobiledataset.js
+			</param>
+			<interceptor-ref name="organisationUnitTreeStack" />
+	</action>
+	
+	<action name="updateMobileDataset"
+			class="org.hisp.dhis.dataset.action.UpdateMobileDataSetAction">
+			<result name="success" type="redirect">showMobileDataSet.action</result>
+	</action>
+    
     <action name="dataSet" class="org.hisp.dhis.dataset.action.DataSetListAction">
       <result name="success" type="velocity">/main.vm</result>
       <param name="page">/dhis-web-maintenance-dataset/dataSetList.vm</param>

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/index.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/index.vm	2011-01-11 17:14:27 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/index.vm	2011-02-25 07:08:59 +0000
@@ -5,4 +5,5 @@
     #introListImgItem( "dataSet.action" "dataset" "dataset" )
     #introListImgItem( "section.action" "dataset_section" "dataset" )
     #introListImgItem( "showAssignMultiDataSetForOrgunitForm.action" "dataset_assignment_editor" "dataset" )
+    #introListImgItem( "showMobileDataSet.action" "mobile_dataset" "dataset" )
 </ul>
\ No newline at end of file

=== added file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/mobiledataset.js'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/mobiledataset.js	1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/javascript/mobiledataset.js	2011-02-25 07:08:59 +0000
@@ -0,0 +1,3 @@
+function orgunitselected(){
+	window.location.reload(true)
+}
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/menu.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/menu.vm	2011-01-11 17:04:20 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/menu.vm	2011-02-25 07:08:59 +0000
@@ -4,4 +4,5 @@
 	<li><a href="dataSet.action">$i18n.getString( "dataset" )&nbsp;</a></li>
 	<li><a href="section.action">$i18n.getString( "dataset_section" )&nbsp;</a></li>
 	<li><a href="showAssignMultiDataSetForOrgunitForm.action">$i18n.getString( "dataset_assignment_editor" )&nbsp;</a></li>
+	<li><a href="showMobileDataSet.action">$i18n.getString( "mobile_dataset" )&nbsp;</a></li>
 </ul>
\ No newline at end of file

=== added file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/menuWithTree.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/menuWithTree.vm	1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/menuWithTree.vm	2011-02-25 07:08:59 +0000
@@ -0,0 +1,5 @@
+#parse( "/dhis-web-maintenance-dataset/menu.vm" )
+#parse( "/dhis-web-commons/ouwt/orgunittreesearch.vm" )
+<script>
+	selection.setListenerFunction( orgunitselected );
+</script>
\ No newline at end of file

=== added file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/mobileDatasetList.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/mobileDatasetList.vm	1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-dataset/src/main/webapp/dhis-web-maintenance-dataset/mobileDatasetList.vm	2011-02-25 07:08:59 +0000
@@ -0,0 +1,49 @@
+<form id="updateMobileDataset" name="updateMobileDataset" action="updateMobileDataset.action" method="post">
+<table id="dataSetSelectionArea">
+    <col/> ## Available DataSet of selected Organisation Unit
+    <col/> ## Filter
+    <col/> ## Mobile DataSet of selected Organisation Unit
+    <thead>
+      <tr>
+        <th>$i18n.getString( "available_datasets" )</th>
+		<th>$i18n.getString( "filter" )</th>
+        <th>$i18n.getString( "mobile_dataset" )</th>
+      </tr>
+    </thead>
+    <tbody>
+		<tr>
+		  <!---->
+		  <td>
+          <select size="15" id="availableList" name="availableList" multiple="multiple" style="min-width:20em;height:20em" ondblclick="moveSelectedById( 'availableList', 'selectedList');">
+              	#foreach( $dataset in $dataSets )
+              		<option value="$dataset.id">$encoder.htmlEncode( $dataset.name )-Version $dataset.version</option>
+          		#end
+          </select>
+          </td>
+		  <td>
+            <input type="button" value="&gt;" title="$i18n.getString( 'move_selected' )" style="width:50px" onclick="moveSelectedById( 'availableList', 'selectedList');"/><br/>
+            <input type="button" value="&lt;" title="$i18n.getString( 'remove_selected' )" style="width:50px" onclick="moveSelectedById( 'selectedList', 'availableList');"/><br/>
+            <input type="button" value="&gt;&gt;" title="$i18n.getString('move_all')" style="width:50px" onclick="moveAllById( 'availableList', 'selectedList' );"/><br/>
+            <input type="button" value="&lt;&lt;" title="$i18n.getString('remove_all')" style="width:50px" onclick="moveAllById( 'selectedList', 'availableList' );"/>
+          </td>
+          <td>
+          <!---->
+          <select size="15" id="selectedList" name="selectedList" multiple="multiple" style="min-width:20em;height:20em" ondblclick="moveSelectedById( 'selectedList', 'availableList');">
+              	#foreach( $mobiledataset in $mobileDatasets )
+              		<option value="$mobiledataset.id">$encoder.htmlEncode( $mobiledataset.name )-Version $mobiledataset.version</option>
+          		#end
+          </select>
+          </td>
+          <td style="width:30px; text-align:center">
+            <a href="javascript:moveUpSelectedOption( 'selectedList' )"><img src="../images/move_up.png"/></a><br/><br/>
+            <a href="javascript:moveDownSelectedOption( 'selectedList' )"><img src="../images/move_down.png"/></a><br/><br/>
+          </td>
+		</tr>
+		<tr>
+        <td colspan="3">
+          <input type="submit" value="$i18n.getString( 'save' )" style="width:20em"/>
+        </td>
+      </tr>
+	</tbody>
+</table>
+</form>
\ No newline at end of file