Lines 577-591
Link Here
|
577 |
} else { |
577 |
} else { |
578 |
table.search( term ).draw(); |
578 |
table.search( term ).draw(); |
579 |
} |
579 |
} |
580 |
clearFilter( term ); |
|
|
581 |
} |
582 |
|
583 |
function clearFilter( term ){ |
584 |
if( term == "" ){ |
585 |
$(".dt_button_clear_filter").addClass("disabled"); |
586 |
} else { |
587 |
$(".dt_button_clear_filter").removeClass("disabled"); |
588 |
} |
589 |
} |
580 |
} |
590 |
|
581 |
|
591 |
/* Custom table search configuration: If a table row |
582 |
/* Custom table search configuration: If a table row |
Lines 656-668
Link Here
|
656 |
var opt = $(this).find("option:selected").text(); |
647 |
var opt = $(this).find("option:selected").text(); |
657 |
filterDataTable( table_dt, 2, opt ); |
648 |
filterDataTable( table_dt, 2, opt ); |
658 |
}); |
649 |
}); |
659 |
|
|
|
660 |
$(".dt_button_clear_filter").on("click", function(){ |
661 |
table_dt.search('').columns().search('').draw(); |
662 |
$("#news-filter select").each(function(){ |
663 |
$(this).val(""); |
664 |
}); |
665 |
}); |
666 |
}); |
650 |
}); |
667 |
</script> |
651 |
</script> |
668 |
[% ELSE %] |
652 |
[% ELSE %] |
669 |
- |
|
|