← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 3834: Orgunit form feature type dropdown added.

 

Merge authors:
  Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 3834 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2011-06-02 18:51:26 +0200
message:
  Orgunit form feature type dropdown added.
modified:
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/resources/org/hisp/dhis/oum/i18n_module.properties
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/resources/struts.xml
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/addOrganisationUnitForm.vm
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/updateOrganisationUnitForm.vm


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/resources/org/hisp/dhis/oum/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/resources/org/hisp/dhis/oum/i18n_module.properties	2011-05-22 12:19:06 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/resources/org/hisp/dhis/oum/i18n_module.properties	2011-06-02 16:21:56 +0000
@@ -109,6 +109,9 @@
 all													= All
 please_select_from_tree								= Please select from tree (optional)
 feature_type										= Feature type
+multipolygon										= MultiPolygon
+polygon												= Polygon
+point												= Point
 available_data_sets									= Available data sets
 selected_data_sets									= Selected data sets
 limited												= Limited

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/resources/struts.xml'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/resources/struts.xml	2011-05-27 09:06:55 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/resources/struts.xml	2011-06-02 16:49:19 +0000
@@ -43,7 +43,7 @@
 			class="org.hisp.dhis.oum.action.organisationunit.PrepareAddOrganisationUnitAction">
 			<result name="success" type="velocity">/main.vm</result>
 			<param name="page">/dhis-web-maintenance-organisationunit/addOrganisationUnitForm.vm</param>
-			<param name="javascripts">javascript/shortName.js,javascript/featureType.js,../dhis-web-commons/ouwt/ouwt.js</param>
+			<param name="javascripts">javascript/shortName.js,../dhis-web-commons/ouwt/ouwt.js</param>
 			<param name="requiredAuthorities">F_ORGANISATIONUNIT_ADD</param>
 		</action>
 
@@ -72,7 +72,7 @@
 			class="org.hisp.dhis.oum.action.organisationunit.GetOrganisationUnitAction">
 			<result name="success" type="velocity">/main.vm</result>
 			<param name="page">/dhis-web-maintenance-organisationunit/updateOrganisationUnitForm.vm</param>
-			<param name="javascripts">javascript/shortName.js,javascript/featureType.js,../dhis-web-commons/ouwt/ouwt.js</param>
+			<param name="javascripts">javascript/shortName.js,../dhis-web-commons/ouwt/ouwt.js</param>
 			<param name="requiredAuthorities">F_ORGANISATIONUNIT_UPDATE</param>
 		</action>
 

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/addOrganisationUnitForm.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/addOrganisationUnitForm.vm	2011-05-22 12:19:06 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/addOrganisationUnitForm.vm	2011-06-02 16:21:56 +0000
@@ -40,7 +40,12 @@
     </tr>
     <tr>
         <td><label for="featureType">$i18n.getString( "feature_type" )</label></td>
-        <td><input type="text" id="featureType" name="featureType" style="width:20em" readonly="readonly"/></td>
+        <td>
+            <select id="featureType" name="featureType" style="min-width:20em">
+                <option value="Polygon">$i18n.getString( "polygon" )</option>
+                <option value="Point">$i18n.getString( "point" )</option>
+            </select>
+        </td>
     </tr>
     <tr>
         <td><label for="url">$i18n.getString( "url" )</label></td>

=== modified file 'dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/updateOrganisationUnitForm.vm'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/updateOrganisationUnitForm.vm	2011-05-22 12:19:06 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/updateOrganisationUnitForm.vm	2011-06-02 16:21:56 +0000
@@ -72,7 +72,12 @@
     </tr>
     <tr>
         <td><label for="featureType">$i18n.getString( "feature_type" )</label></td>
-        <td><input type="text" id="featureType" name="featureType" value="$!encoder.htmlEncode( $organisationUnit.featureType )" style="width:20em" readonly="readonly"/></td>
+        <td>
+            <select id="featureType" name="featureType" style="min-width:20em">
+                <option value="Polygon" #if( $organisationUnit.featureType == $i18n.getString( "polygon" ) || $organisationUnit.featureType == $i18n.getString( "multipolygon" ) ) selected="selected" #end>$i18n.getString( "polygon" )</option>
+                <option value="Point" #if( $organisationUnit.featureType == $i18n.getString( "point" ) ) selected="selected" #end>$i18n.getString( "point" )</option>
+            </select>
+        </td>
     </tr>
     <tr>
         <td><label for="url">$i18n.getString( "url" )</label></td>