Skip to content

Commit

Permalink
Fix Select All/None doesn't work w/ post field (checkbox_list type)
Browse files Browse the repository at this point in the history
  • Loading branch information
rilwis committed Nov 16, 2017
1 parent 173e3df commit 998c6c3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/input-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ jQuery( function ( $ ) {

$( '.rwmb-input-list-select-all-none' ).toggle(
function () {
$('input.rwmb-checkbox_list[name="' + $(this).data('name') + '[]"]').prop('checked', true);
$('input[name="' + $(this).data('name') + '[]"]').prop('checked', true);
},
function () {
$('input.rwmb-checkbox_list[name="' + $(this).data('name') + '[]"]').prop('checked', false);
$('input[name="' + $(this).data('name') + '[]"]').prop('checked', false);
}
);
} );

1 comment on commit 998c6c3

@rilwis
Copy link
Member Author

@rilwis rilwis commented on 998c6c3 Nov 16, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixes #1188

Please sign in to comment.