This repository was archived by the owner on Oct 8, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed
Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change 77class DatabaseSeeder extends Seeder
88{
99 /**
10- * Seed the application's database.
11- *
10+ * Seed your application's database.
1211 * @return void
1312 */
1413 public function run (): array
Original file line number Diff line number Diff line change 22
33namespace App \Database \Seeds ;
44
5+ use App \Models \User ;
56use App \Database \Factories \UserFactory ;
67use Illuminate \Database \Seeder ;
7- use App \Models \User ;
88
99class UsersSeeder extends Seeder
1010{
1111 /**
1212 * Run the database seeds.
13- *
1413 * @return void
1514 */
1615 public function run ()
1716 {
18- // You can directly create db records
17+ // You can directly create db records like this 👇
18+
1919 // $user = new User();
20+ // $user->username = 'mychi';
2021 // $user->fullname = 'Mychi Darko';
21- // $user->email = "[email protected] " ; 22- // $user->password = md5(" password.demo" );
22+ // $user->email = '[email protected] ' ; 23+ // $user->password = \Leaf\Password::hash(' password' );
2324 // $user->save();
2425
25- // You can also use factories like this
26+ // You can also use factories like this 👇
2627 (new UserFactory )->create (5 )->save ();
2728
2829 // even better, you can use them together :-)
You can’t perform that action at this time.
0 commit comments