diff --git a/src/Entity/Parts/PartTraits/ManufacturerTrait.php b/src/Entity/Parts/PartTraits/ManufacturerTrait.php index 51a14a37..fc27ac14 100644 --- a/src/Entity/Parts/PartTraits/ManufacturerTrait.php +++ b/src/Entity/Parts/PartTraits/ManufacturerTrait.php @@ -75,7 +75,12 @@ trait ManufacturerTrait } if (null !== $this->getManufacturer()) { - return $this->getManufacturer()->getAutoProductUrl($this->name); + //If possible use the MPN to resolve the auto product URL, otherwise use the parts name + $mpn = $this->getManufacturerProductNumber(); + if (empty($mpn)) { + $mpn = $this->getName(); + } + return $this->getManufacturer()->getAutoProductUrl($mpn); } return ''; // no url is available