develop
Last change
on this file since 194a359 was 194a359, checked in by beratkjufliju <kufliju@…>, 3 years ago |
added departments, edited users and added user settings
|
-
Property mode
set to
100644
|
File size:
934 bytes
|
Rev | Line | |
---|
[194a359] | 1 | <?php
|
---|
| 2 |
|
---|
| 3 | namespace Database\Seeders;
|
---|
| 4 |
|
---|
| 5 | use Carbon\Carbon;
|
---|
| 6 | use Illuminate\Database\Seeder;
|
---|
| 7 |
|
---|
| 8 | class DepartmentsTableSeeder extends Seeder
|
---|
| 9 | {
|
---|
| 10 | /**
|
---|
| 11 | * Run the database seeds.
|
---|
| 12 | *
|
---|
| 13 | * @return void
|
---|
| 14 | */
|
---|
| 15 | public function run()
|
---|
| 16 | {
|
---|
| 17 | \DB::table('departments')->insert([
|
---|
| 18 | [
|
---|
| 19 | "name" => "HR department",
|
---|
| 20 | "code" => "14",
|
---|
| 21 | "user_id" => "1",
|
---|
| 22 | "created_at" => Carbon::now()->format('Y-m-d H:i:s'),
|
---|
| 23 | ],
|
---|
| 24 | [
|
---|
| 25 | "name" => "IT department",
|
---|
| 26 | "code" => "01",
|
---|
| 27 | "user_id" => "1",
|
---|
| 28 | "created_at" => Carbon::now()->format('Y-m-d H:i:s'),
|
---|
| 29 | ],
|
---|
| 30 | [
|
---|
| 31 | "name" => "Business department",
|
---|
| 32 | "code" => "12",
|
---|
| 33 | "user_id" => "1",
|
---|
| 34 | "created_at" => Carbon::now()->format('Y-m-d H:i:s'),
|
---|
| 35 | ],
|
---|
| 36 | ]);
|
---|
| 37 | }
|
---|
| 38 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.