dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #22689
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 10986: (GIS) Migrated to analytics + Cleaned up outdated actions.
Merge authors:
Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 10986 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2013-05-24 16:06:07 +0200
message:
(GIS) Migrated to analytics + Cleaned up outdated actions.
removed:
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLayerAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLegendAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLegendSetAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AssignDataElementsToMapLegendSetAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AssignIndicatorsToMapLegendSetAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLayerAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLegendAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLegendSetAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapSystemSettingsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapViewAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementGroupSetsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementGroupsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllIndicatorGroupsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllIndicatorsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLayersAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLegendSetsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLegendsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapViewsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllOrganisationUnitLevelsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetDataElementMapValuesAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetDataElementsByDataElementGroupAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetGeoJsonWithValuesAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetIndicatorMapValuesAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetIndicatorsByIndicatorGroupAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetInfrastructuralDataElementMapValuesAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLayersByTypeAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLegendSetAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLegendsByMapLegendSetAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapUserSettingsAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapViewAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetOrganisationUnitLevelsByFeatureTypeAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetOrganisationUnitsAtLevelAction.java
dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/SetMapUserSettingsAction.java
modified:
dhis-2/dhis-web/dhis-web-mapping/src/main/resources/META-INF/dhis/beans.xml
dhis-2/dhis-web/dhis-web-mapping/src/main/resources/struts.xml
dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/app/scripts/core.js
--
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
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLayerAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLayerAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLayerAction.java 1970-01-01 00:00:00 +0000
@@ -1,129 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class AddOrUpdateMapLayerAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private String name;
-
- public void setName( String name )
- {
- this.name = name;
- }
-
- private String type;
-
- public void setType( String type )
- {
- this.type = type;
- }
-
- private String url;
-
- public void setUrl( String url )
- {
- this.url = url;
- }
-
- private String layers;
-
- public void setLayers( String layers )
- {
- this.layers = layers;
- }
-
- private String time;
-
- public void setTime( String time )
- {
- this.time = time;
- }
-
- private String fillColor;
-
- public void setFillColor( String fillColor )
- {
- this.fillColor = fillColor;
- }
-
- private double fillOpacity;
-
- public void setFillOpacity( double fillOpacity )
- {
- this.fillOpacity = fillOpacity;
- }
-
- private String strokeColor;
-
- public void setStrokeColor( String strokeColor )
- {
- this.strokeColor = strokeColor;
- }
-
- private int strokeWidth;
-
- public void setStrokeWidth( int strokeWidth )
- {
- this.strokeWidth = strokeWidth;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- mappingService.addOrUpdateMapLayer( name, type, url, layers, time, fillColor, fillOpacity, strokeColor, strokeWidth );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLegendAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLegendAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLegendAction.java 1970-01-01 00:00:00 +0000
@@ -1,102 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class AddOrUpdateMapLegendAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private String name;
-
- public void setName( String name )
- {
- this.name = name;
- }
-
- private String startValue;
-
- public void setStartValue( String startValue )
- {
- this.startValue = startValue;
- }
-
- private String endValue;
-
- public void setEndValue( String endValue )
- {
- this.endValue = endValue;
- }
-
- private String color;
-
- public void setColor( String color )
- {
- this.color = color;
- }
-
- private String image;
-
- public void setImage( String image )
- {
- this.image = image;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- this.mappingService.addOrUpdateMapLegend( name, Double.parseDouble( startValue ),
- Double.parseDouble( endValue ), color, image );
-
- return SUCCESS;
- }
-}
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLegendSetAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLegendSetAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AddOrUpdateMapLegendSetAction.java 1970-01-01 00:00:00 +0000
@@ -1,109 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.Set;
-
-import org.hisp.dhis.mapping.MapLegend;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class AddOrUpdateMapLegendSetAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private String name;
-
- public void setName( String name )
- {
- this.name = name;
- }
-
- private String type;
-
- public void setType( String type )
- {
- this.type = type;
- }
-
- private String symbolizer;
-
- public void setSymbolizer( String symbolizer )
- {
- this.symbolizer = symbolizer;
- }
-
- private Collection<String> mapLegends;
-
- public void setMapLegends( Collection<String> mapLegends )
- {
- this.mapLegends = mapLegends;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- Set<MapLegend> legends = new HashSet<MapLegend>();
-
- if ( mapLegends != null )
- {
- for ( String legend : mapLegends )
- {
- legends.add( mappingService.getMapLegend( Integer.parseInt( legend ) ) );
- }
- }
-
- mappingService.addOrUpdateMapLegendSet( name, type, symbolizer, legends );
-
- return SUCCESS;
- }
-}
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AssignDataElementsToMapLegendSetAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AssignDataElementsToMapLegendSetAction.java 2012-10-25 08:23:30 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AssignDataElementsToMapLegendSetAction.java 1970-01-01 00:00:00 +0000
@@ -1,68 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-import java.util.Collection;
-
-import org.hisp.dhis.dataelement.DataElement;
-import org.hisp.dhis.dataelement.DataElementService;
-import org.hisp.dhis.mapping.MapLegendSet;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-public class AssignDataElementsToMapLegendSetAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- private DataElementService dataElementService;
-
- public void setDataElementService( DataElementService dataElementService )
- {
- this.dataElementService = dataElementService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer id;
-
- public void setId( Integer id )
- {
- this.id = id;
- }
-
- private Collection<String> dataElements;
-
- public void setDataElements( Collection<String> dataElements )
- {
- this.dataElements = dataElements;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- MapLegendSet mapLegendSet = mappingService.getMapLegendSet( id );
-
- for ( String dataElement : dataElements )
- {
- DataElement element = dataElementService.getDataElement( Integer.parseInt( dataElement ) );
- element.setLegendSet( mapLegendSet );
- dataElementService.updateDataElement( element );
- }
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AssignIndicatorsToMapLegendSetAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AssignIndicatorsToMapLegendSetAction.java 2012-10-25 08:23:30 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/AssignIndicatorsToMapLegendSetAction.java 1970-01-01 00:00:00 +0000
@@ -1,70 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-import java.util.Collection;
-
-import org.hisp.dhis.indicator.Indicator;
-import org.hisp.dhis.indicator.IndicatorService;
-import org.hisp.dhis.mapping.MapLegendSet;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-public class AssignIndicatorsToMapLegendSetAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- private IndicatorService indicatorService;
-
- public void setIndicatorService( IndicatorService indicatorService )
- {
- this.indicatorService = indicatorService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer id;
-
- public void setId( Integer id )
- {
- this.id = id;
- }
-
- private Collection<String> indicators;
-
- public void setIndicators( Collection<String> indicators )
- {
- this.indicators = indicators;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- MapLegendSet mapLegendSet = mappingService.getMapLegendSet( id );
-
- for ( String indicator : indicators )
- {
- Indicator i = indicatorService.getIndicator( Integer.parseInt( indicator ) );
- i.setLegendSet( mapLegendSet );
- indicatorService.updateIndicator( i );
- }
-
- mappingService.updateMapLegendSet( mapLegendSet );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLayerAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLayerAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLayerAction.java 1970-01-01 00:00:00 +0000
@@ -1,79 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import org.hisp.dhis.mapping.MapLayer;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class DeleteMapLayerAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer id;
-
- public void setId( Integer id )
- {
- this.id = id;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- MapLayer mapLayer = mappingService.getMapLayer( id );
-
- if ( mapLayer != null )
- {
- mappingService.deleteMapLayer( mapLayer );
- }
-
- return SUCCESS;
- }
-}
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLegendAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLegendAction.java 2012-04-20 09:52:17 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLegendAction.java 1970-01-01 00:00:00 +0000
@@ -1,48 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-import org.hisp.dhis.mapping.MapLegend;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-public class DeleteMapLegendAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer id;
-
- public void setId( Integer id )
- {
- this.id = id;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- MapLegend mapLegend = mappingService.getMapLegend( id.intValue() );
-
- if ( mapLegend != null )
- {
- mappingService.deleteMapLegend( mapLegend );
- }
-
- return SUCCESS;
- }
-}
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLegendSetAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLegendSetAction.java 2012-10-19 15:15:44 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapLegendSetAction.java 1970-01-01 00:00:00 +0000
@@ -1,79 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import org.hisp.dhis.mapping.MapLegendSet;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Lars Helge Overland
- * @version $Id$
- */
-public class DeleteMapLegendSetAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private String id;
-
- public void setId( String id )
- {
- this.id = id;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- MapLegendSet legendSet = mappingService.getMapLegendSet( id );
-
- if ( legendSet != null )
- {
- mappingService.deleteMapLegendSet( legendSet );
- }
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapSystemSettingsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapSystemSettingsAction.java 2012-02-02 20:01:36 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapSystemSettingsAction.java 1970-01-01 00:00:00 +0000
@@ -1,77 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import org.hisp.dhis.setting.SystemSettingManager;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class DeleteMapSystemSettingsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private SystemSettingManager systemSettingManager;
-
- public void setSystemSettingManager( SystemSettingManager systemSettingManager )
- {
- this.systemSettingManager = systemSettingManager;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Boolean googleKey;
-
- public void setGoogleKey( Boolean googleKey )
- {
- this.googleKey = googleKey;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- if ( googleKey == true )
- {
- systemSettingManager.deleteSystemSetting( SystemSettingManager.KEY_GOOGLE_MAPS_API_KEY );
- }
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapViewAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapViewAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/DeleteMapViewAction.java 1970-01-01 00:00:00 +0000
@@ -1,79 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import org.hisp.dhis.mapping.MapView;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class DeleteMapViewAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer id;
-
- public void setId( Integer id )
- {
- this.id = id;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- MapView mapView = mappingService.getMapView( id );
-
- if ( mapView != null )
- {
- mappingService.deleteMapView( mapView );
- }
-
- return SUCCESS;
- }
-}
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementGroupSetsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementGroupSetsAction.java 2012-01-25 17:11:43 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementGroupSetsAction.java 1970-01-01 00:00:00 +0000
@@ -1,82 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
-import org.hisp.dhis.dataelement.DataElementGroupSet;
-import org.hisp.dhis.dataelement.DataElementService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetAllDataElementGroupSetsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private DataElementService dataElementService;
-
- public void setDataElementService( DataElementService dataElementService )
- {
- this.dataElementService = dataElementService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<DataElementGroupSet> object;
-
- public List<DataElementGroupSet> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = new ArrayList<DataElementGroupSet>( dataElementService.getAllDataElementGroupSets() );
-
- Collections.sort( object, IdentifiableObjectNameComparator.INSTANCE );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementGroupsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementGroupsAction.java 2012-01-25 17:11:43 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementGroupsAction.java 1970-01-01 00:00:00 +0000
@@ -1,82 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
-import org.hisp.dhis.dataelement.DataElementGroup;
-import org.hisp.dhis.dataelement.DataElementService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetAllDataElementGroupsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private DataElementService dataElementService;
-
- public void setDataElementService( DataElementService dataElementService )
- {
- this.dataElementService = dataElementService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<DataElementGroup> object;
-
- public List<DataElementGroup> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = new ArrayList<DataElementGroup>( dataElementService.getAllDataElementGroups() );
-
- Collections.sort( object, IdentifiableObjectNameComparator.INSTANCE );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementsAction.java 2012-01-20 10:38:11 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllDataElementsAction.java 1970-01-01 00:00:00 +0000
@@ -1,82 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
-import org.hisp.dhis.dataelement.DataElement;
-import org.hisp.dhis.dataelement.DataElementService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetAllDataElementsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private DataElementService dataElementService;
-
- public void setDataElementService( DataElementService dataElementService )
- {
- this.dataElementService = dataElementService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<DataElement> object;
-
- public List<DataElement> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = new ArrayList<DataElement>( dataElementService.getAllDataElements() );
-
- Collections.sort( object, new IdentifiableObjectNameComparator() );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllIndicatorGroupsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllIndicatorGroupsAction.java 2012-01-25 17:11:43 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllIndicatorGroupsAction.java 1970-01-01 00:00:00 +0000
@@ -1,82 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
-import org.hisp.dhis.indicator.IndicatorGroup;
-import org.hisp.dhis.indicator.IndicatorService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Lars Helge Overland
- * @version $Id$
- */
-public class GetAllIndicatorGroupsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private IndicatorService indicatorService;
-
- public void setIndicatorService( IndicatorService indicatorService )
- {
- this.indicatorService = indicatorService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<IndicatorGroup> object;
-
- public List<IndicatorGroup> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = new ArrayList<IndicatorGroup>( indicatorService.getAllIndicatorGroups() );
-
- Collections.sort( object, IdentifiableObjectNameComparator.INSTANCE );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllIndicatorsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllIndicatorsAction.java 2012-01-20 10:38:11 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllIndicatorsAction.java 1970-01-01 00:00:00 +0000
@@ -1,82 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
-import org.hisp.dhis.indicator.Indicator;
-import org.hisp.dhis.indicator.IndicatorService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetAllIndicatorsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private IndicatorService indicatorService;
-
- public void setIndicatorService( IndicatorService indicatorService )
- {
- this.indicatorService = indicatorService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<Indicator> object;
-
- public List<Indicator> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = new ArrayList<Indicator>( indicatorService.getAllIndicators() );
-
- Collections.sort( object, new IdentifiableObjectNameComparator() );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLayersAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLayersAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLayersAction.java 1970-01-01 00:00:00 +0000
@@ -1,81 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.mapping.MapLayer;
-import org.hisp.dhis.mapping.MappingService;
-import org.hisp.dhis.mapping.comparator.MapLayerNameComparator;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetAllMapLayersAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<MapLayer> object;
-
- public List<MapLayer> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- object = new ArrayList<MapLayer>( mappingService.getAllMapLayers() );
-
- Collections.sort( object, new MapLayerNameComparator() );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLegendSetsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLegendSetsAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLegendSetsAction.java 1970-01-01 00:00:00 +0000
@@ -1,77 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.hisp.dhis.mapping.MapLegendSet;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Lars Helge Overland
- * @version $Id$
- */
-public class GetAllMapLegendSetsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<MapLegendSet> object;
-
- public List<MapLegendSet> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- object = new ArrayList<MapLegendSet>( mappingService.getAllMapLegendSets() );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLegendsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLegendsAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapLegendsAction.java 1970-01-01 00:00:00 +0000
@@ -1,82 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.mapping.MapLegend;
-import org.hisp.dhis.mapping.MappingService;
-import org.hisp.dhis.mapping.comparator.MapLegendComparator;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetAllMapLegendsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<MapLegend> object;
-
- public List<MapLegend> getObject()
- {
- return this.object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- this.object = new ArrayList<MapLegend>( this.mappingService.getAllMapLegends() );
-
- Collections.sort( this.object, new MapLegendComparator() );
-
- return SUCCESS;
- }
-}
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapViewsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapViewsAction.java 2012-11-06 07:01:56 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllMapViewsAction.java 1970-01-01 00:00:00 +0000
@@ -1,81 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
-import org.hisp.dhis.mapping.MapView;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetAllMapViewsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<MapView> object;
-
- public List<MapView> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- object = new ArrayList<MapView>( mappingService.getAllMapViews() );
-
- Collections.sort( object, IdentifiableObjectNameComparator.INSTANCE );
-
- return SUCCESS;
- }
-}
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllOrganisationUnitLevelsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllOrganisationUnitLevelsAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetAllOrganisationUnitLevelsAction.java 1970-01-01 00:00:00 +0000
@@ -1,77 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.List;
-
-import org.hisp.dhis.organisationunit.OrganisationUnitLevel;
-import org.hisp.dhis.organisationunit.OrganisationUnitService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Lars Helge Overland
- * @version $Id$
- */
-public class GetAllOrganisationUnitLevelsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private OrganisationUnitService organisationUnitService;
-
- public void setOrganisationUnitService( OrganisationUnitService organisationUnitService )
- {
- this.organisationUnitService = organisationUnitService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<OrganisationUnitLevel> object;
-
- public List<OrganisationUnitLevel> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = organisationUnitService.getOrganisationUnitLevels();
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetDataElementMapValuesAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetDataElementMapValuesAction.java 2012-04-20 09:52:17 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetDataElementMapValuesAction.java 1970-01-01 00:00:00 +0000
@@ -1,123 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import static org.hisp.dhis.api.utils.ContextUtils.CONTENT_TYPE_JSON;
-
-import java.util.Collection;
-
-import org.apache.struts2.ServletActionContext;
-import org.hisp.dhis.aggregation.AggregatedMapValue;
-import org.hisp.dhis.api.utils.ContextUtils;
-import org.hisp.dhis.api.utils.ContextUtils.CacheStrategy;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetDataElementMapValuesAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- private ContextUtils contextUtils;
-
- public void setContextUtils( ContextUtils contextUtils )
- {
- this.contextUtils = contextUtils;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer id;
-
- public void setId( Integer id )
- {
- this.id = id;
- }
-
- private Integer periodId;
-
- public void setPeriodId( Integer periodId )
- {
- this.periodId = periodId;
- }
-
- private Integer parentId;
-
- public void setParentId( Integer parentId )
- {
- this.parentId = parentId;
- }
-
- private Integer level;
-
- public void setLevel( Integer level )
- {
- this.level = level;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Collection<AggregatedMapValue> object;
-
- public Collection<AggregatedMapValue> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = mappingService.getDataElementMapValues( id, periodId, parentId, level );
-
- contextUtils.configureResponse( ServletActionContext.getResponse(), CONTENT_TYPE_JSON, CacheStrategy.RESPECT_SYSTEM_SETTING, null, false );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetDataElementsByDataElementGroupAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetDataElementsByDataElementGroupAction.java 2012-04-22 19:36:58 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetDataElementsByDataElementGroupAction.java 1970-01-01 00:00:00 +0000
@@ -1,98 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
-import org.hisp.dhis.dataelement.DataElement;
-import org.hisp.dhis.dataelement.DataElementGroup;
-import org.hisp.dhis.dataelement.DataElementService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- */
-public class GetDataElementsByDataElementGroupAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private DataElementService dataElementService;
-
- public void setDataElementService( DataElementService dataElementService )
- {
- this.dataElementService = dataElementService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer dataElementGroupId;
-
- public void setDataElementGroupId( Integer dataElementGroupId )
- {
- this.dataElementGroupId = dataElementGroupId;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<DataElement> object;
-
- public List<DataElement> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- DataElementGroup group = dataElementService.getDataElementGroup( dataElementGroupId );
-
- if ( group != null )
- {
- object = new ArrayList<DataElement>( group.getMembers() );
-
- Collections.sort( object, new IdentifiableObjectNameComparator() );
- }
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetGeoJsonWithValuesAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetGeoJsonWithValuesAction.java 2012-04-22 19:36:58 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetGeoJsonWithValuesAction.java 1970-01-01 00:00:00 +0000
@@ -1,179 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collection;
-
-import org.hisp.dhis.aggregation.AggregatedMapValue;
-import org.hisp.dhis.mapping.MappingService;
-import org.hisp.dhis.organisationunit.OrganisationUnit;
-import org.hisp.dhis.organisationunit.OrganisationUnitService;
-import org.hisp.dhis.system.filter.OrganisationUnitWithValidCoordinatesFilter;
-import org.hisp.dhis.system.util.FilterUtils;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetGeoJsonWithValuesAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private OrganisationUnitService organisationUnitService;
-
- public void setOrganisationUnitService( OrganisationUnitService organisationUnitService )
- {
- this.organisationUnitService = organisationUnitService;
- }
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer indicatorId;
-
- public void setIndicatorId( Integer indicatorId )
- {
- this.indicatorId = indicatorId;
- }
-
- private Integer dataElementId;
-
- public void setDataElementId( Integer dataElementId )
- {
- this.dataElementId = dataElementId;
- }
-
- private Integer periodId;
-
- public void setPeriodId( Integer periodId )
- {
- this.periodId = periodId;
- }
-
- private Integer parentId;
-
- public void setParentId( Integer id )
- {
- this.parentId = id;
- }
-
- private Integer level;
-
- public void setLevel( Integer level )
- {
- this.level = level;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private Collection<OrganisationUnit> object;
-
- public Collection<OrganisationUnit> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- OrganisationUnit parent = organisationUnitService.getOrganisationUnit( parentId );
-
- level = level == null ? organisationUnitService.getLevelOfOrganisationUnit( parent.getId() ) : level;
-
- Collection<OrganisationUnit> organisationUnits = organisationUnitService.getOrganisationUnitsAtLevel( level,
- parent );
-
- FilterUtils.filter( organisationUnits, new OrganisationUnitWithValidCoordinatesFilter() );
-
- object = new ArrayList<OrganisationUnit>();
-
- for ( OrganisationUnit unit : organisationUnits )
- {
- if ( !unit.getFeatureType().equals( OrganisationUnit.FEATURETYPE_POINT ) )
- {
- object.add( unit );
- }
- }
-
- for ( OrganisationUnit unit : organisationUnits )
- {
- if ( unit.getFeatureType().equals( OrganisationUnit.FEATURETYPE_POINT ) )
- {
- object.add( unit );
- }
- }
-
- Collection<AggregatedMapValue> values = new ArrayList<AggregatedMapValue>();
-
- if ( indicatorId != null )
- {
- values = mappingService.getIndicatorMapValues( indicatorId, periodId, object );
- }
-
- else if ( dataElementId != null )
- {
- values = mappingService.getDataElementMapValues( dataElementId, periodId, object );
- }
-
- if ( values != null )
- {
- for ( OrganisationUnit unit : object )
- {
- for ( AggregatedMapValue value : values )
- {
- if ( unit.getId() == value.getOrganisationUnitId() )
- {
- unit.setValue( value.getValue() );
- }
- }
- }
- }
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetIndicatorMapValuesAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetIndicatorMapValuesAction.java 2012-09-12 18:01:24 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetIndicatorMapValuesAction.java 1970-01-01 00:00:00 +0000
@@ -1,123 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import static org.hisp.dhis.api.utils.ContextUtils.CONTENT_TYPE_JSON;
-
-import java.util.Collection;
-
-import org.apache.struts2.ServletActionContext;
-import org.hisp.dhis.aggregation.AggregatedMapValue;
-import org.hisp.dhis.api.utils.ContextUtils;
-import org.hisp.dhis.api.utils.ContextUtils.CacheStrategy;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetIndicatorMapValuesAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- private ContextUtils contextUtils;
-
- public void setContextUtils( ContextUtils contextUtils )
- {
- this.contextUtils = contextUtils;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer id;
-
- public void setId( Integer id )
- {
- this.id = id;
- }
-
- private Integer periodId;
-
- public void setPeriodId( Integer periodId )
- {
- this.periodId = periodId;
- }
-
- private Integer parentId;
-
- public void setParentId( Integer parentId )
- {
- this.parentId = parentId;
- }
-
- private Integer level;
-
- public void setLevel( Integer level )
- {
- this.level = level;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private Collection<AggregatedMapValue> object;
-
- public Collection<AggregatedMapValue> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = mappingService.getIndicatorMapValues( id, periodId, parentId, level );
-
- contextUtils.configureResponse( ServletActionContext.getResponse(), CONTENT_TYPE_JSON, CacheStrategy.RESPECT_SYSTEM_SETTING, null, false );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetIndicatorsByIndicatorGroupAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetIndicatorsByIndicatorGroupAction.java 2012-01-20 10:38:11 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetIndicatorsByIndicatorGroupAction.java 1970-01-01 00:00:00 +0000
@@ -1,104 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
-import org.hisp.dhis.indicator.Indicator;
-import org.hisp.dhis.indicator.IndicatorGroup;
-import org.hisp.dhis.indicator.IndicatorService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Lars Helge Overland
- * @version $Id$
- */
-public class GetIndicatorsByIndicatorGroupAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private IndicatorService indicatorService;
-
- public void setIndicatorService( IndicatorService indicatorService )
- {
- this.indicatorService = indicatorService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer indicatorGroupId;
-
- public void setIndicatorGroupId( Integer indicatorGroupId )
- {
- this.indicatorGroupId = indicatorGroupId;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<Indicator> object;
-
- public List<Indicator> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- if ( indicatorGroupId != null )
- {
- IndicatorGroup group = indicatorService.getIndicatorGroup( indicatorGroupId );
-
- if ( group != null )
- {
- object = new ArrayList<Indicator>( group.getMembers() );
-
- Collections.sort( object, new IdentifiableObjectNameComparator() );
-
- return SUCCESS;
- }
- }
-
- return NONE;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetInfrastructuralDataElementMapValuesAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetInfrastructuralDataElementMapValuesAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetInfrastructuralDataElementMapValuesAction.java 1970-01-01 00:00:00 +0000
@@ -1,95 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.Collection;
-
-import org.hisp.dhis.aggregation.AggregatedMapValue;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetInfrastructuralDataElementMapValuesAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer periodId;
-
- public void setPeriodId( Integer periodId )
- {
- this.periodId = periodId;
- }
-
- private Integer organisationUnitId;
-
- public void setOrganisationUnitId( Integer organisationUnitId )
- {
- this.organisationUnitId = organisationUnitId;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private Collection<AggregatedMapValue> object;
-
- public Collection<AggregatedMapValue> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = mappingService.getInfrastructuralDataElementMapValues( periodId, organisationUnitId );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLayersByTypeAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLayersByTypeAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLayersByTypeAction.java 1970-01-01 00:00:00 +0000
@@ -1,92 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.mapping.MapLayer;
-import org.hisp.dhis.mapping.MappingService;
-import org.hisp.dhis.mapping.comparator.MapLayerNameComparator;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetMapLayersByTypeAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private String type;
-
- public void setType( String type )
- {
- this.type = type;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<MapLayer> object;
-
- public List<MapLayer> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- {
- object = new ArrayList<MapLayer>( mappingService.getMapLayersByType( type ) );
-
- Collections.sort( object, new MapLayerNameComparator() );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLegendSetAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLegendSetAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLegendSetAction.java 1970-01-01 00:00:00 +0000
@@ -1,86 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import org.hisp.dhis.mapping.MapLegendSet;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetMapLegendSetAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private int id;
-
- public void setId( int id )
- {
- this.id = id;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private MapLegendSet object;
-
- public MapLegendSet getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = mappingService.getMapLegendSet( id );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLegendsByMapLegendSetAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLegendsByMapLegendSetAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapLegendsByMapLegendSetAction.java 1970-01-01 00:00:00 +0000
@@ -1,94 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.mapping.MapLegend;
-import org.hisp.dhis.mapping.MappingService;
-import org.hisp.dhis.mapping.comparator.MapLegendComparator;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetMapLegendsByMapLegendSetAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private int mapLegendSetId;
-
- public void setMapLegendSetId( int mapLegendSetId )
- {
- this.mapLegendSetId = mapLegendSetId;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<MapLegend> object;
-
- public List<MapLegend> getObject()
- {
- return this.object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- this.object = new ArrayList<MapLegend>( this.mappingService.getMapLegendSet( this.mapLegendSetId )
- .getMapLegends() );
-
- Collections.sort( this.object, new MapLegendComparator() );
-
- return SUCCESS;
- }
-}
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapUserSettingsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapUserSettingsAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapUserSettingsAction.java 1970-01-01 00:00:00 +0000
@@ -1,78 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import static org.hisp.dhis.mapping.MappingService.KEY_MAP_DATE_TYPE;
-import static org.hisp.dhis.mapping.MappingService.MAP_DATE_TYPE_FIXED;
-
-import org.hisp.dhis.user.UserSettingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetMapUserSettingsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private UserSettingService userSettingService;
-
- public void setUserSettingService( UserSettingService userSettingService )
- {
- this.userSettingService = userSettingService;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private String mapDateType;
-
- public String getMapDateType()
- {
- return mapDateType;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
-
- public String execute()
- throws Exception
- {
- mapDateType = (String) userSettingService.getUserSetting( KEY_MAP_DATE_TYPE, MAP_DATE_TYPE_FIXED );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapViewAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapViewAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetMapViewAction.java 1970-01-01 00:00:00 +0000
@@ -1,86 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import org.hisp.dhis.mapping.MapView;
-import org.hisp.dhis.mapping.MappingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetMapViewAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private MappingService mappingService;
-
- public void setMappingService( MappingService mappingService )
- {
- this.mappingService = mappingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer id;
-
- public void setId( Integer id )
- {
- this.id = id;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private MapView object;
-
- public MapView getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = mappingService.getMapView( id );
-
- return SUCCESS;
- }
-}
\ No newline at end of file
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetOrganisationUnitLevelsByFeatureTypeAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetOrganisationUnitLevelsByFeatureTypeAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetOrganisationUnitLevelsByFeatureTypeAction.java 1970-01-01 00:00:00 +0000
@@ -1,100 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.Arrays;
-import java.util.List;
-
-import org.hisp.dhis.organisationunit.OrganisationUnit;
-import org.hisp.dhis.organisationunit.OrganisationUnitLevel;
-import org.hisp.dhis.organisationunit.OrganisationUnitService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class GetOrganisationUnitLevelsByFeatureTypeAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private OrganisationUnitService organisationUnitService;
-
- public void setOrganisationUnitService( OrganisationUnitService organisationUnitService )
- {
- this.organisationUnitService = organisationUnitService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private String featureType;
-
- public void setFeatureType( String featureType )
- {
- this.featureType = featureType;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<OrganisationUnitLevel> object;
-
- public List<OrganisationUnitLevel> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = organisationUnitService.getOrganisationUnitLevels();
-
- if ( featureType.equals( OrganisationUnit.FEATURETYPE_MULTIPOLYGON ) )
- {
- object.remove( object.size() - 1 );
- }
-
- else if ( featureType.equals( OrganisationUnit.FEATURETYPE_POINT ) )
- {
- object = Arrays.asList( object.get( object.size() - 1 ) );
- }
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetOrganisationUnitsAtLevelAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetOrganisationUnitsAtLevelAction.java 2012-01-20 10:38:11 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/GetOrganisationUnitsAtLevelAction.java 1970-01-01 00:00:00 +0000
@@ -1,93 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
-import org.hisp.dhis.organisationunit.OrganisationUnit;
-import org.hisp.dhis.organisationunit.OrganisationUnitService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Lars Helge Overland
- * @version $Id$
- */
-public class GetOrganisationUnitsAtLevelAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private OrganisationUnitService organisationUnitService;
-
- public void setOrganisationUnitService( OrganisationUnitService organisationUnitService )
- {
- this.organisationUnitService = organisationUnitService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private Integer level;
-
- public void setLevel( Integer level )
- {
- this.level = level;
- }
-
- // -------------------------------------------------------------------------
- // Output
- // -------------------------------------------------------------------------
-
- private List<OrganisationUnit> object;
-
- public List<OrganisationUnit> getObject()
- {
- return object;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- object = new ArrayList<OrganisationUnit>( organisationUnitService.getOrganisationUnitsAtLevel( level ) );
-
- Collections.sort( object, new IdentifiableObjectNameComparator() );
-
- return SUCCESS;
- }
-}
=== removed file 'dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/SetMapUserSettingsAction.java'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/SetMapUserSettingsAction.java 2011-12-26 10:07:59 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/java/org/hisp/dhis/mapping/action/SetMapUserSettingsAction.java 1970-01-01 00:00:00 +0000
@@ -1,79 +0,0 @@
-package org.hisp.dhis.mapping.action;
-
-/*
- * Copyright (c) 2004-2012, University of Oslo
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- * * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- * * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-import static org.hisp.dhis.mapping.MappingService.KEY_MAP_DATE_TYPE;
-
-import org.hisp.dhis.user.UserSettingService;
-
-import com.opensymphony.xwork2.Action;
-
-/**
- * @author Jan Henrik Overland
- * @version $Id$
- */
-public class SetMapUserSettingsAction
- implements Action
-{
- // -------------------------------------------------------------------------
- // Dependencies
- // -------------------------------------------------------------------------
-
- private UserSettingService userSettingService;
-
- public void setUserSettingService( UserSettingService userSettingService )
- {
- this.userSettingService = userSettingService;
- }
-
- // -------------------------------------------------------------------------
- // Input
- // -------------------------------------------------------------------------
-
- private String mapDateType;
-
- public void setMapDateType( String mapDateType )
- {
- this.mapDateType = mapDateType;
- }
-
- // -------------------------------------------------------------------------
- // Action implementation
- // -------------------------------------------------------------------------
-
- public String execute()
- throws Exception
- {
- if ( mapDateType != null )
- {
- userSettingService.saveUserSetting( KEY_MAP_DATE_TYPE, mapDateType );
- }
-
- return SUCCESS;
- }
-}
=== modified file 'dhis-2/dhis-web/dhis-web-mapping/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/resources/META-INF/dhis/beans.xml 2012-12-14 13:46:47 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/resources/META-INF/dhis/beans.xml 2013-05-24 13:32:24 +0000
@@ -20,42 +20,21 @@
<!-- OrganisationUnit -->
- <bean id="org.hisp.dhis.mapping.action.GetAllOrganisationUnitLevelsAction"
- class="org.hisp.dhis.mapping.action.GetAllOrganisationUnitLevelsAction"
- scope="prototype">
- <property name="organisationUnitService"
- ref="org.hisp.dhis.organisationunit.OrganisationUnitService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetOrganisationUnitLevelsByFeatureTypeAction"
- class="org.hisp.dhis.mapping.action.GetOrganisationUnitLevelsByFeatureTypeAction"
- scope="prototype">
- <property name="organisationUnitService"
- ref="org.hisp.dhis.organisationunit.OrganisationUnitService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetOrganisationUnitsAtLevelAction"
- class="org.hisp.dhis.mapping.action.GetOrganisationUnitsAtLevelAction"
- scope="prototype">
- <property name="organisationUnitService"
- ref="org.hisp.dhis.organisationunit.OrganisationUnitService" />
- </bean>
-
<bean id="org.hisp.dhis.mapping.action.GetOrganisationUnitChildrenAction"
class="org.hisp.dhis.mapping.action.GetOrganisationUnitChildrenAction"
scope="prototype">
<property name="organisationUnitService"
ref="org.hisp.dhis.organisationunit.OrganisationUnitService" />
</bean>
-
- <bean id="org.hisp.dhis.mapping.action.UpdateOrganisationUnitCoordinatesAction"
+
+ <bean id="org.hisp.dhis.mapping.action.UpdateOrganisationUnitCoordinatesAction"
class="org.hisp.dhis.mapping.action.UpdateOrganisationUnitCoordinatesAction"
scope="prototype">
<property name="organisationUnitService"
ref="org.hisp.dhis.organisationunit.OrganisationUnitService" />
</bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetOrganisationUnitInfoFacilityAction"
+
+ <bean id="org.hisp.dhis.mapping.action.GetOrganisationUnitInfoFacilityAction"
class="org.hisp.dhis.mapping.action.GetOrganisationUnitInfoFacilityAction"
scope="prototype">
<property name="organisationUnitService"
@@ -63,216 +42,27 @@
<property name="organisationUnitGroupService"
ref="org.hisp.dhis.organisationunit.OrganisationUnitGroupService" />
</bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetOrganisationUnitGroupsByGroupSetAction"
+
+ <bean id="org.hisp.dhis.mapping.action.GetOrganisationUnitGroupsByGroupSetAction"
class="org.hisp.dhis.mapping.action.GetOrganisationUnitGroupsByGroupSetAction"
scope="prototype">
<property name="organisationUnitGroupService"
ref="org.hisp.dhis.organisationunit.OrganisationUnitGroupService" />
</bean>
-
- <!-- UserSetting -->
-
- <bean id="org.hisp.dhis.mapping.action.GetMapUserSettingsAction"
- class="org.hisp.dhis.mapping.action.GetMapUserSettingsAction"
- scope="prototype">
- <property name="userSettingService" ref="org.hisp.dhis.user.UserSettingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.SetMapUserSettingsAction"
- class="org.hisp.dhis.mapping.action.SetMapUserSettingsAction"
- scope="prototype">
- <property name="userSettingService" ref="org.hisp.dhis.user.UserSettingService" />
- </bean>
-
- <!-- SystemSetting -->
-
- <bean id="org.hisp.dhis.mapping.action.DeleteMapSystemSettingsAction"
- class="org.hisp.dhis.mapping.action.DeleteMapSystemSettingsAction"
- scope="prototype">
- <property name="systemSettingManager" ref="org.hisp.dhis.setting.SystemSettingManager" />
- </bean>
-
- <!-- Map values -->
-
- <bean id="org.hisp.dhis.mapping.action.GetIndicatorMapValuesAction"
- class="org.hisp.dhis.mapping.action.GetIndicatorMapValuesAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- <property name="contextUtils" ref="contextUtils" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetDataElementMapValuesAction"
- class="org.hisp.dhis.mapping.action.GetDataElementMapValuesAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- <property name="contextUtils" ref="contextUtils" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetInfrastructuralDataElementMapValuesAction"
- class="org.hisp.dhis.mapping.action.GetInfrastructuralDataElementMapValuesAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <!-- MapLegend -->
-
- <bean id="org.hisp.dhis.mapping.action.AddOrUpdateMapLegendAction"
- class="org.hisp.dhis.mapping.action.AddOrUpdateMapLegendAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.DeleteMapLegendAction"
- class="org.hisp.dhis.mapping.action.DeleteMapLegendAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetAllMapLegendsAction"
- class="org.hisp.dhis.mapping.action.GetAllMapLegendsAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetMapLegendsByMapLegendSetAction"
- class="org.hisp.dhis.mapping.action.GetMapLegendsByMapLegendSetAction"
- scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <!-- MapLegendSet -->
-
- <bean id="org.hisp.dhis.mapping.action.AddOrUpdateMapLegendSetAction"
- class="org.hisp.dhis.mapping.action.AddOrUpdateMapLegendSetAction"
- scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.DeleteMapLegendSetAction"
- class="org.hisp.dhis.mapping.action.DeleteMapLegendSetAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetAllMapLegendSetsAction"
- class="org.hisp.dhis.mapping.action.GetAllMapLegendSetsAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetMapLegendSetAction"
- class="org.hisp.dhis.mapping.action.GetMapLegendSetAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean
- id="org.hisp.dhis.mapping.action.AssignIndicatorsToMapLegendSetAction"
- class="org.hisp.dhis.mapping.action.AssignIndicatorsToMapLegendSetAction"
- scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- <property name="indicatorService" ref="org.hisp.dhis.indicator.IndicatorService" />
- </bean>
-
- <bean
- id="org.hisp.dhis.mapping.action.AssignDataElementsToMapLegendSetAction"
- class="org.hisp.dhis.mapping.action.AssignDataElementsToMapLegendSetAction"
- scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- <property name="dataElementService" ref="org.hisp.dhis.dataelement.DataElementService" />
- </bean>
<!-- Map -->
<bean id="org.hisp.dhis.mapping.action.RenameMapAction" class="org.hisp.dhis.mapping.action.RenameMapAction"
scope="prototype"/>
- <!-- MapView -->
-
- <bean id="org.hisp.dhis.mapping.action.DeleteMapViewAction" class="org.hisp.dhis.mapping.action.DeleteMapViewAction"
- scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetMapViewAction" class="org.hisp.dhis.mapping.action.GetMapViewAction"
- scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetAllMapViewsAction"
- class="org.hisp.dhis.mapping.action.GetAllMapViewsAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.AddMapViewToDashboardAction"
- class="org.hisp.dhis.mapping.action.AddMapViewToDashboardAction"
- scope="prototype">
- <property name="currentUserService" ref="org.hisp.dhis.user.CurrentUserService" />
- <property name="dashboardService" ref="org.hisp.dhis.dashboard.DashboardService" />
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <!-- MapLayer -->
-
- <bean id="org.hisp.dhis.mapping.action.AddOrUpdateMapLayerAction"
- class="org.hisp.dhis.mapping.action.AddOrUpdateMapLayerAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.DeleteMapLayerAction"
- class="org.hisp.dhis.mapping.action.DeleteMapLayerAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetAllMapLayersAction"
- class="org.hisp.dhis.mapping.action.GetAllMapLayersAction" scope="prototype">
- <property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetMapLayersByTypeAction"
- class="org.hisp.dhis.mapping.action.GetMapLayersByTypeAction" scope="prototype">
+ <!-- MapValues -->
+
+ <bean id="org.hisp.dhis.mapping.action.GetInfrastructuralDataElementMapValuesAction"
+ class="org.hisp.dhis.mapping.action.GetInfrastructuralDataElementMapValuesAction" scope="prototype">
<property name="mappingService" ref="org.hisp.dhis.mapping.MappingService" />
</bean>
- <!-- Indicator -->
-
- <bean id="org.hisp.dhis.mapping.action.GetAllIndicatorGroupsAction"
- class="org.hisp.dhis.mapping.action.GetAllIndicatorGroupsAction"
- scope="prototype">
- <property name="indicatorService" ref="org.hisp.dhis.indicator.IndicatorService" />
- </bean>
-
- <bean
- id="org.hisp.dhis.mapping.action.GetIndicatorsByIndicatorGroupAction"
- class="org.hisp.dhis.mapping.action.GetIndicatorsByIndicatorGroupAction"
- scope="prototype">
- <property name="indicatorService" ref="org.hisp.dhis.indicator.IndicatorService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetAllIndicatorsAction"
- class="org.hisp.dhis.mapping.action.GetAllIndicatorsAction" scope="prototype">
- <property name="indicatorService" ref="org.hisp.dhis.indicator.IndicatorService" />
- </bean>
-
- <!-- DataElement -->
-
- <bean id="org.hisp.dhis.mapping.action.GetAllDataElementGroupSetsAction"
- class="org.hisp.dhis.mapping.action.GetAllDataElementGroupSetsAction"
- scope="prototype">
- <property name="dataElementService" ref="org.hisp.dhis.dataelement.DataElementService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetAllDataElementGroupsAction"
- class="org.hisp.dhis.mapping.action.GetAllDataElementGroupsAction"
- scope="prototype">
- <property name="dataElementService" ref="org.hisp.dhis.dataelement.DataElementService" />
- </bean>
-
- <bean
- id="org.hisp.dhis.mapping.action.GetDataElementsByDataElementGroupAction"
- class="org.hisp.dhis.mapping.action.GetDataElementsByDataElementGroupAction"
- scope="prototype">
- <property name="dataElementService" ref="org.hisp.dhis.dataelement.DataElementService" />
- </bean>
-
- <bean id="org.hisp.dhis.mapping.action.GetAllDataElementsAction"
- class="org.hisp.dhis.mapping.action.GetAllDataElementsAction" scope="prototype">
- <property name="dataElementService" ref="org.hisp.dhis.dataelement.DataElementService" />
- </bean>
-
- <!-- Period -->
+<!-- Period -->
<bean id="org.hisp.dhis.mapping.action.GetAllPeriodTypesAction"
class="org.hisp.dhis.mapping.action.GetAllPeriodTypesAction" scope="prototype">
@@ -294,15 +84,6 @@
ref="org.hisp.dhis.organisationunit.OrganisationUnitService" />
</bean>
- <bean id="org.hisp.dhis.mapping.action.GetGeoJsonWithValuesAction"
- class="org.hisp.dhis.mapping.action.GetGeoJsonWithValuesAction"
- scope="prototype">
- <property name="organisationUnitService"
- ref="org.hisp.dhis.organisationunit.OrganisationUnitService" />
- <property name="mappingService"
- ref="org.hisp.dhis.mapping.MappingService" />
- </bean>
-
<bean id="org.hisp.dhis.mapping.action.GetGeoJsonFacilitiesAction"
class="org.hisp.dhis.mapping.action.GetGeoJsonFacilitiesAction"
scope="prototype">
=== modified file 'dhis-2/dhis-web/dhis-web-mapping/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/resources/struts.xml 2013-03-13 13:59:41 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/resources/struts.xml 2013-05-24 14:04:12 +0000
@@ -14,6 +14,13 @@
<action name="index" class="org.hisp.dhis.mapping.action.NoAction">
<result name="success" type="redirect">app/index.html</result>
</action>
+
+ <!-- Security -->
+
+ <action name="deleteMapLegendSet" class="org.hisp.dhis.mapping.action.NoAction">
+ <result name="success" type="velocity-json">/dhis-web-mapping/void.vm</result>
+ <param name="requiredAuthorities">F_GIS_ADMIN</param>
+ </action>
<!-- Initialize -->
@@ -21,36 +28,8 @@
<result name="success" type="velocity-json">/dhis-web-mapping/jsonInitialize.vm</result>
</action>
- <!-- UserSetting -->
-
- <action name="getMapUserSettings" class="org.hisp.dhis.mapping.action.GetMapUserSettingsAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/jsonUserSettings.vm</result>
- </action>
-
- <action name="setMapUserSettings" class="org.hisp.dhis.mapping.action.SetMapUserSettingsAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm</result>
- </action>
-
- <!-- SystemSetting -->
-
- <action name="deleteMapSystemSettings" class="org.hisp.dhis.mapping.action.DeleteMapSystemSettingsAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm</result>
- </action>
-
<!-- OrganisationUnit -->
- <action name="getAllOrganisationUnitLevels" class="org.hisp.dhis.mapping.action.GetAllOrganisationUnitLevelsAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/jsonOrganisationUnitLevels.vm</result>
- </action>
-
- <action name="getOrganisationUnitLevelsByFeatureType" class="org.hisp.dhis.mapping.action.GetOrganisationUnitLevelsByFeatureTypeAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/jsonOrganisationUnitLevels.vm</result>
- </action>
-
- <action name="getOrganisationUnitsAtLevel" class="org.hisp.dhis.mapping.action.GetOrganisationUnitsAtLevelAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/jsonminOrganisationUnits.vm</result>
- </action>
-
<action name="getOrganisationUnitChildren" class="org.hisp.dhis.mapping.action.GetOrganisationUnitChildrenAction">
<result name="success" type="velocity-json">/dhis-web-mapping/jsonOrganisationUnitChildren.vm</result>
</action>
@@ -59,33 +38,22 @@
<result name="success" type="velocity-json">/dhis-web-mapping/void.vm</result>
</action>
- <action name="getFacilityInfo" class="org.hisp.dhis.mapping.action.GetOrganisationUnitInfoFacilityAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/jsonminFacilityInfo.vm</result>
- </action>
+ <action name="getFacilityInfo" class="org.hisp.dhis.mapping.action.GetOrganisationUnitInfoFacilityAction">
+ <result name="success" type="velocity-json">/dhis-web-mapping/jsonminFacilityInfo.vm</result>
+ </action>
<action name="getOrganisationUnitGroupsByGroupSet" class="org.hisp.dhis.mapping.action.GetOrganisationUnitGroupsByGroupSetAction">
<result name="success" type="velocity-json">/dhis-web-mapping/jsonminOrganisationUnitGroups.vm</result>
</action>
- <!-- OrganisationUnitLevel -->
-
- <action name="getOrganisationUnitLevels" class="org.hisp.dhis.mapping.action.GetOrganisationUnitLevelsAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/jsonOrganisationUnitLevels.vm</result>
- </action>
-
- <!-- Map values -->
-
- <action name="getIndicatorMapValues" class="org.hisp.dhis.mapping.action.GetIndicatorMapValuesAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/jsonminAggregatedMapValues.vm</result>
- </action>
-
- <action name="getDataElementMapValues"
- class="org.hisp.dhis.mapping.action.GetDataElementMapValuesAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonminAggregatedMapValues.vm
- </result>
- </action>
-
+ <!-- Map -->
+
+ <action name="renameMap" class="org.hisp.dhis.mapping.action.RenameMapAction">
+ <result name="success" type="velocity-json">/dhis-web-mapping/void.vm</result>
+ </action>
+
+ <!-- MapValues -->
+
<action name="getInfrastructuralDataElementMapValues"
class="org.hisp.dhis.mapping.action.GetInfrastructuralDataElementMapValuesAction">
<result name="success" type="velocity-json">
@@ -93,200 +61,6 @@
</result>
</action>
- <!-- MapLegend -->
-
- <action name="addOrUpdateMapLegend"
- class="org.hisp.dhis.mapping.action.AddOrUpdateMapLegendAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm
- </result>
- <param name="requiredAuthorities">F_GIS_ADMIN</param>
- </action>
-
- <action name="deleteMapLegend"
- class="org.hisp.dhis.mapping.action.DeleteMapLegendAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm
- </result>
- <param name="requiredAuthorities">F_GIS_ADMIN</param>
- </action>
-
- <action name="getAllMapLegends"
- class="org.hisp.dhis.mapping.action.GetAllMapLegendsAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonMapLegends.vm
- </result>
- </action>
-
- <action name="getMapLegendsByMapLegendSet"
- class="org.hisp.dhis.mapping.action.GetMapLegendsByMapLegendSetAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonMapLegends.vm
- </result>
- </action>
-
- <!-- MapLegendSet -->
-
- <action name="addOrUpdateMapLegendSet"
- class="org.hisp.dhis.mapping.action.AddOrUpdateMapLegendSetAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm
- </result>
- <param name="requiredAuthorities">F_GIS_ADMIN</param>
- </action>
-
- <action name="deleteMapLegendSet"
- class="org.hisp.dhis.mapping.action.DeleteMapLegendSetAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm
- </result>
- <param name="requiredAuthorities">F_GIS_ADMIN</param>
- </action>
-
- <action name="getAllMapLegendSets"
- class="org.hisp.dhis.mapping.action.GetAllMapLegendSetsAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonminMapLegendSets.vm
- </result>
- </action>
-
- <action name="getMapLegendSet"
- class="org.hisp.dhis.mapping.action.GetMapLegendSetAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonMapLegendSet.vm
- </result>
- </action>
-
- <action name="assignIndicatorsToMapLegendSet"
- class="org.hisp.dhis.mapping.action.AssignIndicatorsToMapLegendSetAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm
- </result>
- </action>
-
- <action name="assignDataElementsToMapLegendSet"
- class="org.hisp.dhis.mapping.action.AssignDataElementsToMapLegendSetAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm
- </result>
- </action>
-
- <!-- Map -->
-
- <action name="renameMap" class="org.hisp.dhis.mapping.action.RenameMapAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm</result>
- </action>
-
- <!-- MapView -->
-
- <action name="deleteMapView" class="org.hisp.dhis.mapping.action.DeleteMapViewAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm</result>
- </action>
-
- <action name="getMapView" class="org.hisp.dhis.mapping.action.GetMapViewAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/jsonMapView.vm
- </result>
- </action>
-
- <action name="getAllMapViews"
- class="org.hisp.dhis.mapping.action.GetAllMapViewsAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/jsonMapViews.vm
- </result>
- </action>
-
- <action name="getAllMapViewsMin"
- class="org.hisp.dhis.mapping.action.GetAllMapViewsAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonminMapViews.vm
- </result>
- </action>
-
- <action name="addMapViewToDashboard"
- class="org.hisp.dhis.mapping.action.AddMapViewToDashboardAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm
- </result>
- </action>
-
- <!-- MapLayer -->
-
- <action name="addOrUpdateMapLayer"
- class="org.hisp.dhis.mapping.action.AddOrUpdateMapLayerAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm
- </result>
- <param name="requiredAuthorities">F_GIS_ADMIN</param>
- </action>
-
- <action name="deleteMapLayer"
- class="org.hisp.dhis.mapping.action.DeleteMapLayerAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/void.vm
- </result>
- <param name="requiredAuthorities">F_GIS_ADMIN</param>
- </action>
-
- <action name="getAllMapLayers"
- class="org.hisp.dhis.mapping.action.GetAllMapLayersAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonMapLayers.vm
- </result>
- </action>
-
- <action name="getMapLayersByType"
- class="org.hisp.dhis.mapping.action.GetMapLayersByTypeAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonMapLayers.vm
- </result>
- </action>
-
- <!-- Indicator -->
-
- <action name="getAllIndicatorGroups"
- class="org.hisp.dhis.mapping.action.GetAllIndicatorGroupsAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonIndicatorGroups.vm
- </result>
- </action>
-
- <action name="getIndicatorsByIndicatorGroup"
- class="org.hisp.dhis.mapping.action.GetIndicatorsByIndicatorGroupAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonminIndicators.vm
- </result>
- <result name="none" type="velocity-json">
- /dhis-web-mapping/void.vm
- </result>
- </action>
-
- <action name="getAllIndicators"
- class="org.hisp.dhis.mapping.action.GetAllIndicatorsAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonminIndicators.vm
- </result>
- </action>
-
- <!-- DataElement -->
-
- <action name="getAllDataElementGroupSets"
- class="org.hisp.dhis.mapping.action.GetAllDataElementGroupSetsAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonDataElementGroupSets.vm
- </result>
- </action>
-
- <action name="getAllDataElementGroups"
- class="org.hisp.dhis.mapping.action.GetAllDataElementGroupsAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonDataElementGroups.vm
- </result>
- </action>
-
- <action name="getDataElementsByDataElementGroup"
- class="org.hisp.dhis.mapping.action.GetDataElementsByDataElementGroupAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonminDataElements.vm
- </result>
- </action>
-
- <action name="getAllDataElements"
- class="org.hisp.dhis.mapping.action.GetAllDataElementsAction">
- <result name="success" type="velocity-json">
- /dhis-web-mapping/jsonminDataElements.vm
- </result>
- </action>
-
<!-- Period -->
<action name="getAllPeriodTypes"
@@ -309,11 +83,6 @@
<result name="success" type="velocity-json">/dhis-web-mapping/geojsonmin.vm</result>
</action>
- <action name="getGeoJsonWithValues"
- class="org.hisp.dhis.mapping.action.GetGeoJsonWithValuesAction">
- <result name="success" type="velocity-json">/dhis-web-mapping/geojsonminValues.vm</result>
- </action>
-
<action name="getGeoJsonFacilities"
class="org.hisp.dhis.mapping.action.GetGeoJsonFacilitiesAction">
<result name="success" type="velocity-json">/dhis-web-mapping/geojsonFacilities.vm</result>
=== modified file 'dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/app/scripts/core.js'
--- dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/app/scripts/core.js 2013-05-16 09:32:16 +0000
+++ dhis-2/dhis-web/dhis-web-mapping/src/main/webapp/dhis-web-mapping/app/scripts/core.js 2013-05-24 12:34:17 +0000
@@ -14,21 +14,47 @@
type_vector: 'vector'
},
dimension: {
+ data: {
+ id: 'data',
+ value: 'data',
+ param: 'dx',
+ dimensionName: 'dx',
+ objectName: 'dx'
+ },
indicator: {
id: 'indicator',
- param: 'in'
+ value: 'indicators',
+ param: 'in',
+ dimensionName: 'dx',
+ objectName: 'in'
},
dataElement: {
id: 'dataElement',
- param: 'de'
+ value: 'dataElement',
+ param: 'de',
+ dimensionName: 'dx',
+ objectName: 'de'
},
period: {
id: 'period',
- param: 'pe'
+ value: 'period',
+ param: 'pe',
+ dimensionName: 'pe',
+ objectName: 'pe'
},
organisationUnit: {
id: 'organisationUnit',
- param: 'ou'
+ value: 'organisationUnit',
+ param: 'ou',
+ dimensionName: 'ou',
+ objectName: 'ou'
+ },
+ value: {
+ id: 'value',
+ value: 'value',
+ param: 'value',
+ dimensionName: 'value',
+ objectName: 'value'
}
},
widget: {
@@ -1295,52 +1321,69 @@
features = features || layer.features.slice(0);
var type = view.valueType,
- dataUrl = 'mapValues/' + gis.conf.finals.dimension[type].param + '.jsonp',
+ dimConf = gis.conf.finals.dimension,
+ paramString = '?',
indicator = gis.conf.finals.dimension.indicator,
dataElement = gis.conf.finals.dimension.dataElement,
period = gis.conf.finals.dimension.period,
- organisationUnit = gis.conf.finals.dimension.organisationUnit,
- params = {};
-
- params[type === indicator.id ? indicator.param : dataElement.param] = view[type].id;
- params[period.param] = view.period.id;
- params[organisationUnit.param] = view.parentOrganisationUnit.id;
- params.le = view.organisationUnitLevel.id;
-
- Ext.data.JsonP.request({
- url: gis.baseUrl + gis.conf.url.path_api + dataUrl,
- params: params,
+ organisationUnit = gis.conf.finals.dimension.organisationUnit;
+
+ paramString += 'dimension=ou:LEVEL-' + view.organisationUnitLevel.level + '-' + view.parentOrganisationUnit.id;
+ paramString += '&dimension=dx:' + view[type].id;
+ paramString += '&filter=pe:' + view.period.id;
+
+ Ext.Ajax.request({
+ url: gis.baseUrl + '/api/analytics.json' + paramString,
disableCaching: false,
scope: this,
success: function(r) {
- var values = r,
+ //var values = r,
+ var response = Ext.decode(r.responseText),
+ dimConf = gis.conf.finals.dimension,
featureMap = {},
valueMap = {},
+ ouIndex,
+ dxIndex,
+ valueIndex,
newFeatures = [];
- if (values.length === 0) {
- alert(GIS.i18n.no_aggregated_data_found);
+ if (!(Ext.isObject(response) && Ext.isArray(response.rows) && response.rows.length)) {
+ alert(GIS.i18n.current_selection_no_data);
olmap.mask.hide();
return;
}
- for (var i = 0; i < features.length; i++) {
- var iid = features[i].attributes.internalId;
- featureMap[iid] = true;
- }
- for (var i = 0; i < values.length; i++) {
- var iid = values[i].organisationUnitId,
- value = values[i].value;
- valueMap[iid] = value;
+ // ou index, value index
+ for (var i = 0; i < response.headers.length; i++) {
+ if (response.headers[i].name === dimConf.organisationUnit.dimensionName) {
+ ouIndex = i;
+ }
+ else if (response.headers[i].name === dimConf.data.dimensionName) {
+ dxIndex = i;
+ }
+ else if (response.headers[i].name === dimConf.value.dimensionName) {
+ valueIndex = i;
+ }
+ }
+
+ // Feature map
+ for (var i = 0, id; i < features.length; i++) {
+ var id = features[i].attributes.id;
+ featureMap[id] = true;
+ }
+
+ // Value map
+ for (var i = 0; i < response.rows.length; i++) {
+ var id = response.rows[i][ouIndex],
+ value = parseFloat(response.rows[i][valueIndex]);
+ valueMap[id] = value;
}
for (var i = 0; i < features.length; i++) {
var feature = features[i],
- iid = feature.attributes.internalId;
- if (featureMap.hasOwnProperty(iid) && valueMap.hasOwnProperty(iid)) {
- feature.attributes.value = valueMap[iid];
- //var m = Math.random();
- //feature.attributes.value = m < 0.3 ? -5 : m < 0.6 ? null : 1;
+ id = feature.attributes.id;
+ if (featureMap.hasOwnProperty(id) && valueMap.hasOwnProperty(id)) {
+ feature.attributes.value = valueMap[id];
feature.attributes.label = feature.attributes.name + ' (' + feature.attributes.value + ')';
newFeatures.push(feature);
}