Files
LauckCycles/database/factories/ProductFactory.php
T
2025-08-12 23:57:57 -03:00

31 lines
891 B
PHP

<?php
namespace Database\Factories;
use Illuminate\Database\Eloquent\Factories\Factory;
/**
* @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Product>
*/
class ProductFactory extends Factory
{
/**
* Define the model's default state.
*
* @return array<string, mixed>
*/
public function definition(): array
{
return [
'nombre' => $this->faker->sentence(3),
'marca'=> $this->faker->randomElement(['Cube','Giant','Megamo','KTM','MMR','Liv','Ghost','Lapierre']),
'modelo'=> $this->faker->bothify('????-####'),
'rodado'=> $this->faker->numberBetween(12,30),
'color'=> $this->faker->safeColorName(),
'tipo'=> $this->faker->word(),
'descripcion'=> $this->faker->text(),
'precio'=> $this->faker->randomFloat(2,100,200)
];
}
}