Fix Dutch model table names and seeder status values
- Add explicit $table property to all Eloquent models with Dutch names - Fix pivot table names in belongsToMany relationships - Fix seeder: use valid enum values for afhankelijkheden status Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -16,6 +16,8 @@ class User extends Authenticatable
|
||||
/** @use HasFactory<UserFactory> */
|
||||
use HasApiTokens, HasFactory, Notifiable;
|
||||
|
||||
protected $table = 'users';
|
||||
|
||||
protected $fillable = [
|
||||
'name',
|
||||
'email',
|
||||
@@ -41,12 +43,12 @@ class User extends Authenticatable
|
||||
|
||||
public function roles(): BelongsToMany
|
||||
{
|
||||
return $this->belongsToMany(Role::class);
|
||||
return $this->belongsToMany(Role::class, 'role_user');
|
||||
}
|
||||
|
||||
public function projects(): BelongsToMany
|
||||
{
|
||||
return $this->belongsToMany(Project::class)
|
||||
return $this->belongsToMany(Project::class, 'project_user')
|
||||
->withPivot('rol')
|
||||
->withTimestamps()
|
||||
->using(ProjectUser::class);
|
||||
|
||||
Reference in New Issue
Block a user