Roman_applicant-site/database/seeders/DepartmentSeeder.php

36 lines
979 B
PHP
Raw Normal View History

2024-02-08 15:59:44 +03:00
<?php
namespace Database\Seeders;
2024-02-08 16:20:05 +03:00
use App\Models\Department;
2024-02-08 15:59:44 +03:00
use Illuminate\Database\Console\Seeds\WithoutModelEvents;
use Illuminate\Database\Seeder;
2024-02-08 16:20:05 +03:00
use Illuminate\Support\Facades\DB;
2024-02-08 15:59:44 +03:00
class DepartmentSeeder extends Seeder
{
/**
* Run the database seeds.
*/
public function run(): void
{
2024-02-08 16:20:05 +03:00
DB::table('departments')->insert([
[
'name' => 'Кафедра инф. без.',
'description' => 'Кафедра инф. без. описание',
'position' => 1,
2024-02-12 09:19:08 +03:00
'slug' => 'departmentInfWithout',
2024-02-08 16:20:05 +03:00
'faculty_id' => 1,
],
[
'name' => 'кафедра стоматологии',
'description' => 'кафедра стоматологии описание',
'position' => 2,
2024-02-12 09:19:08 +03:00
'slug' => 'departmentOfDentistry',
2024-02-08 16:20:05 +03:00
'faculty_id' => 2,
],
]);
2024-02-08 15:59:44 +03:00
}
}