← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 2153: Work in Progress for Manpower module of Bangladesh

 

------------------------------------------------------------
revno: 2153
committer: Neeraj <neeraj.hisp@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2010-11-23 19:29:22 +0530
message:
  Work in Progress for Manpower module of Bangladesh
modified:
  dhis-2/dhis-web/dhis-web-portal/pom.xml
  local/bd/dhis-web-linelisting-manpower/src/main/resources/org/hisp/dhis/ll/i18n_module.properties
  local/bd/dhis-web-linelisting-manpower/src/main/resources/struts.xml
  local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/addEmployeeForm.vm
  local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/javascript/employee.js
  local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/javascript/form.js
  local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/updateEmployeeForm.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-portal/pom.xml'
--- dhis-2/dhis-web/dhis-web-portal/pom.xml	2010-10-28 09:17:13 +0000
+++ dhis-2/dhis-web/dhis-web-portal/pom.xml	2010-11-23 13:59:22 +0000
@@ -139,6 +139,44 @@
       <type>war</type>
     </dependency>
 	
+	<!-- India modules -->
+    
+    
+    <dependency>
+      <groupId>org.hisp.dhis</groupId>
+      <artifactId>dhis-web-dashboard</artifactId>
+      <version>${version}</version>
+      <type>war</type>
+    </dependency>
+    <dependency>
+      <groupId>org.hisp.dhis</groupId>
+      <artifactId>dhis-web-reports-national</artifactId>
+      <version>${version}</version>
+      <type>war</type>
+    </dependency>
+
+
+	<dependency>
+      <groupId>org.hisp.dhis</groupId>
+      <artifactId>dhis-web-dataentry-national</artifactId>
+      <version>${version}</version>
+      <type>war</type>
+    </dependency> 
+	
+    <dependency>
+      <groupId>org.hisp.dhis</groupId>
+      <artifactId>dhis-web-excelimport</artifactId>
+      <version>${version}</version>
+      <type>war</type>
+    </dependency>
+
+    <dependency>
+      <groupId>org.hisp.dhis</groupId>
+      <artifactId>dhis-web-maintenance-in</artifactId>
+      <version>${version}</version>
+      <type>war</type>
+    </dependency>
+	
     <!-- Vietnam modules -->
     <!--
     <dependency>

=== modified file 'local/bd/dhis-web-linelisting-manpower/src/main/resources/org/hisp/dhis/ll/i18n_module.properties'
--- local/bd/dhis-web-linelisting-manpower/src/main/resources/org/hisp/dhis/ll/i18n_module.properties	2010-11-22 14:00:26 +0000
+++ local/bd/dhis-web-linelisting-manpower/src/main/resources/org/hisp/dhis/ll/i18n_module.properties	2010-11-23 13:59:22 +0000
@@ -338,24 +338,24 @@
 confirm_delete_indicator_group					= Do you want delete this indicator ?
 update_indicator_group_member					= Update Indicator Member
 factor_cannot_be_zero							= Factor cannot be zero
-id                                = Id
-shortName                         =	Short Name
-create_new_line_list_option       =	Add Line List Option
-line_list_option                  = Line List Option
-linelisting_aggregation           = Line Listing Aggregation
-periodType                        =	Period Type
-available_line_lists_elements     =	Available Line Lists Elements
-confirm_delete_line_list_element	= Are you sure you want to delete this linelist Elements?
-specify_group_members	            =	Please Specify Group Members
-no_organisationunit_selected      = No Organisationunit Selected
-no_linelistgroup_selected         = No Line List Group Selected
-no_period_selected                = No Period Selected
-validation_rule_management        = Validation Rule Management
-define_associations               = Define Associations
+id                            		    = Id
+shortName                    		     = Short Name
+create_new_line_list_option  		     =	Add Line List Option
+line_list_option            		     = Line List Option
+linelisting_aggregation     		     = Line Listing Aggregation
+periodType                    		     =	Period Type
+available_line_lists_elements 		     =	Available Line Lists Elements
+confirm_delete_line_list_element		 = Are you sure you want to delete this linelist Elements?
+specify_group_members	          		 =	Please Specify Group Members
+no_organisationunit_selected      		 = No Organisationunit Selected
+no_linelistgroup_selected         		 = No Line List Group Selected
+no_period_selected              		 = No Period Selected
+validation_rule_management        		 = Validation Rule Management
+define_associations               		 = Define Associations
 define_linelist_group_associations       = Define Line List Group Associations
-ds_dataset_list													 = Dataset List
-from 															       = From
-to 															         = To
+ds_dataset_list							 = Dataset List
+from 									 = From
+to 										 = To
 ga_orgunit                               = OrganisationUnit
 ga_facilityby                            = OrganisationUnit By
 create_new_validation_rule               = Create New Validation Rule
@@ -367,23 +367,22 @@
 linelist_group_list                      = Line list Group List
 dataelement_list                         = DataElement List
 dataelement_group_list                   = Dataelement Ggroup List
