0
0
mirror of https://github.com/wagtail/wagtail.git synced 2024-11-25 05:02:57 +01:00

Reinstate error reporting on image upload from #2167

This commit is contained in:
Matt Westcott 2018-01-02 23:57:47 +00:00
parent 95b394e5e5
commit 925b0bd021
3 changed files with 11 additions and 1 deletions

View File

@ -67,7 +67,8 @@ Changelog
* Fix: Style of the page unlock button was broken (Bertrand Bordage)
* Fix: Admin search no longer floods browser history (Bertrand Bordage)
* Fix: Version comparison now handles custom primary keys on inline models correctly (LB (Ben Johnston))
* Fixed error when inserting chooser panels into FieldRowPanel (Florent Osmont, Bertrand Bordage)
* Fix: Fixed error when inserting chooser panels into FieldRowPanel (Florent Osmont, Bertrand Bordage)
* Fix: Reinstated missing error reporting on image upload (Matt Westcott)
1.13.1 (17.11.2017)

View File

@ -96,6 +96,7 @@ Bug fixes
* Admin search no longer floods browser history (Bertrand Bordage)
* Version comparison now handles custom primary keys on inline models correctly (LB (Ben Johnston))
* Fixed error when inserting chooser panels into FieldRowPanel (Florent Osmont, Bertrand Bordage)
* Reinstated missing error reporting on image upload (Matt Westcott)
Upgrade considerations

View File

@ -76,6 +76,14 @@ function(modal) {
dataType: 'text',
success: function(response){
modal.loadResponseText(response);
},
error: function(response, textStatus, errorThrown) {
{% trans "Server Error" as error_label %}
{% trans "Report this error to your webmaster with the following information:" as error_message %}
message = '{{ error_message|escapejs }}<br />' + errorThrown + ' - ' + response.status;
$('#upload').append(
'<div class="help-block help-critical">' +
'<strong>{{ error_label|escapejs }}: </strong>' + message + '</div>');
}
});
}