fix(constructeur) : fix remaining references after ConstructeurLink migration
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -837,11 +837,16 @@ final class EntityVersionService
|
||||
$snapshot['version'] = $entity->getVersion();
|
||||
}
|
||||
|
||||
// Constructeurs
|
||||
if (method_exists($entity, 'getConstructeurs')) {
|
||||
$snapshot['constructeurIds'] = [];
|
||||
foreach ($entity->getConstructeurs() as $c) {
|
||||
$snapshot['constructeurIds'][] = ['id' => $c->getId(), 'name' => $c->getName()];
|
||||
// Constructeur links
|
||||
if (method_exists($entity, 'getConstructeurLinks')) {
|
||||
$snapshot['constructeurLinks'] = [];
|
||||
foreach ($entity->getConstructeurLinks() as $link) {
|
||||
$snapshot['constructeurLinks'][] = [
|
||||
'id' => $link->getId(),
|
||||
'constructeurId' => $link->getConstructeur()->getId(),
|
||||
'constructeurName' => $link->getConstructeur()->getName(),
|
||||
'supplierReference' => $link->getSupplierReference(),
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user