SearchKit - Fix "all selected" checkbox when selecting a single page of results
authorColeman Watts <coleman@civicrm.org>
Tue, 22 Mar 2022 20:13:59 +0000 (16:13 -0400)
committerColeman Watts <coleman@civicrm.org>
Tue, 22 Mar 2022 20:13:59 +0000 (16:13 -0400)
ext/search_kit/ang/crmSearchTasks/traits/searchDisplayTasksTrait.service.js

index b15c67d8e732436b212e8f92451c2940d1d058ed..4e9ff99c0412c2371548b83000ab076ee830eb1e 100644 (file)
@@ -21,7 +21,7 @@
 
       // Select all rows on the current page
       selectPage: function() {
-        this.allRowsSelected = true;
+        this.allRowsSelected = (this.rowCount <= this.results.length);
         this.selectedRows = _.uniq(_.pluck(this.results, 'key'));
       },