← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 6078: Included active property in add org unit ui

 

------------------------------------------------------------
revno: 6078
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2012-02-22 13:01:02 +0100
message:
  Included active property in add org unit ui
modified:
  dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/java/org/hisp/dhis/oum/action/organisationunit/AddOrganisationUnitAction.java
  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/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/java/org/hisp/dhis/oum/action/organisationunit/AddOrganisationUnitAction.java'
--- dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/java/org/hisp/dhis/oum/action/organisationunit/AddOrganisationUnitAction.java	2012-01-20 05:42:41 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/java/org/hisp/dhis/oum/action/organisationunit/AddOrganisationUnitAction.java	2012-02-22 12:01:02 +0000
@@ -131,6 +131,13 @@
         this.openingDate = openingDate;
     }
 
+    private boolean active;
+
+    public void setActive( boolean active )
+    {
+        this.active = active;
+    }
+
     private String comment;
 
     public void setComment( String comment )
@@ -254,7 +261,7 @@
         // Create organisation unit
         // ---------------------------------------------------------------------
 
-        OrganisationUnit organisationUnit = new OrganisationUnit( name, shortName, code, date, null, true, comment );
+        OrganisationUnit organisationUnit = new OrganisationUnit( name, shortName, code, date, null, active, comment );
 
         organisationUnit.setUrl( url );
         organisationUnit.setParent( parent );

=== 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	2012-02-21 13:01:40 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/resources/org/hisp/dhis/oum/i18n_module.properties	2012-02-22 12:01:02 +0000
@@ -1,5 +1,5 @@
 create_new_org_unit=Create new organisation unit
-registers_date=Registers data
+registers_data=Registers data
 crease_new_org_unit_group=Create new organisation unit group
 hierarchy_operations=Hierarchy operations
 select_an_org_unit_to_move=Select an organisation unit to move

=== 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-10-29 14:16:54 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/addOrganisationUnitForm.vm	2012-02-22 12:01:02 +0000
@@ -45,7 +45,16 @@
 		<td><label for="openingDate">$i18n.getString( "opening_date" ) ($i18n.getString( "format.date.label" )) <em title="$i18n.getString( 'required' )" class="required">*</em></label></td>
 		<td><input type="text" id="openingDate" name="openingDate" value="$format.formatDate( $defaultDate )" style="width:20em"/></td>
 		<td></td>
-	</tr>	
+	</tr>
+	<tr>
+		<td><label for="active">$i18n.getString( "registers_data" )</label></td>
+		<td>
+			<select id="active" name="active" style="min-width:20em">
+				<option value="true" selected="selected">$i18n.getString( "yes" )</option>
+				<option value="false">$i18n.getString( "no" )</option>
+			</select>
+		</td>
+	</tr>
 	<tr>
 		<td><label for="comment">$i18n.getString( "comment" )</label></td>
 		<td><textarea id="comment" name="comment" style="width:20em; height:5em"></textarea></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-10-29 14:16:54 +0000
+++ dhis-2/dhis-web/dhis-web-maintenance/dhis-web-maintenance-organisationunit/src/main/webapp/dhis-web-maintenance-organisationunit/updateOrganisationUnitForm.vm	2012-02-22 12:01:02 +0000
@@ -63,7 +63,7 @@
 	</tr>
 	#end
 	<tr>
-		<td><label for="active">$i18n.getString( "registers_date" )</label></td>
+		<td><label for="active">$i18n.getString( "registers_data" )</label></td>
 		<td>
 			<select id="active" name="active" style="min-width:20em">
 				<option value="true" #if( $organisationUnit.active ) selected="selected" #end>$i18n.getString( "yes" )</option>