A few seeder fixes

Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
snipe 2021-09-23 22:16:19 -07:00
parent 28a5838dfb
commit 7cbdf2c727
2 changed files with 3 additions and 1 deletions

View file

@ -54,6 +54,7 @@ class UserFactory extends Factory
'first_name' => 'Admin', 'first_name' => 'Admin',
'last_name' => 'User', 'last_name' => 'User',
'username' => 'admin', 'username' => 'admin',
'avatar' => '1.jpg',
'permissions' => '{"superuser":"1"}', 'permissions' => '{"superuser":"1"}',
]; ];
}); });
@ -66,6 +67,7 @@ class UserFactory extends Factory
'first_name' => 'Snipe E.', 'first_name' => 'Snipe E.',
'last_name' => 'Head', 'last_name' => 'Head',
'username' => 'snipe', 'username' => 'snipe',
'avatar' => '2.jpg',
'email' => 'snipe@snipe.net', 'email' => 'snipe@snipe.net',
'permissions' => '{"superuser":"1"}', 'permissions' => '{"superuser":"1"}',
]; ];

View file

@ -48,7 +48,7 @@ class UserSeeder extends Seeder
} }
} }
$users = User::orderBy('id', 'desc')->take(20)->get(); $users = User::orderBy('id', 'asc')->take(20)->get();
$file_number = 1; $file_number = 1;
foreach ($users as $user) { foreach ($users as $user) {