This commit is contained in:
Andras Bacsai
2023-05-22 15:47:40 +02:00
parent 1dbd1065f9
commit a044354294
25 changed files with 332 additions and 209 deletions

View File

@@ -18,7 +18,6 @@ class UserFactory extends Factory
public function definition(): array
{
return [
'name' => fake()->name(),
'uuid' => Str::uuid(),
'email' => fake()->unique()->safeEmail(),
'email_verified_at' => now(),

View File

@@ -15,7 +15,7 @@ return new class extends Migration
$table->id();
$table->string('uuid')->unique();
$table->boolean('is_root_user')->default(false);
$table->string('name');
$table->string('name')->default('Your Name Here');
$table->string('email')->unique();
$table->timestamp('email_verified_at')->nullable();
$table->string('password');

View File

@@ -11,12 +11,10 @@ class UserSeeder extends Seeder
{
User::factory()->create([
"id" => 0,
'name' => 'Root User',
'email' => 'test@example.com',
'is_root_user' => true,
]);
User::factory()->create([
'name' => 'Normal User',
'email' => 'test2@example.com',
]);
}