← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 12541: Fixed bug - Don't display Search and Add button when to click Clear and Close button in advanced-...

 

------------------------------------------------------------
revno: 12541
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2013-10-10 07:04:15 +0700
message:
  Fixed bug - Don't display Search and Add button when to click Clear and Close button in advanced-search person function.
modified:
  dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.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/javascript/commons.js'
--- dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-10-09 06:40:18 +0000
+++ dhis-2/dhis-web/dhis-web-caseentry/src/main/webapp/dhis-web-caseentry/javascript/commons.js	2013-10-10 00:04:15 +0000
@@ -2403,9 +2403,9 @@
 
 function clearAndCloseSearch()
 {
-	jQuery('#advancedSearchTB tr').each( function()
+	jQuery('#advancedSearchTB tr').each( function(i, item)
 	{
-		if(jQuery(this).id==undefined){
+		if( i>0 && jQuery(this).id==undefined){
 			jQuery(this).remove();
 		}
 	});