Complex Table with Multiple Features

Filament 3

Demonstrates many features of Filament Tables: filters, summarizers, sorting, searching, header widgets, etc.

21-complex-table-multiple-features

Get the Source Code:

Only This Example

$9

One-time payment

Full source code for Complex Table with Multiple Features
Downloadable ZIP file with the source code
Lifetime access to this example
GitHub Sign in with GitHub to buy

Sign in first, then complete your $9 checkout.

Best value — all 169 examples

FilamentExamples Membership

$99 /year
or
$199 lifetime
Access to code of all 169 examples
Future new examples and updates included
FilaCheck Pro package licence included
MCP server included
View membership plans

30-day money-back guarantee

How it works

The whole table logic is in the OrderResource Filament Resource.

Table tabs are in the ListOrders class. For every tab, we modify the query based on the order status and show the order count for a particular status. Here is what the code to add tabs looks like:

public function getTabs(): array
{
return [
'in_progress' => ListRecords\Tab::make()
->badge(Order::where('status', OrderStatus::IN_PROGRESS->value)->count())
->modifyQueryUsing(fn (Builder $query) => $query->where('status', OrderStatus::IN_PROGRESS->value)),
'completed' => ListRecords\Tab::make()
->badge(Order::where('status', OrderStatus::COMPLETED->value)->count())
->modifyQueryUsing(fn (Builder $query) => $query->where('status', OrderStatus::COMPLETED->value)),
'canceled' => ListRecords\Tab::make()
->badge(Order::where('status', OrderStatus::CANCELED->value)->count())
->modifyQueryUsing(fn (Builder $query) => $query->where('status', OrderStatus::CANCELED->value)),
'priority' => ListRecords\Tab::make()
->badge(Order::where('is_priority', true)->count())
->modifyQueryUsing(fn (Builder $query) => $query->where('is_priority', true)),
];
}

Above the table, we have a widget with three stats cards showing revenue for the current day, the last seven days, and the last 30 days. The widget must be registered in the ListOrders class in the getHeaderWidgets method.

Here is the...

The FULL tutorial is available after the purchase: in the Readme file of the official repository you would get invited to.