mirror of
https://github.com/vitodeploy/vito.git
synced 2025-07-04 15:32:35 +00:00
2.x - databases
This commit is contained in:
@ -23,16 +23,18 @@ protected function getTableQuery(): Builder
|
||||
return ServerLog::query()->where('server_id', $this->server->id);
|
||||
}
|
||||
|
||||
protected static ?string $heading = 'Logs';
|
||||
protected static ?string $heading = '';
|
||||
|
||||
protected function getTableColumns(): array
|
||||
{
|
||||
return [
|
||||
TextColumn::make('name')
|
||||
->label('Event')
|
||||
->searchable()
|
||||
->sortable(),
|
||||
TextColumn::make('created_at_by_timezone')
|
||||
TextColumn::make('created_at')
|
||||
->label('Created At')
|
||||
->formatStateUsing(fn ($record) => $record->created_at_by_timezone)
|
||||
->sortable(),
|
||||
];
|
||||
}
|
||||
@ -68,7 +70,8 @@ public function getTable(): Table
|
||||
])
|
||||
->actions([
|
||||
Action::make('view')
|
||||
->label('View')
|
||||
->hiddenLabel()
|
||||
->tooltip('View')
|
||||
->icon('heroicon-o-eye')
|
||||
->authorize(fn ($record) => auth()->user()->can('view', $record))
|
||||
->modalHeading('View Log')
|
||||
@ -81,7 +84,8 @@ public function getTable(): Table
|
||||
->modalSubmitAction(false)
|
||||
->modalCancelActionLabel('Close'),
|
||||
Action::make('download')
|
||||
->label('Download')
|
||||
->hiddenLabel()
|
||||
->tooltip('Download')
|
||||
->color('secondary')
|
||||
->icon('heroicon-o-archive-box-arrow-down')
|
||||
->authorize(fn ($record) => auth()->user()->can('view', $record))
|
||||
|
Reference in New Issue
Block a user