-confirm_to_delete_employee                      = Are You sure you want to Delete this Employee?
-pdscode											= PDS Code
-dob												= Date Of Birth
-lprDate											= LPR Date
-sex												= Sex
-joinDate										= Joining Date of Government Service
-res_Add											= Residential Address
-contact_no										= Contact Number
-emer_cont_no									= Emergency Contact Number
-pdsCode_in_use										= This PDS Code is already in use
-reporting_date									= Reporting Date
-
-department_management = Department Management
-create_new_department = Create New Department
-edit_department = Update Department
-define_deparment_associations = Define Department Associations
-confirm_delete_department = Are you sure you want to delete this department?
+confirm_to_delete_employee               = Are You sure you want to Delete this Employee?
+pdscode									= PDS Code
+dob										= Date Of Birth
+lprDate									= LPR Date
+sex										= Sex
+joinDate								= Joining Date of Government Service
+res_Add									= Residential Address
+contact_no								= Contact Number
+emer_cont_no							= Emergency Contact Number
+pdsCode_in_use							= This PDS Code is already in use
+reporting_date							= Reporting Date
+department_management 					= Department Management
+create_new_department 					= Create New Department
+edit_department 						= Update Department
+define_deparment_associations 			= Define Department Associations
+confirm_delete_department 				= Are you sure you want to delete this department?
 adding_department_failed				= Adding the department failed with the following message
 saving_department_failed				= Saving the department failed with the following message
-no_post_selected = No Post Selected
\ No newline at end of file
+no_post_selected 						= No Post Selected

=== modified file 'local/bd/dhis-web-linelisting-manpower/src/main/resources/struts.xml'
--- local/bd/dhis-web-linelisting-manpower/src/main/resources/struts.xml	2010-11-22 07:28:23 +0000
+++ local/bd/dhis-web-linelisting-manpower/src/main/resources/struts.xml	2010-11-23 13:59:22 +0000
@@ -366,8 +366,8 @@
 			</result>
 			<param name="onExceptionReturn">plainTextError</param>
 		</action>
-	
-<!-- LL EmployeeList 16/10/2010 end -->  				
+		
+	<!-- LL EmployeeList 16/10/2010 end -->  				
 		
 		
 		    

=== modified file 'local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/addEmployeeForm.vm'
--- local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/addEmployeeForm.vm	2010-10-28 11:40:15 +0000
+++ local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/addEmployeeForm.vm	2010-11-23 13:59:22 +0000
@@ -39,7 +39,7 @@
 			</tr>
 			<tr>
 				<td><label for="lprDate"> $i18n.getString( "lprDate" ) ($i18n.getString( "format.date.label" )) <em title="$i18n.getString("required")"class="required">*</em></label></td>
-				<td><input type="text" id="lprDate" name="lprDate" style="width:20em"></td>
+				<td><input type="text" id="lprDate" name="lprDate" style="width:20em" onchange="validateDate( this )"></td>
 			</tr>
 			<tr>
 				<td><label for="sex"> $i18n.getString( "sex" ) <em title="$i18n.getString("required")"class="required">*</em></label></td>
@@ -52,7 +52,7 @@
 			</tr>
 			<tr>
 				<td><label for="govtserjoindate"> $i18n.getString( "joinDate" ) ($i18n.getString( "format.date.label" )) <em title="$i18n.getString("required")"class="required">*</em></label></td>
-				<td><input type="text" id="govtSerJoinDate" name="govtSerJoinDate" style="width:20em"></td>
+				<td><input type="text" id="govtSerJoinDate" name="govtSerJoinDate" style="width:20em" onchange="validateDate( this )"></td>
 			</tr>
 			<tr>
 				<td><label for="resAdd"> $i18n.getString( "res_Add" ) <em title="$i18n.getString("required")"class="required">*</em></label></td>
@@ -60,11 +60,11 @@
 			</tr>
 			<tr>
 				<td><label for="contactNo"> $i18n.getString( "contact_no" ) <em title="$i18n.getString("required")"class="required">*</em></label></td>
-				<td><input type="text" id="contactNo" name="contactNo" style="width:20em" class="{validate:{required:true,minlength:8}}"></td>
+				<td><input type="text" id="contactNo" name="contactNo" style="width:20em" class="{validate:{required:true,number:true,minlength:6}}"></td>
 			</tr>
 			<tr>
 				<td><label for="emerContactNo"> $i18n.getString( "emer_cont_no" ) <em title="$i18n.getString("required")"class="required">*</em></label></td>
-				<td><input type="text" id="emerContactNo" name="emerContactNo" style="width:20em" class="{validate:{required:true,minlength:8}}"></td>
+				<td><input type="text" id="emerContactNo" name="emerContactNo" style="width:20em" class="{validate:{required:true,number:true,minlength:6}}"></td>
 			</tr>
 			
 			<tr>

