mirror of
https://github.com/Einundzwanzig-Podcast/einundzwanzig-portal.git
synced 2025-12-11 06:46:47 +00:00
event calendar
This commit is contained in:
@@ -6,6 +6,7 @@ use App\Models\BitcoinEvent;
|
||||
use Illuminate\Database\Eloquent\Builder;
|
||||
use Rappasoft\LaravelLivewireTables\DataTableComponent;
|
||||
use Rappasoft\LaravelLivewireTables\Views\Column;
|
||||
use Rappasoft\LaravelLivewireTables\Views\Filters\TextFilter;
|
||||
|
||||
class BitcoinEventTable extends DataTableComponent
|
||||
{
|
||||
@@ -34,6 +35,17 @@ class BitcoinEventTable extends DataTableComponent
|
||||
->setPerPage(10);
|
||||
}
|
||||
|
||||
public function filters(): array
|
||||
{
|
||||
return [
|
||||
TextFilter::make('Event by ID', 'byid')
|
||||
->hiddenFromMenus()
|
||||
->filter(function (Builder $builder, string $value) {
|
||||
$builder->whereIn('bitcoin_events.id', str($value)->explode(','));
|
||||
}),
|
||||
];
|
||||
}
|
||||
|
||||
public function columns(): array
|
||||
{
|
||||
return [
|
||||
|
||||
Reference in New Issue
Block a user