How to add a static row at the top in table
How do I show static entry in the table which is not in the database .
Want to show name and email as like we do in normal html.
how to add a static row at the top
public static function table(Table $table): Table
{
return $table
->columns([
Tables\Columns\TextColumn::make('name') ->searchable()->sortable(), Tables\Columns\TextColumn::make('email') ->searchable()->sortable(),
]) ->defaultSort('id', 'desc') ->filters([ ]) ->actions([
]) ->bulkActions([ ]);
}
->columns([
Tables\Columns\TextColumn::make('name') ->searchable()->sortable(), Tables\Columns\TextColumn::make('email') ->searchable()->sortable(),
]) ->defaultSort('id', 'desc') ->filters([ ]) ->actions([
]) ->bulkActions([ ]);
}
1 Reply
Maybe via sushi or using a database view as a model
https://filamentphp.com/docs/3.x/support/overview#eloquent-models