diff options
author | David Rothstein <drothstein@gmail.com> | 2015-03-30 17:45:25 -0400 |
---|---|---|
committer | David Rothstein <drothstein@gmail.com> | 2015-03-30 17:45:25 -0400 |
commit | bcb8761d36eb0297d8675f6af17957f9accc5b7b (patch) | |
tree | f1014b235c1aee8400efe46afbe4afaa4279a819 /misc | |
parent | 0a9d5311c576a077af33678b148dff811325085d (diff) | |
download | brdo-bcb8761d36eb0297d8675f6af17957f9accc5b7b.tar.gz brdo-bcb8761d36eb0297d8675f6af17957f9accc5b7b.tar.bz2 |
Issue #1995058 by TravisCarden, acbramley, vbouchet: Tableselect "select all" checkbox should be checked on page load if all checkboxes are ticked
Diffstat (limited to 'misc')
-rw-r--r-- | misc/tableselect.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/misc/tableselect.js b/misc/tableselect.js index 8f0cd9750..09bac1390 100644 --- a/misc/tableselect.js +++ b/misc/tableselect.js @@ -57,6 +57,10 @@ Drupal.tableSelect = function () { // Keep track of the last checked checkbox. lastChecked = e.target; }); + + // If all checkboxes are checked on page load, make sure the select-all one + // is checked too, otherwise keep unchecked. + updateSelectAll((checkboxes.length == $(checkboxes).filter(':checked').length)); }; Drupal.tableSelectRange = function (from, to, state) { |