このリポジトリは2023-09-09にアーカイブされています。 ファイルの閲覧とクローンは可能ですが、プッシュ、イシューの作成、プルリクエストはできません。
kikikan/backend/database/factories/TelActivationFactory.php

41 行
944 B
PHP
Raw 通常表示 履歴

2021-08-13 14:44:08 +09:00
<?php
namespace Database\Factories;
use App\Models\TelActivation;
use Illuminate\Database\Eloquent\Factories\Factory;
class TelActivationFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = TelActivation::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
2021-09-29 12:43:36 +09:00
$tel = [
'070'.rand(10000000, 99999999),
'080'.rand(10000000, 99999999),
'090'.rand(10000000, 99999999)
];
2021-08-13 14:44:08 +09:00
return [
2021-09-29 12:43:36 +09:00
'type' => rand(0, 1),
2021-11-02 22:40:03 +09:00
'child_id' => rand(1, 10),
2021-09-29 12:43:36 +09:00
'tel' => $tel[rand(0, 2)],
'token' => $this->faker->creditCardNumber,
2021-08-13 14:44:08 +09:00
'ttl' => $this->faker->dateTime,
'created_at' => $this->faker->dateTime,
'updated_at' => $this->faker->dateTime,
];
}
}