develop
Last change
on this file since 75a169d was 0df7a93, checked in by beratkjufliju <kufliju@…>, 3 years ago |
bug fixes
|
-
Property mode
set to
100644
|
File size:
1.7 KB
|
Rev | Line | |
---|
[7304c7f] | 1 | <?php
|
---|
| 2 |
|
---|
| 3 | namespace Database\Seeders;
|
---|
| 4 |
|
---|
[120759b] | 5 | use App\Models\User;
|
---|
[7304c7f] | 6 | use Carbon\Carbon;
|
---|
| 7 | use Illuminate\Database\Seeder;
|
---|
| 8 |
|
---|
| 9 | class UsersTableSeeder extends Seeder
|
---|
| 10 | {
|
---|
| 11 | /**
|
---|
| 12 | * Run the database seeds.
|
---|
| 13 | *
|
---|
| 14 | * @return void
|
---|
| 15 | */
|
---|
| 16 | public function run()
|
---|
| 17 | {
|
---|
| 18 | \DB::table("users")->insert([
|
---|
[2db8837] | 19 | "id" => "1",
|
---|
[7304c7f] | 20 | "name" => "Berat",
|
---|
| 21 | "surname" => "Kjufliju",
|
---|
[0df7a93] | 22 | "username" => "admin",
|
---|
[7304c7f] | 23 | "password" => bcrypt("123456"),
|
---|
| 24 | "email" => "kufliju@gmail.com",
|
---|
[d795fa6] | 25 | "phone_number" => "+38971201239",
|
---|
[7304c7f] | 26 | "role_id" => 1,
|
---|
| 27 | "is_active" => true,
|
---|
| 28 | "is_confirmed" => true,
|
---|
[d795fa6] | 29 | "created_by" => "1",
|
---|
[4b7e2d3] | 30 | "created_at" => now()
|
---|
[7304c7f] | 31 | ]);
|
---|
| 32 |
|
---|
[0df7a93] | 33 | \DB::table("users")->insert([
|
---|
| 34 | "id" => "2",
|
---|
| 35 | "name" => "Berat",
|
---|
| 36 | "surname" => "Kjufliju",
|
---|
| 37 | "username" => "referent",
|
---|
| 38 | "password" => bcrypt("123456"),
|
---|
| 39 | "email" => "mail@host.com",
|
---|
| 40 | "phone_number" => "+38971201236",
|
---|
| 41 | "role_id" => 2,
|
---|
| 42 | "is_active" => true,
|
---|
| 43 | "is_confirmed" => true,
|
---|
| 44 | "created_by" => "1",
|
---|
| 45 | "created_at" => now()
|
---|
| 46 | ]);
|
---|
| 47 |
|
---|
| 48 | \DB::table("users")->insert([
|
---|
| 49 | "id" => "3",
|
---|
| 50 | "name" => "Berat",
|
---|
| 51 | "surname" => "Kjufliju",
|
---|
| 52 | "username" => "viewer",
|
---|
| 53 | "password" => bcrypt("123456"),
|
---|
| 54 | "email" => "test@test.com",
|
---|
| 55 | "phone_number" => "+38971201235",
|
---|
| 56 | "role_id" => 3,
|
---|
| 57 | "is_active" => true,
|
---|
| 58 | "is_confirmed" => true,
|
---|
| 59 | "created_by" => "1",
|
---|
| 60 | "created_at" => now()
|
---|
| 61 | ]);
|
---|
| 62 |
|
---|
[4b7e2d3] | 63 | User::factory()->count(50)->create();
|
---|
[194a359] | 64 |
|
---|
[7304c7f] | 65 | }
|
---|
| 66 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.