->actions([
Tables\Actions\Action::make('Decline')
->requiresConfirmation()
->action(function (GroupOrder $record) {
$declinedStatusId = OrderStatus::where('name', 'declined')->first()->id;
$record->update(['status_id' => $declinedStatusId]);
}),
Tables\Actions\Action::make('Accept')
->requiresConfirmation()
->action(function (GroupOrder $record) {
$acceptedStatusId = OrderStatus::where('name', 'accepted')->first()->id;
$record->update(['status_id' => $acceptedStatusId]);
}),
])
->actions([
Tables\Actions\Action::make('Decline')
->requiresConfirmation()
->action(function (GroupOrder $record) {
$declinedStatusId = OrderStatus::where('name', 'declined')->first()->id;
$record->update(['status_id' => $declinedStatusId]);
}),
Tables\Actions\Action::make('Accept')
->requiresConfirmation()
->action(function (GroupOrder $record) {
$acceptedStatusId = OrderStatus::where('name', 'accepted')->first()->id;
$record->update(['status_id' => $acceptedStatusId]);
}),
])