Skip to content

Commit

Permalink
Merge pull request #14223 from Godmartinz/user-bulk-edit
Browse files Browse the repository at this point in the history
Fixed Select2 functionality in User bulk check-in Delete User
  • Loading branch information
snipe committed Feb 6, 2024
2 parents 1630e4b + 5aa3469 commit 5f8ac66
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions resources/views/users/confirm-bulk-delete.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -131,14 +131,15 @@
$(":submit").attr("disabled", "disabled");
$("[name='status_id']").on('select2:select', function (e) {
if (e.params.data.id != ""){
console.log(e.params.data.id);
$(":submit").removeAttr("disabled");
}
else {
$(":submit").attr("disabled", "disabled");
}
});
//The line below needs to be here because in mobile view the status_id select2 forgets its select2 so this makes it function properly.
$("[name='status_id']").select2();
$("[name='status_id']").on('select2:select', function (e) {
if (e.params.data.id != "") {
console.log(e.params.data.id);
$(":submit").removeAttr("disabled");
} else {
$(":submit").attr("disabled", "disabled");
}
});
</script>
@stop

0 comments on commit 5f8ac66

Please sign in to comment.