<?php

namespace App\Filament\Resources\AcademicResource\Pages;

use App\Filament\Resources\AcademicResource;
use Filament\Resources\Pages\CreateRecord;
use Filament\Notifications\Notification;

class CreateAcademic extends CreateRecord
{
    protected static string $resource = AcademicResource::class;

    protected function getRedirectUrl(): string
    {
        return $this->getResource()::getUrl('index');
    }

    protected function getCreatedNotification(): ?Notification
    {
        return Notification::make()
            ->success()
            ->title('Academic created')
            ->body('The academic information has been created successfully.');
    }

    protected function mutateFormDataBeforeCreate(array $data): array
    {
        // Add any data transformation logic here
        return $data;
    }
} 