mirror of
https://github.com/filamentphp/filament.git
synced 2026-09-24 15:42:09 +08:00
Merge pull request #16274 from MrPunyapal/feat/group-by-support-for-exports
Fix: total rows calculation for group by in CanExportRecords trait
This commit is contained in:
@@ -130,7 +130,7 @@ trait CanExportRecords
|
||||
|
||||
$records = $action instanceof ExportTableBulkAction ? $action->getRecords() : null;
|
||||
|
||||
$totalRows = $records ? $records->count() : $query->count();
|
||||
$totalRows = $records ? $records->count() : $query->toBase()->getCountForPagination();
|
||||
$maxRows = $action->getMaxRows() ?? $totalRows;
|
||||
|
||||
if ($maxRows < $totalRows) {
|
||||
|
||||
Reference in New Issue
Block a user