<?php

namespace Database\Factories;

use App\Enums\JourneyMethod;
use App\Models\TravelRequest;
use Illuminate\Database\Eloquent\Factories\Factory;

/**
 * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\TravelJourney>
 */
class TravelJourneyFactory extends Factory
{
    public function definition(): array
    {
        return [
            'travel_request_id' => TravelRequest::factory(),
            'origin' => fake()->city(),
            'destination' => fake()->city(),
            'date' => fake()->dateTimeBetween('+1 week', '+3 months')->format('Y-m-d'),
            'time' => fake()->time('H:i'),
            'method' => fake()->randomElement(JourneyMethod::cases()),
        ];
    }
}
