--- a/src/ldt/ldt/static/ldt/js/jquery.chunked_uploads.js Thu Feb 14 12:37:22 2013 +0100
+++ b/src/ldt/ldt/static/ldt/js/jquery.chunked_uploads.js Thu Feb 14 15:05:06 2013 +0100
@@ -127,8 +127,6 @@
is_canceled = true;
//stop the download
chunked_uploads_jqXHR.abort();
- $('#pause_upload').attr('disabled', true);
- $('#resume_upload').attr('disabled', true);
//wait 1s before sending a DELETE request to the server
setTimeout(function() {
$.ajax({
@@ -140,7 +138,7 @@
$.ajax({
type: current_upload[0].delete_type,
url: current_upload[0].delete_url,
- data: authentication,
+ headers: authentication,
});
}
});
@@ -162,6 +160,16 @@
}
});
}
+ $('#pause_upload').attr('disabled', true);
+ $('#resume_upload').attr('disabled', true);
+ $('#cancel_upload').attr('disabled', true);
+ $('.progress').css(
+ 'width',
+ 0 + '%'
+ );
+ if (typeof chunked_uploads_error === "function") {
+ chunked_uploads_error();
+ }
});
$('#pause_upload').click(function (e) {
@@ -225,5 +233,4 @@
}
});
};
-
});
\ No newline at end of file