update
This commit is contained in:
parent
0e28d816d6
commit
a9da5e8820
7 changed files with 17 additions and 116 deletions
13
web/app/Filament/Pages/CronJobs.php
Normal file
13
web/app/Filament/Pages/CronJobs.php
Normal file
|
@ -0,0 +1,13 @@
|
|||
<?php
|
||||
|
||||
namespace App\Filament\Pages;
|
||||
|
||||
use Filament\Pages\Page;
|
||||
|
||||
class CronJobs extends Page
|
||||
{
|
||||
protected static ?string $navigationIcon = 'heroicon-o-document-text';
|
||||
|
||||
protected static string $view = 'filament.pages.cron-jobs';
|
||||
|
||||
}
|
|
@ -1,66 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Filament\Resources;
|
||||
|
||||
use App\Filament\Resources\CronJobResource\Pages;
|
||||
use App\Filament\Resources\CronJobResource\RelationManagers;
|
||||
use App\Models\CronJob;
|
||||
use Filament\Forms;
|
||||
use Filament\Forms\Form;
|
||||
use Filament\Resources\Resource;
|
||||
use Filament\Tables;
|
||||
use Filament\Tables\Table;
|
||||
use Illuminate\Database\Eloquent\Builder;
|
||||
use Illuminate\Database\Eloquent\SoftDeletingScope;
|
||||
|
||||
class CronJobResource extends Resource
|
||||
{
|
||||
protected static ?string $model = CronJob::class;
|
||||
|
||||
protected static ?string $navigationIcon = 'heroicon-o-clock';
|
||||
|
||||
protected static ?int $navigationSort = 99;
|
||||
|
||||
public static function form(Form $form): Form
|
||||
{
|
||||
return $form
|
||||
->schema([
|
||||
//
|
||||
]);
|
||||
}
|
||||
|
||||
public static function table(Table $table): Table
|
||||
{
|
||||
return $table
|
||||
->columns([
|
||||
//
|
||||
])
|
||||
->filters([
|
||||
//
|
||||
])
|
||||
->actions([
|
||||
Tables\Actions\EditAction::make(),
|
||||
])
|
||||
->bulkActions([
|
||||
Tables\Actions\BulkActionGroup::make([
|
||||
Tables\Actions\DeleteBulkAction::make(),
|
||||
]),
|
||||
]);
|
||||
}
|
||||
|
||||
public static function getRelations(): array
|
||||
{
|
||||
return [
|
||||
//
|
||||
];
|
||||
}
|
||||
|
||||
public static function getPages(): array
|
||||
{
|
||||
return [
|
||||
'index' => Pages\ListCronJobs::route('/'),
|
||||
'create' => Pages\CreateCronJob::route('/create'),
|
||||
'edit' => Pages\EditCronJob::route('/{record}/edit'),
|
||||
];
|
||||
}
|
||||
}
|
|
@ -1,12 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Filament\Resources\CronJobResource\Pages;
|
||||
|
||||
use App\Filament\Resources\CronJobResource;
|
||||
use Filament\Actions;
|
||||
use Filament\Resources\Pages\CreateRecord;
|
||||
|
||||
class CreateCronJob extends CreateRecord
|
||||
{
|
||||
protected static string $resource = CronJobResource::class;
|
||||
}
|
|
@ -1,19 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Filament\Resources\CronJobResource\Pages;
|
||||
|
||||
use App\Filament\Resources\CronJobResource;
|
||||
use Filament\Actions;
|
||||
use Filament\Resources\Pages\EditRecord;
|
||||
|
||||
class EditCronJob extends EditRecord
|
||||
{
|
||||
protected static string $resource = CronJobResource::class;
|
||||
|
||||
protected function getHeaderActions(): array
|
||||
{
|
||||
return [
|
||||
Actions\DeleteAction::make(),
|
||||
];
|
||||
}
|
||||
}
|
|
@ -1,19 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Filament\Resources\CronJobResource\Pages;
|
||||
|
||||
use App\Filament\Resources\CronJobResource;
|
||||
use Filament\Actions;
|
||||
use Filament\Resources\Pages\ListRecords;
|
||||
|
||||
class ListCronJobs extends ListRecords
|
||||
{
|
||||
protected static string $resource = CronJobResource::class;
|
||||
|
||||
protected function getHeaderActions(): array
|
||||
{
|
||||
return [
|
||||
Actions\CreateAction::make(),
|
||||
];
|
||||
}
|
||||
}
|
3
web/resources/views/filament/pages/cron-jobs.blade.php
Normal file
3
web/resources/views/filament/pages/cron-jobs.blade.php
Normal file
|
@ -0,0 +1,3 @@
|
|||
<x-filament-panels::page>
|
||||
|
||||
</x-filament-panels::page>
|
|
@ -22,3 +22,4 @@ Route::get('/', function () {
|
|||
return view('welcome');
|
||||
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in a new issue