← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 14804: Remove Tracked Entity dropdown from Advanced Search when a program is selected (just derive from ...

 

------------------------------------------------------------
revno: 14804
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Sat 2014-04-12 10:37:13 +0800
message:
  Remove Tracked Entity dropdown from Advanced Search when a program is selected (just derive from the program).
modified:
  dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js
  dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programTrackingSelect.vm
  dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/searchTrackedEntityInstanceCriteria.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-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2014-04-12 02:10:47 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2014-04-12 02:37:13 +0000
@@ -129,10 +129,7 @@
 function getSearchParams(page) {
 	var params = "ou=" + getFieldValue("orgunitId");
 	params += "&page=" + page;
-	if( getFieldValue('trackedEntity')!=''){
-		params += '&trackedEntity=' + getFieldValue('trackedEntity');
-	}
-	else if (getFieldValue('program') != '') {
+	if (getFieldValue('program') != '') {
 		params += "&program=" + getFieldValue('program');
 		if( getFieldValue('programStatus')!=""){
 			params += "&programStatus=" + getFieldValue('programStatus');
@@ -1969,12 +1966,3 @@
 	hideById('showSearchCriteriaDiv');
 }
 
-function trackedEntityOnChange()
-{
-	if( getFieldValue('trackedEntity')!=''){
-		disable('program');
-	}
-	else{
-		enable('program');
-	}
-}

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programTrackingSelect.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programTrackingSelect.vm	2014-04-11 00:54:51 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/programTrackingSelect.vm	2014-04-12 02:37:13 +0000
@@ -17,7 +17,6 @@
         disable('listEntityInstanceBtn');
         hideById('addEntityInstanceBtn');
         hideById('searchBySelectedUnitTD');
-		hideById('trackedEntityTR');
         disable('advancedSearchBtn');
         setFieldValue('searchByProgramStage', 'true');
         setFieldValue('hideLink', 'true');

=== modified file 'dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/searchTrackedEntityInstanceCriteria.vm'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/searchTrackedEntityInstanceCriteria.vm	2014-04-12 02:10:47 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/searchTrackedEntityInstanceCriteria.vm	2014-04-12 02:37:13 +0000
@@ -90,19 +90,6 @@
 			</td>
 		</tr>
 		
-		<tr id='trackedEntityTR'>
-			<td>$i18n.getString('tracked_entity')</td>
-			<td>
-				<select id='trackedEntity' name='trackedEntity' onchange='trackedEntityOnChange()'>
-					<option value="">[$i18n.getString('please_select')]</option>
-					#foreach($trackedEntity in $trackedEntities)
-						<option value="$trackedEntity.uid">$trackedEntity.name</option>
-					#end
-				</select>
-				<span id="programLoader" style="display:none;" ><img src="../images/ajax-loader-bar.gif" /></span>
-			</td>
-		</tr>
-		
 		<tr id="enrollmentSelectTR" class='hidden' >
 			<td>$i18n.getString('show')</td>
 			<td>