Skip to content

Commit

Permalink
Merge pull request #2850 from RF1705/patch-2
Browse files Browse the repository at this point in the history
[10.x] Fix relation key name for BelongsToMany
  • Loading branch information
yajra authored Sep 20, 2022
2 parents 6609d6d + b100442 commit 1d5e30c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/EloquentDataTable.php
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ protected function joinEagerLoadedColumn($relation, $relationColumn)

$related = $model->getRelated();
$table = $related->getTable();
$tablePK = $related->getForeignKey();
$tablePK = $model->getRelatedPivotKeyName();
$foreign = $pivot.'.'.$tablePK;
$other = $related->getQualifiedKeyName();

Expand Down

0 comments on commit 1d5e30c

Please sign in to comment.