on recharge si pas d'erreur

This commit is contained in:
Christophe 2022-06-03 14:12:54 +02:00
parent 4cb2349efb
commit ac6b6e1a9a

View file

@ -21,6 +21,9 @@ jQuery(function () {
dataType: 'json', dataType: 'json',
async: true, async: true,
}).done(function (retour) { }).done(function (retour) {
if (!$.isEmptyObject(retour) && !$.isEmptyObject(retour.message_erreur)) {
alert(retour.message_erreur);
} else {
if (parseInt(id) > 0) { if (parseInt(id) > 0) {
app.rechargerJson(id); app.rechargerJson(id);
app.rechargerJson_deux(id); app.rechargerJson_deux(id);
@ -35,8 +38,6 @@ jQuery(function () {
callback: function () {}, callback: function () {},
}); });
} }
if (!$.isEmptyObject(retour) && !$.isEmptyObject(retour.message_erreur)) {
alert(retour.message_erreur);
} }
}); });
}); });