freekdz
$table->contentGrid()
public static function table(Table $table): Table
{
return $table
->contentGrid([
'md' => 2,
'xl' => 3,
])
->columns([
TextColumn::make('code')->sortable()
->searchable(),
ImageColumn::make('image')
->disk('public_uploads')
->label('Photo')
->width(100)
->height(100)
->defaultImageUrl(url('images/default-boardtypes.png')),
TextColumn::make('region_name')->sortable()
->searchable()
->label('Region'),
TextColumn::make('ville_name')->sortable()
->searchable()
->label('Ville - Commune')
->description(fn ($record) => ' ' . $record->commune_name .' ' ),
TextColumn::make('adresse')
->searchable()
->label('Adresse'),
TextColumn::make('type')->sortable()
->searchable()
->label('Type'),
TextColumn::make('face')->sortable()
->label('Face')
->description(fn ($record) => ' ' . $record->libre .' ' ),
])
8 replies