*/ class UserFactory extends Factory { /** * Define the model's default state. * * @return array */ public function definition() { return [ 'name' => fake()->name(), 'account' => fake()->numberBetween(10000,99999), 'address' => fake()->address(), 'checked' => fake()->boolean(), 'email' => fake()->unique()->safeEmail(), 'description' => fake()->realText(), 'interest' => fake()->jobTitle(), 'date_of_birth' => fake()->dateTimeBetween('-70 years', 'now'), 'credit_card' => json_encode([ "type" => fake()->creditCardType(), "number" => fake()->creditCardNumber(), "name" => fake()->name(), "expirationDate" => fake()->creditCardExpirationDateString(), ]), ]; } /** * Indicate that the model's email address should be unverified. * * @return static */ public function unverified() { return $this->state(fn(array $attributes) => [ 'email_verified_at' => null, ]); } }