#1178 - fetching actual target entity when resolving column types of it
This commit is contained in:
parent
a39b6869ca
commit
f88f5ce454
@ -604,8 +604,9 @@ class ManyToManyPersister extends AbstractCollectionPersister
|
|||||||
if (isset($mapping[$relationMode][$joinTableColumn])) {
|
if (isset($mapping[$relationMode][$joinTableColumn])) {
|
||||||
$whereClauses[] = 't.' . $joinTableColumn . ' = ?';
|
$whereClauses[] = 't.' . $joinTableColumn . ' = ?';
|
||||||
$column = $mapping[$relationMode][$joinTableColumn];
|
$column = $mapping[$relationMode][$joinTableColumn];
|
||||||
$params[] = $id[$targetEntity->getFieldForColumn($column)];
|
$columnOwningClass = $this->em->getClassMetadata($mapping['targetEntity']);
|
||||||
$types[] = PersisterHelper::getTypeOfColumn($column, $targetEntity, $this->em);
|
$params[] = $id[$columnOwningClass->getFieldForColumn($column)];
|
||||||
|
$types[] = PersisterHelper::getTypeOfColumn($column, $columnOwningClass, $this->em);
|
||||||
} elseif ( ! $joinNeeded) {
|
} elseif ( ! $joinNeeded) {
|
||||||
$whereClauses[] = 't.' . $joinTableColumn . ' = ?';
|
$whereClauses[] = 't.' . $joinTableColumn . ' = ?';
|
||||||
$params[] = $key;
|
$params[] = $key;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user