← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 232: Name property added to Map object.

 

------------------------------------------------------------
revno: 232
committer: Jan Henrik Overland janhenrik.overland@xxxxxxxxx
branch nick: trunk
timestamp: Thu 2009-04-23 13:51:19 +0200
message:
  Name property added to Map object.
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/Map.java
  dhis-2/dhis-services/dhis-service-mapping/src/main/resources/org/hisp/dhis/mapping/hibernate/Map.hbm.xml
  dhis-2/dhis-services/dhis-service-mapping/src/main/resources/org/hisp/dhis/mapping/hibernate/MapOrganisationUnitRelation.hbm.xml

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/Map.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/Map.java	2009-04-21 13:10:55 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/Map.java	2009-04-23 11:51:19 +0000
@@ -39,6 +39,8 @@
 public class Map
 {
     private int id;
+    
+    private String name;
 
     private String mapLayerPath;
     
@@ -62,9 +64,10 @@
     {
     }
 
-    public Map( String mapLayerPath, OrganisationUnit organisationUnit, OrganisationUnitLevel organisationUnitLevel, 
+    public Map( String name, String mapLayerPath, OrganisationUnit organisationUnit, OrganisationUnitLevel organisationUnitLevel, 
         String uniqueColumn, String nameColumn, String longitude, String latitude, int zoom, Set<String> staticMapLayerPaths )
     {
+        this.name = name;
         this.mapLayerPath = mapLayerPath;
         this.organisationUnit = organisationUnit;
         this.organisationUnitLevel = organisationUnitLevel;
@@ -123,6 +126,16 @@
         this.id = id;
     }
     
+    public String getName()
+    {
+        return name;
+    }
+
+    public void setName( String name )
+    {
+        this.name = name;
+    }
+    
     public String getMapLayerPath()
     {
         return mapLayerPath;

=== modified file 'dhis-2/dhis-services/dhis-service-mapping/src/main/resources/org/hisp/dhis/mapping/hibernate/Map.hbm.xml'
--- dhis-2/dhis-services/dhis-service-mapping/src/main/resources/org/hisp/dhis/mapping/hibernate/Map.hbm.xml	2009-04-14 12:17:30 +0000
+++ dhis-2/dhis-services/dhis-service-mapping/src/main/resources/org/hisp/dhis/mapping/hibernate/Map.hbm.xml	2009-04-23 11:51:19 +0000
@@ -7,27 +7,29 @@
 	
 	<class name="org.hisp.dhis.mapping.Map" table="map">
     
-    <id name="id" column="mapid">
-		<generator class="native"/>
-    </id>
-
-	<property name="mapLayerPath" column="maplayerpath"/>
-		
-	<many-to-one name="organisationUnit" class="org.hisp.dhis.organisationunit.OrganisationUnit" 
-        column="organisationunitid" not-null="true" foreign-key="fk_map_organisationunitid"/>
-	  
-	<many-to-one name="organisationUnitLevel" class="org.hisp.dhis.organisationunit.OrganisationUnitLevel" 
-        column="organisationunitlevelid" not-null="true" foreign-key="fk_map_organisationunitlevelid"/>
-		
-	<property name="uniqueColumn" column="uniquecolumn"/>
-    
-	<property name="nameColumn" column="namecolumn"/>
-		
-	<property name="longitude" column="longitude"/>
-		
-	<property name="latitude" column="latitude"/>
-		
-	<property name="zoom" column="zoom"/>			
+    	<id name="id" column="mapid">
+			<generator class="native"/>
+		</id>
+			
+		<property name="name" column="name"/>	
+	
+		<property name="mapLayerPath" column="maplayerpath"/>
+			
+		<many-to-one name="organisationUnit" class="org.hisp.dhis.organisationunit.OrganisationUnit" 
+			column="organisationunitid" not-null="true" foreign-key="fk_map_organisationunitid"/>
+		  
+		<many-to-one name="organisationUnitLevel" class="org.hisp.dhis.organisationunit.OrganisationUnitLevel" 
+			column="organisationunitlevelid" not-null="true" foreign-key="fk_map_organisationunitlevelid"/>
+			
+		<property name="uniqueColumn" column="uniquecolumn"/>
+		
+		<property name="nameColumn" column="namecolumn"/>
+			
+		<property name="longitude" column="longitude"/>
+			
+		<property name="latitude" column="latitude"/>
+			
+		<property name="zoom" column="zoom"/>			
 	
 	</class>
 	

=== modified file 'dhis-2/dhis-services/dhis-service-mapping/src/main/resources/org/hisp/dhis/mapping/hibernate/MapOrganisationUnitRelation.hbm.xml'
--- dhis-2/dhis-services/dhis-service-mapping/src/main/resources/org/hisp/dhis/mapping/hibernate/MapOrganisationUnitRelation.hbm.xml	2009-04-06 18:55:31 +0000
+++ dhis-2/dhis-services/dhis-service-mapping/src/main/resources/org/hisp/dhis/mapping/hibernate/MapOrganisationUnitRelation.hbm.xml	2009-04-23 11:51:19 +0000
@@ -7,17 +7,17 @@
 	
 	<class name="org.hisp.dhis.mapping.MapOrganisationUnitRelation" table="mapOrganisationUnitRelation">
     
-    <id name="id" column="maporganisationunitrelationid">
-		<generator class="native"/>
-    </id>
-
-	<many-to-one name="map" class="org.hisp.dhis.mapping.Map" 
-        column="mapid" not-null="true" foreign-key="fk_maporganisationunitrelation_mapid"/>
-	  
-	<many-to-one name="organisationUnit" class="org.hisp.dhis.organisationunit.OrganisationUnit" 
-        column="organisationunitid" not-null="true" foreign-key="fk_map_organisationunitid"/>
-	  
-    <property name="featureId" column="featureid"/>
+    	<id name="id" column="maporganisationunitrelationid">
+			<generator class="native"/>
+		</id>
+	
+		<many-to-one name="map" class="org.hisp.dhis.mapping.Map" 
+			column="mapid" not-null="true" foreign-key="fk_maporganisationunitrelation_mapid"/>
+		  
+		<many-to-one name="organisationUnit" class="org.hisp.dhis.organisationunit.OrganisationUnit" 
+			column="organisationunitid" not-null="true" foreign-key="fk_map_organisationunitid"/>
+		  
+		<property name="featureId" column="featureid"/>
 		
 	</class>
 	



--
Trunk
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.