← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 8089: Single event without registration data entry error.

 

------------------------------------------------------------
revno: 8089
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2012-09-14 20:48:39 +0700
message:
  Single event without registration data entry error.
modified:
  dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/anonymousRegistration.vm
  dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/anonymousRegistration.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
=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/anonymousRegistration.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/anonymousRegistration.vm	2012-09-12 05:44:28 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/anonymousRegistration.vm	2012-09-14 13:48:39 +0000
@@ -34,6 +34,7 @@
 				</td>		
 				<td>
 					<select type="text" id="programId" name="programId" onchange='getDataElements();' class='stage-object-selected'>
+						<option value="" psid="">[$i18n.getString("please_select")]</option>
 						#foreach( $program in $programs )
 							#foreach( $programStage in $program.programStages )
 								<option value='$program.id' psid='$programStage.id' reportDateDes="$programStage.reportDateDescription">$program.name</option>

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/anonymousRegistration.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/anonymousRegistration.js	2012-09-07 09:18:04 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/anonymousRegistration.js	2012-09-14 13:48:39 +0000
@@ -13,7 +13,7 @@
 			
 			jQuery( '#programId').append( '<option value="" psid="">[' + i18n_please_select + ']</option>' );
 			for ( i in json.programs ) {
-				jQuery( '#programId').append( '<option value="' + json.programs[i].id +'" psid="' + json.programs[i].psid + '">' + json.programs[i].name + '</option>' );
+				jQuery( '#programId').append( '<option value="' + json.programs[i].id +'" psid="' + json.programs[i].programStageId + '">' + json.programs[i].name + '</option>' );
 			}
 			
 			disableCriteriaDiv();
@@ -29,6 +29,9 @@
 
 function disableCriteriaDiv()
 {
+	jQuery('#selectDiv :input').each( function( idx, item ){
+		disable(this.id);
+	});
 	jQuery('#criteriaDiv :input').each( function( idx, item ){
 		disable(this.id);
 	});
@@ -38,6 +41,9 @@
 
 function enableCriteriaDiv()
 {
+	jQuery('#selectDiv :input').each( function( idx, item ){
+		enable(this.id);
+	});
 	jQuery('#criteriaDiv :input').each( function( idx, item ){
 		enable(this.id);
 	});