remotes/1693045480750635534/spooky-22
Aevann1 2021-09-26 11:32:06 +02:00
parent b4d4eb134f
commit e689007a0c
1 changed files with 4 additions and 4 deletions

View File

@ -11,8 +11,8 @@
xhr.onload = function() {
if (xhr.status==204) {}
else if (xhr.status >= 200 && xhr.status < 300) {
document.getElementById('toast-post-success').toast('dispose');
document.getElementById('toast-post-success').toast('show');
$('#toast-post-success').toast('dispose');
$('#toast-post-success').toast('show');
document.getElementById('toast-post-success-text').innerText = JSON.parse(xhr.response)["message"];
callback(xhr)
return true
@ -22,8 +22,8 @@
} else {
data=JSON.parse(xhr.response);
document.getElementById('toast-post-error').toast('dispose');
document.getElementById('toast-post-error').toast('show');
$('#toast-post-error').toast('dispose');
$('#toast-post-error').toast('show');
document.getElementById('toast-post-error-text').innerText = data["error"];
return false