F
Filament14mo ago
Hemith

Access the current group data in summarizer.

public function table(Table $table): Table
{
return $table
->columns([
TextColumn::make('quantity')
->summarize(Sum::make()),
])
->defaultGroup('product.name');
}
public function table(Table $table): Table
{
return $table
->columns([
TextColumn::make('quantity')
->summarize(Sum::make()),
])
->defaultGroup('product.name');
}
In this example, I'm showing the product orders table grouped by the product name showing total quantity for each. Can I get the product data in the summarizer for each group? I want to display the data like so: ( Sum of Quantity / product.total_quantity). Is this possible?
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server