mirror of
https://github.com/vitodeploy/vito.git
synced 2025-07-03 06:56:15 +00:00
[2.x] [Filament] Update deprecated getFormSchema
method to use form()
override (#354)
This commit is contained in:
@ -26,8 +26,6 @@ protected function getTableQuery(): Builder
|
||||
return BackupFile::query()->where('backup_id', $this->backup->id);
|
||||
}
|
||||
|
||||
protected static ?string $heading = '';
|
||||
|
||||
protected function getTableColumns(): array
|
||||
{
|
||||
return [
|
||||
@ -54,9 +52,12 @@ protected function applyDefaultSortingToTableQuery(Builder $query): Builder
|
||||
return $query->latest('created_at');
|
||||
}
|
||||
|
||||
public function getTable(): Table
|
||||
public function table(Table $table): Table
|
||||
{
|
||||
return $this->table
|
||||
return $table
|
||||
->heading(null)
|
||||
->query($this->getTableQuery())
|
||||
->columns($this->getTableColumns())
|
||||
->actions([
|
||||
Action::make('restore')
|
||||
->hiddenLabel()
|
||||
|
@ -24,8 +24,6 @@ protected function getTableQuery(): Builder
|
||||
return Backup::query()->where('server_id', $this->server->id);
|
||||
}
|
||||
|
||||
protected static ?string $heading = '';
|
||||
|
||||
protected function getTableColumns(): array
|
||||
{
|
||||
return [
|
||||
@ -52,9 +50,12 @@ protected function getTableColumns(): array
|
||||
];
|
||||
}
|
||||
|
||||
public function getTable(): Table
|
||||
public function table(Table $table): Table
|
||||
{
|
||||
return $this->table
|
||||
return $table
|
||||
->heading(null)
|
||||
->query($this->getTableQuery())
|
||||
->columns($this->getTableColumns())
|
||||
->actions([
|
||||
Action::make('files')
|
||||
->hiddenLabel()
|
||||
|
@ -27,8 +27,6 @@ protected function getTableQuery(): Builder
|
||||
return DatabaseUser::query()->where('server_id', $this->server->id);
|
||||
}
|
||||
|
||||
protected static ?string $heading = '';
|
||||
|
||||
protected function getTableColumns(): array
|
||||
{
|
||||
return [
|
||||
@ -46,9 +44,12 @@ protected function getTableColumns(): array
|
||||
];
|
||||
}
|
||||
|
||||
public function getTable(): Table
|
||||
public function table(Table $table): Table
|
||||
{
|
||||
return $this->table
|
||||
return $table
|
||||
->heading(null)
|
||||
->query($this->getTableQuery())
|
||||
->columns($this->getTableColumns())
|
||||
->actions([
|
||||
$this->passwordAction(),
|
||||
$this->linkAction(),
|
||||
|
@ -22,8 +22,6 @@ protected function getTableQuery(): Builder
|
||||
return Database::query()->where('server_id', $this->server->id);
|
||||
}
|
||||
|
||||
protected static ?string $heading = '';
|
||||
|
||||
protected function getTableColumns(): array
|
||||
{
|
||||
return [
|
||||
@ -41,9 +39,12 @@ protected function getTableColumns(): array
|
||||
];
|
||||
}
|
||||
|
||||
public function getTable(): Table
|
||||
public function table(Table $table): Table
|
||||
{
|
||||
return $this->table
|
||||
return $table
|
||||
->heading(null)
|
||||
->query($this->getTableQuery())
|
||||
->columns($this->getTableColumns())
|
||||
->actions([
|
||||
Action::make('delete')
|
||||
->hiddenLabel()
|
||||
|
Reference in New Issue
Block a user