1
0
mirror of synced 2025-01-31 04:21:44 +03:00

Updated to auto complete other end of relationships.

This commit is contained in:
Jonathan.Wage 2007-09-19 21:08:23 +00:00
parent fec83cfac3
commit 04f1a135cf

View File

@ -120,7 +120,13 @@ abstract class Doctrine_Import_Schema
// Fix the other end of the relations
foreach($this->relations as $className => $relations) {
foreach ($relations AS $alias => $relation) {
$newRelation = array();
$newRelation['foreign'] = $relation['local'];
$newRelation['local'] = $relation['foreign'];
$newRelation['class'] = $className;
$newRelation['alias'] = $className;
$this->relations[$relation['class']][$className] = $newRelation;
}
}
}