if ($resolverContext instanceof EntityResolverContext &&
$productConfig->
isMapped()) { /** @var SalesChannelProductEntity $product */
$product =
$this->
resolveEntityValue($resolverContext->
getEntity(),
$productConfig->
getStringValue());
$productBox->
setProduct($product);
$productBox->
setProductId($product->
getId());
} if ($productConfig->
isStatic()) { $this->
resolveProductFromRemote($slot,
$productBox,
$result,
$productConfig->
getStringValue(),
$resolverContext->
getSalesChannelContext());
} } private function resolveProductFromRemote( CmsSlotEntity
$slot,
ProductBoxStruct
$productBox,
ElementDataCollection
$result,
string
$productId,
SalesChannelContext
$salesChannelContext ): void
{ $searchResult =
$result->
get('product_' .
$slot->
getUniqueIdentifier());