Игнорируется алерт и json выводится в элемент input
<form id="my_form" method="POST" action="/convers/upload_file/" >
<input id="fileupload" type="file" name="files" >
</form>
var uploadButton = $('<button/>')
.addClass('btn btn-primary')
.text('Processing...')
.on('click', function () {
$('#my_form').submit();
var busy = false
function ajaxFormSubmit(){
e.preventDefault();
if(busy) return false;
busy = true;
var $that = $('#my_form'),
formData = new FormData($that.get(0));
$.ajax({
url: $that.attr('action'),
type: $that.attr('method'),
contentType: false,
processData: false,
data: formData,
dataType: 'json',
success: function(json){
alert(json)
setTimeout(function(){busy = false;},1000);
}
});
}
}) ;