=== modified file 'local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/javascript/employee.js'
--- local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/javascript/employee.js	2010-11-22 11:37:31 +0000
+++ local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/javascript/employee.js	2010-11-23 13:59:22 +0000
@@ -44,3 +44,16 @@
     
 }
 
+function validateDate( dateType )
+{
+	var sourceDate = document.getElementById('dob').value;
+	var compareDate = dateType.value;
+	if ( sourceDate > compareDate)
+	{
+		alert("This Date can not be before than Date of Birth");
+		dateType.value = "";
+		setTimeout(function(){
+			dateType.focus();dateType.select();
+	    },2);
+	}
+}

=== modified file 'local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/javascript/form.js'
--- local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/javascript/form.js	2010-11-23 09:50:29 +0000
+++ local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/javascript/form.js	2010-11-23 13:59:22 +0000
@@ -1,5 +1,33 @@
 var currentPDSCode;
 
+function validateDate( date )
+{
+	alert("In Validate Date Function and date is " + date );
+	var sourceDate = document.getElementById('dob').value;
+	var compareDate = date.value
+	var request = new Request();
+	request.setResponseTypeXML('element');
+	request.setCallbackSuccess( elementReceived );
+	request.send( 'validateDate.action?sourceDate=' + sourceDate + '&compareDate=' + compareDate);
+}
+
+function elementReceived( dateElement )
+{
+	var type = dateElement.getAttribute( "type" );
+	if (type == 'success' )
+	{
+		
+	}
+	else if (type == 'input' )
+	{
+		alert( dateElement.firstChild.nodeValue );
+		date.value = "";
+		setTimeout(function(){
+			date.focus();date.select();
+	    },2);
+	}
+}
+
 function validatePostVacant( dataValueMapKey )
 {
 	var reportingDate = document.getElementById('reportingDate').value;

=== modified file 'local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/updateEmployeeForm.vm'
--- local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/updateEmployeeForm.vm	2010-10-28 11:40:15 +0000
+++ local/bd/dhis-web-linelisting-manpower/src/main/webapp/dhis-web-linelisting-mp/updateEmployeeForm.vm	2010-11-23 13:59:22 +0000
@@ -35,7 +35,7 @@
 			</tr>
 			<tr>
 				<td><label for="lprDate"> $i18n.getString( "lprDate" ) ($i18n.getString( "format.date.label" )) <em title="$i18n.getString("required")"class="required">*</em></label></td>
-				<td><input type="text" id="lprDate" name="lprDate" value="$employee.lprDate" style="width:20em"></td>
+				<td><input type="text" id="lprDate" name="lprDate" value="$employee.lprDate" style="width:20em" onchange="validateDate( this )"></td>
 			</tr>
 			<tr>
 				<td><label for="sex"> $i18n.getString( "sex" ) <em title="$i18n.getString("required")"class="required">*</em></label></td>
@@ -48,7 +48,7 @@
 			</tr>
 			<tr>
 				<td><label for="govtserjoindate"> $i18n.getString( "joinDate" ) ($i18n.getString( "format.date.label" )) <em title="$i18n.getString("required")"class="required">*</em></label></td>
-				<td><input type="text" id="govtSerJoinDate" name="govtSerJoinDate" value="$employee.joinDateToGovtService" style="width:20em"></td>
+				<td><input type="text" id="govtSerJoinDate" name="govtSerJoinDate" value="$employee.joinDateToGovtService" style="width:20em" onchange="validateDate( this )"></td>
 			</tr>
 			<tr>
 				<td><label for="resAdd"> $i18n.getString( "res_Add" ) <em title="$i18n.getString("required")"class="required">*</em></label></td>
@@ -56,11 +56,11 @@
 			</tr>
 			<tr>
 				<td><label for="contactNo"> $i18n.getString( "contact_no" ) <em title="$i18n.getString("required")"class="required">*</em></label></td>
-				<td><input type="text" id="contactNo" name="contactNo" value="$employee.contactNumber" style="width:20em" class="{validate:{required:true,minlength:8}}"></td>
+				<td><input type="text" id="contactNo" name="contactNo" value="$employee.contactNumber" style="width:20em" class="{validate:{required:true,number:true,minlength:6}}"></td>
 			</tr>
 			<tr>
 				<td><label for="emerContactNo"> $i18n.getString( "emer_cont_no" ) <em title="$i18n.getString("required")"class="required">*</em></label></td>
-				<td><input type="text" id="emerContactNo" name="emerContactNo" value="$employee.emergencyContactNumber" style="width:20em" class="{validate:{required:true,minlength:8}}"></td>
+				<td><input type="text" id="emerContactNo" name="emerContactNo" value="$employee.emergencyContactNumber" style="width:20em" class="{validate:{required:true,number:true,minlength:6}}"></td>
 			</tr>
 			
 			<tr>