Skip to content

Commit

Permalink
related to #2158 fix bug badge-number
Browse files Browse the repository at this point in the history
The ‘badge-number’ was not updated when a user was added or deleted, but now everything is fine.
  • Loading branch information
LintyDev committed May 31, 2024
1 parent 777d489 commit 918249d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions admin/themes/default/js/user_list.js
Original file line number Diff line number Diff line change
Expand Up @@ -2153,6 +2153,7 @@ function add_user() {
})
$("#AddUserSuccess label span:first").html(user_added_str.replace("%s", ajax_data.username));
$("#AddUserSuccess").css("display", "flex");
$('.badge-number').html(+$('.badge-number').html() + 1);
}
else {
$("#AddUser .AddUserErrors").html(data.message)
Expand All @@ -2176,6 +2177,7 @@ function delete_user(uid) {
success:function(data) {
close_user_list();
update_user_list();
$('.badge-number').html(+$('.badge-number').html() - 1);
// msg where user was deleted
//jQuery('#showAddUser .infos').html('✔ User '+username+' deleted').show();
},
Expand Down

0 comments on commit 918249d

Please sign in to comment.