diff options
author | Thomas Duval <thomas.duval@orange.com> | 2018-10-05 16:54:37 +0200 |
---|---|---|
committer | Thomas Duval <thomas.duval@orange.com> | 2018-10-05 16:58:48 +0200 |
commit | 2e35a7e46f0929438c1c206e3116caa829f07dc6 (patch) | |
tree | 759a83b3dfefe70faeada1c3af7377f4cd89b8eb /moon_dashboard/moon/static/moon/js/util.service.js | |
parent | 2dbe655587ca98b67c1a3e3798c63fd47229adc0 (diff) |
Update code to 4.6 official version
Change-Id: Ibd0da0e476e24b2685f54693efc11f7a58d40a62
Diffstat (limited to 'moon_dashboard/moon/static/moon/js/util.service.js')
-rwxr-xr-x | moon_dashboard/moon/static/moon/js/util.service.js | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/moon_dashboard/moon/static/moon/js/util.service.js b/moon_dashboard/moon/static/moon/js/util.service.js index 18ae901d..29680a43 100755 --- a/moon_dashboard/moon/static/moon/js/util.service.js +++ b/moon_dashboard/moon/static/moon/js/util.service.js @@ -117,8 +117,12 @@ }, displayErrorFunction: function displayErrorFunction(message) { - return function() { - toast.add('error', gettext(message)); + return function(response) { + var text = gettext(message); + if (response && response.data && response.data.message) { + text += ' (' + response.data.message + ')' + } + toast.add('error', text); } }, |