Fix Bill using the wrong field for join (#15524)

This commit is contained in:
Neil Lathwood
2023-10-30 18:50:57 +00:00
committed by GitHub
parent f7c9b230db
commit 840cda00ff

View File

@@ -52,6 +52,6 @@ class Bill extends Model
public function ports(): BelongsToMany
{
return $this->belongsToMany(\App\Models\Port::class, 'bill_ports', 'bill_id', 'bill_id');
return $this->belongsToMany(\App\Models\Port::class, 'bill_ports', 'bill_id', 'port_id');
}
}