<?php

namespace Database\Factories;

use App\Models\Product;
use App\Models\Seller;
use App\Models\Category;
use Illuminate\Database\Eloquent\Factories\Factory;

class ProductFactory extends Factory
{
    protected $model = Product::class;

    public function definition(): array
    {
        return [
            'seller_id' => Seller::factory(),
            'category_id' => Category::factory(),
            'name' => $name = ucfirst($this->faker->words(3, true)),
            'slug' => \Illuminate\Support\Str::slug($name),
            'description' => $this->faker->paragraph,
            'price' => $this->faker->randomFloat(2, 100, 10000),
            'moq' => $this->faker->numberBetween(1, 50),
            'is_highlighted' => $this->faker->boolean(10),
        ];
    }
}
