|
@@ 110-113 (lines=4) @@
|
| 107 |
|
|
| 108 |
|
$targetMetadata = $cmf->getMetadataFor($assoc['targetEntity']); |
| 109 |
|
|
| 110 |
|
if (isset($assoc['id']) && $targetMetadata->containsForeignIdentifier) { |
| 111 |
|
$ce[] = "Cannot map association '" . $class->name. "#". $fieldName ." as identifier, because " . |
| 112 |
|
"the target entity '". $targetMetadata->name . "' also maps an association as identifier."; |
| 113 |
|
} |
| 114 |
|
|
| 115 |
|
if ($assoc['mappedBy']) { |
| 116 |
|
if ($targetMetadata->hasField($assoc['mappedBy'])) { |
|
@@ 236-240 (lines=5) @@
|
| 233 |
|
$orderField . " that is not a field on the target entity " . $targetMetadata->name . "."; |
| 234 |
|
continue; |
| 235 |
|
} |
| 236 |
|
if ($targetMetadata->isCollectionValuedAssociation($orderField)) { |
| 237 |
|
$ce[] = "The association " . $class->name."#".$fieldName." is ordered by a field " . |
| 238 |
|
$orderField . " on " . $targetMetadata->name . " that is a collection-valued association."; |
| 239 |
|
continue; |
| 240 |
|
} |
| 241 |
|
if ($targetMetadata->isAssociationInverseSide($orderField)) { |
| 242 |
|
$ce[] = "The association " . $class->name."#".$fieldName." is ordered by a field " . |
| 243 |
|
$orderField . " on " . $targetMetadata->name . " that is the inverse side of an association."; |
|
@@ 241-245 (lines=5) @@
|
| 238 |
|
$orderField . " on " . $targetMetadata->name . " that is a collection-valued association."; |
| 239 |
|
continue; |
| 240 |
|
} |
| 241 |
|
if ($targetMetadata->isAssociationInverseSide($orderField)) { |
| 242 |
|
$ce[] = "The association " . $class->name."#".$fieldName." is ordered by a field " . |
| 243 |
|
$orderField . " on " . $targetMetadata->name . " that is the inverse side of an association."; |
| 244 |
|
continue; |
| 245 |
|
} |
| 246 |
|
} |
| 247 |
|
} |
| 248 |
|
} |