2024-04-27 14:17:16 +03:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Database\Seeders;
|
|
|
|
|
|
|
|
use App\Models\User;
|
|
|
|
// use Illuminate\Database\Console\Seeds\WithoutModelEvents;
|
|
|
|
use Illuminate\Database\Seeder;
|
2024-05-02 16:54:51 +03:00
|
|
|
use Illuminate\Support\Facades\Hash;
|
2024-04-27 14:17:16 +03:00
|
|
|
|
|
|
|
class DatabaseSeeder extends Seeder
|
|
|
|
{
|
|
|
|
public function run(): void
|
|
|
|
{
|
2024-05-23 14:48:29 +03:00
|
|
|
$this->call([
|
|
|
|
DepartmentSeeder::class,
|
|
|
|
]);
|
|
|
|
|
2024-05-07 10:35:04 +03:00
|
|
|
User::factory(20)->create();
|
2024-04-27 14:17:16 +03:00
|
|
|
|
|
|
|
User::factory()->create([
|
|
|
|
'name' => 'Test User',
|
|
|
|
'email' => 'test@example.com',
|
2024-05-23 14:48:29 +03:00
|
|
|
'department_id' => 1,
|
2024-05-02 16:54:51 +03:00
|
|
|
'password' => Hash::make('password'),
|
2024-04-27 14:17:16 +03:00
|
|
|
]);
|
2024-05-07 10:35:04 +03:00
|
|
|
|
|
|
|
$this->call([
|
2024-05-23 14:48:29 +03:00
|
|
|
ProjectSeeder::class,
|
2024-05-07 10:35:04 +03:00
|
|
|
LabelSeeder::class,
|
|
|
|
TaskStatusSeeder::class,
|
|
|
|
TaskSeeder::class,
|
|
|
|
NoteSeeder::class,
|
|
|
|
LabelTaskSeeder::class,
|
2024-05-23 14:48:29 +03:00
|
|
|
ProjectUserSeeder::class,
|
2024-05-07 10:35:04 +03:00
|
|
|
]);
|
2024-04-27 14:17:16 +03:00
|
|
|
}
|
|
|
|
}
|