diff --git a/autopost/public/autopost.js b/autopost/public/autopost.js index 0e7205c..9837930 100644 --- a/autopost/public/autopost.js +++ b/autopost/public/autopost.js @@ -662,20 +662,23 @@ $(document).ready(function() { _csrf: window.__BOOTSTRAP__.csrf }, success: function(data) { - // Supprimer visuellement les lignes - ids.forEach(function(id) { - $('#row-' + id) - .css('outline', '2px solid rgba(239,68,68,0.6)') - .fadeOut('300', function(){ $(this).remove(); }); - }); - showToast(`${ids.length} élément(s) supprimé(s)`); // Fermer la modal $('#bulkDeleteModal').fadeOut(120, function() { $(this).addClass('hidden'); }); - updateBulkActions(); + + // Recharger les données de la page courante + loadPage(currentPage || 1); + + // Mettre à jour les statistiques + $.getJSON('/autopost/stats', function(s) { + if (s) updateStatsUI(s); + }); + + // Décocher la case "Tout sélectionner" + $('#selectAll').prop('checked', false).prop('indeterminate', false); }, error: function(xhr) { let errorMsg = 'Erreur lors de la suppression en lot';