Show error when saving task

This commit is contained in:
2016-09-20 17:39:30 +02:00
parent eb1a972dbb
commit 008ffa0aa4

View File

@@ -19,6 +19,7 @@ function save_task(task_id, task_url) {
.fail(function(xhr_or_response_data) { .fail(function(xhr_or_response_data) {
// jQuery sends the response data (if JSON), or an XHR object (if not JSON). // jQuery sends the response data (if JSON), or an XHR object (if not JSON).
if (console) console.log('Failed saving', xhr_or_response_data); if (console) console.log('Failed saving', xhr_or_response_data);
$('#task-details').html(xhr_or_response_data.responseText);
}) })
.always(function() { .always(function() {
$button.attr('disabled', false); $button.attr('disabled', false);