forked from eatvio/eatvio-infra
init commit
This commit is contained in:
31
database/factories/DiaryFactory.php
Normal file
31
database/factories/DiaryFactory.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
namespace Database\Factories;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\Factory;
|
||||
use App\Models\User;
|
||||
use App\Models\Diary;
|
||||
|
||||
/**
|
||||
* @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Diary>
|
||||
*/
|
||||
class DiaryFactory extends Factory
|
||||
{
|
||||
protected $model = Diary::class;
|
||||
|
||||
/**
|
||||
* Define the model's default state.
|
||||
*
|
||||
* @return array<string, mixed>
|
||||
*/
|
||||
public function definition()
|
||||
{
|
||||
return [
|
||||
'user_id' => User::factory(),
|
||||
'date' => $this->faker->date('Y-m-d'),
|
||||
'wakeup' => '06:30:00',
|
||||
'retire' => '22:30:00',
|
||||
'closed' => false,
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user