Makes sure that the confirm dialog is triggered only for visible input fields.

Signed-off-by: Marc Delisle <marc@infomarc.info>
This commit is contained in:
minhaz 2014-04-19 10:45:16 -04:00 committed by Marc Delisle
parent a432f8a1d7
commit d17889e000

View File

@ -164,7 +164,7 @@ var AJAX = {
//sometime we accidently click on a url,refresh button or back button
//operation to confirm if user want to leave page in such cases
var foundFieldNotEmpty = false;
$("input[type='text']").each(function(index){
$("input[type='text']:visible").each(function(index){
if ($(this).val().length > 0) {
foundFieldNotEmpty = true;
}