| 12345678910111213141516171819202122232425262728293031323334353637383940414243 |
- <?php
- namespace App\Filament\Resources\TeacherResource\Pages;
- use App\Filament\Resources\TeacherResource;
- use Filament\Resources\Pages\EditRecord;
- class EditTeacher extends EditRecord
- {
- protected static string $resource = TeacherResource::class;
- protected function getRedirectUrl(): string
- {
- return $this->getResource()::getUrl('index');
- }
- protected function getSavedNotificationTitle(): ?string
- {
- return '教师信息已更新';
- }
- protected function getSavedNotification(): ?\Filament\Notifications\Notification
- {
- return \Filament\Notifications\Notification::make()
- ->success()
- ->title('教师信息已更新')
- ->body('教师信息已成功更新。');
- }
- public function getTitle(): string
- {
- return '编辑教师';
- }
- public function getBreadcrumbs(): array
- {
- return [
- '#' => '师生管理',
- static::getResource()::getUrl('index') => '教师管理',
- static::getResource()::getUrl('edit', ['record' => $this->record]) => '编辑教师',
- ];
- }
- }
|