Show recipe version and date in product list instead of recipe name
Deploy / deploy (push) Successful in 16s
Deploy / deploy (push) Successful in 16s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
e9ea8770e5
commit
c5b0a43928
1 file changed
+6
-2
@@ -220,8 +220,12 @@ class ProductResource extends Resource {
|
||||
->label('Name')
|
||||
->sortable()
|
||||
->searchable(),
|
||||
Tables\Columns\TextColumn::make('recipe.name')
|
||||
->label('Rezept'),
|
||||
Tables\Columns\TextColumn::make('recipe.version')
|
||||
->label('Rezept')
|
||||
->formatStateUsing(fn ($state, $record) => $record->recipe
|
||||
? 'v' . $record->recipe->version . ' · ' . $record->recipe->created_at->format('d.m.Y')
|
||||
: '—'
|
||||
),
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user