Ja stosuję takie coś:
$('body').on('click', '#IdKliknietegoButtonu', function() {
var that = $(this);
if ((that.data('inprogress') || 0) == 1) { return false;}
$.ajax({
type : "GET",
dataType : "json",
url : "adresDoPlikuKtoryWykonujeAkcje/"+$(this).attr('num'),
beforeSend: function() {
that.data('inprogress', 1);
},
}).done(function( data ) {
that.data('inprogress', 0);
$("#idDivaDoKtoregoChceszZaladowacTresc_wynikJson").html(data.wynikOdebrnayZJson);
}).fail(function(jqXHR, textStatus, errorThrown) {
that.data('inprogress', 0);
alert(textStatus);
});
});