$((function(){var e=!1;$(document).on("click",".btn-export-data",(function(o){if(o.preventDefault(),!e){var n=$(o.currentTarget);$.ajax({url:n.attr("href"),method:"POST",xhrFields:{responseType:"blob"},beforeSend:function(){n.prop("disabled",!0).addClass("button-loading"),e=!0},success:function(e){var o=document.createElement("a"),t=window.URL.createObjectURL(e);o.href=t,o.download=n.data("filename"),document.body.append(o),o.click(),o.remove(),window.URL.revokeObjectURL(t)},error:function(e){Botble.handleError(e)},complete:function(){setTimeout((function(){n.prop("disabled",!1).removeClass("button-loading"),e=!1}),500)}})}}))}));