<?php

namespace App\Filament\Resources\ZoneResource\Pages;

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

class CreateZone extends CreateRecord
{
    protected static string $resource = ZoneResource::class;

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

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

    protected function mutateFormDataBeforeCreate(array $data): array
    {
        return $data;
    }
} 