{
if ($bin = @hex2bin($uuid)) {
return $bin;
}
throw new InvalidUuidException($uuid);
}
/**
* Generates a md5 binary, to hash the string and returns a UUID in hex
*/
$shiftedId = array_shift($id);
return Uuid::fromHexToBytes($shiftedId);
}
return Uuid::fromHexToBytes($id);
}, $primaryKeys);
}
if (!$primaryKeyField instanceof StorageAware) {
throw new \RuntimeException('Primary key fields has to be an instance of StorageAware');
$primaryKeyField = $definition->getPrimaryKeys()->first();
/** @feature-deprecated (flag:FEATURE_NEXT_14872) remove FeatureCheck
* if ($primaryKeyField instanceof IdField || $primaryKeyField instanceof FkField) {
*/
if ($primaryKeyField instanceof IdField || (Feature::isActive('FEATURE_NEXT_14872') && $primaryKeyField instanceof FkField)) {
$primaryKeys = array_map(function ($id) {
if (\is_array($id)) {
/** @var string $shiftedId */
$shiftedId = array_shift($id);
return Uuid::fromHexToBytes($shiftedId);
);
$this->joinBasic($definition, $context, $table, $query, $fields, $criteria);
if (!empty($criteria->getIds())) {
$this->queryHelper->addIdCondition($criteria, $definition, $query);
}
if ($criteria->getTitle()) {
$query->setTitle($criteria->getTitle() . '::read');
}
if ($definition->isInheritanceAware() && $criteria->hasAssociation('parent')) {
throw new ParentAssociationCanNotBeFetched();
}
$rows = $this->fetch($criteria, $definition, $context, $fields);
$collection = $this->hydrator->hydrate($collection, $definition->getEntityClass(), $definition, $rows, $definition->getEntityName(), $context);
$collection = $this->fetchAssociations($criteria, $definition, $context, $collection, $fields);
return $this->_read(
$criteria,
$definition,
$context,
new $collectionClass(),
$definition->getFields()->getBasicFields()
);
}
protected function getParser(): SqlQueryParser
{
return $event;
}
private function read(Criteria $criteria, Context $context): EntityCollection
{
$entities = $this->reader->read($this->definition, $criteria, $context);
if ($this->eventFactory === null) {
throw new \RuntimeException('Event loaded factory was not injected');
}
if (!RepositorySearchDetector::isSearchRequired($this->definition, $criteria)) {
$this->eventDispatcher->dispatch(
new EntitySearchedEvent($criteria, $this->definition, $context)
);
$entities = $this->read($criteria, $context);
return new EntitySearchResult($this->definition->getEntityName(), $entities->count(), $entities, $aggregations, $criteria, $context);
}
$ids = $this->searchIds($criteria, $context);
->getAssociation('sections.blocks')
->addAssociation('backgroundMedia')
->addAssociation('slots');
// step 1, load cms pages with blocks and slots
$pages = $this->cmsPageRepository->search($criteria, $context->getContext());
foreach ($pages as $page) {
if ($page->getSections() === null) {
continue;
}
SalesChannelContext $context,
?array $config = null,
?ResolverContext $resolverContext = null
): EntitySearchResult {
return $this->inner->load(
$request,
$this->addQuickviewAssociation($criteria),
$context,
$config,
$resolverContext
);
SalesChannelContext $context,
?array $config = null,
?ResolverContext $resolverContext = null
): EntitySearchResult {
return $this->inner->load(
$request,
$this->addScrollNavigationAssociations($criteria),
$context,
$config,
$resolverContext
);
SalesChannelContext $context,
?array $config = null,
?ResolverContext $resolverContext = null
): EntitySearchResult {
$pages = $this->inner->load(
$request,
$this->addBlockRuleAssociations($criteria),
$context,
$config,
$resolverContext
);
{
$page = $this->genericLoader->load($request, $context);
$page = NavigationPage::createFrom($page);
if ($cmsPageId) {
$pages = $this->cmsPageLoader->load($request, new Criteria([$cmsPageId]), $context);
if (!$pages->has($cmsPageId)) {
throw new PageNotFoundException($cmsPageId);
}
{
if (!$cmsPageId) {
throw new MissingRequestParameterException('cmsPageId');
}
$page = $this->loadDetailPage($cmsPageId, $context, $request);
return $this->renderStorefront('@Storefront/storefront/page/content/index.html.twig', ['page' => $page]);
}
/**
$this->dispatcher->dispatch($event, KernelEvents::CONTROLLER_ARGUMENTS);
$controller = $event->getController();
$arguments = $event->getArguments();
// call controller
$response = $controller(...$arguments);
// view
if (!$response instanceof Response) {
$event = new ViewEvent($this, $request, $type, $response);
$this->dispatcher->dispatch($event, KernelEvents::VIEW);
public function handle(Request $request, int $type = HttpKernelInterface::MAIN_REQUEST, bool $catch = true)
{
$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());
try {
return $this->handleRaw($request, $type);
} catch (\Exception $e) {
if ($e instanceof RequestExceptionInterface) {
$e = new BadRequestHttpException($e->getMessage(), $e);
}
if (false === $catch) {
$this->boot();
++$this->requestStackSize;
$this->resetServices = true;
try {
return $this->getHttpKernel()->handle($request, $type, $catch);
} finally {
--$this->requestStackSize;
}
}
&& $container->getParameter('shopware.http.cache.enabled');
if ($enabled) {
$kernel = new HttpCache($kernel, $container->get(CacheStore::class), null, ['debug' => $this->debug]);
}
$response = $kernel->handle($transformed, $type, $catch);
// fire event to trigger runtime events like seo url headers
$event = new BeforeSendResponseEvent($transformed, $response);
$container->get('event_dispatcher')->dispatch($event);
}
public function handle(Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true): HttpKernelResult
{
try {
return $this->doHandle($request, (int) $type, (bool) $catch);
} catch (DBALException $e) {
$connectionParams = self::getConnection()->getParams();
$message = str_replace([$connectionParams['url'], $connectionParams['password'], $connectionParams['user']], '******', $e->getMessage());
}
$request = Request::createFromGlobals();
$kernel = new HttpKernel($appEnv, $debug, $classLoader);
$result = $kernel->handle($request);
$result->getResponse()->send();
$kernel->terminate($result->getRequest(), $result->getResponse());
No log messages
InvalidUuidException
|
---|
Shopware\Core\Framework\Uuid\Exception\InvalidUuidException: Value is not a valid UUID: LED-Profile at vendor/shopware/core/Framework/Uuid/Uuid.php:90 at Shopware\Core\Framework\Uuid\Uuid::fromHexToBytes() (vendor/shopware/core/Framework/DataAbstractionLayer/Dbal/EntityDefinitionQueryHelper.php:518) at Shopware\Core\Framework\DataAbstractionLayer\Dbal\EntityDefinitionQueryHelper->Shopware\Core\Framework\DataAbstractionLayer\Dbal\{closure}() at array_map() (vendor/shopware/core/Framework/DataAbstractionLayer/Dbal/EntityDefinitionQueryHelper.php:510) at Shopware\Core\Framework\DataAbstractionLayer\Dbal\EntityDefinitionQueryHelper->addIdCondition() (vendor/shopware/core/Framework/DataAbstractionLayer/Dbal/EntityReader.php:267) at Shopware\Core\Framework\DataAbstractionLayer\Dbal\EntityReader->fetch() (vendor/shopware/core/Framework/DataAbstractionLayer/Dbal/EntityReader.php:122) at Shopware\Core\Framework\DataAbstractionLayer\Dbal\EntityReader->_read() (vendor/shopware/core/Framework/DataAbstractionLayer/Dbal/EntityReader.php:93) at Shopware\Core\Framework\DataAbstractionLayer\Dbal\EntityReader->read() (vendor/shopware/core/Framework/DataAbstractionLayer/EntityRepository.php:270) at Shopware\Core\Framework\DataAbstractionLayer\EntityRepository->read() (vendor/shopware/core/Framework/DataAbstractionLayer/EntityRepository.php:115) at Shopware\Core\Framework\DataAbstractionLayer\EntityRepository->search() (vendor/shopware/core/Content/Cms/SalesChannel/SalesChannelCmsPageLoader.php:58) at Shopware\Core\Content\Cms\SalesChannel\SalesChannelCmsPageLoader->load() (custom/plugins/SwagCmsExtensions/src/Service/Content/Cms/SalesChannel/SalesChannelCmsPageLoaderQuickviewDecorator.php:40) at Swag\CmsExtensions\Service\Content\Cms\SalesChannel\SalesChannelCmsPageLoaderQuickviewDecorator->load() (custom/plugins/SwagCmsExtensions/src/Service/Content/Cms/SalesChannel/SalesChannelCmsPageLoaderScrollNavigationDecorator.php:42) at Swag\CmsExtensions\Service\Content\Cms\SalesChannel\SalesChannelCmsPageLoaderScrollNavigationDecorator->load() (custom/plugins/SwagCmsExtensions/src/Service/Content/Cms/SalesChannel/SalesChannelCmsPageLoaderBlockRuleDecorator.php:45) at Swag\CmsExtensions\Service\Content\Cms\SalesChannel\SalesChannelCmsPageLoaderBlockRuleDecorator->load() (custom/plugins/ElioBlog/src/Controller/BlogController.php:132) at Elio\ElioBlog\Controller\BlogController->loadDetailPage() (custom/plugins/ElioBlog/src/Controller/BlogController.php:114) at Elio\ElioBlog\Controller\BlogController->detail() (vendor/symfony/http-kernel/HttpKernel.php:156) at Symfony\Component\HttpKernel\HttpKernel->handleRaw() (vendor/symfony/http-kernel/HttpKernel.php:78) at Symfony\Component\HttpKernel\HttpKernel->handle() (vendor/symfony/http-kernel/Kernel.php:199) at Symfony\Component\HttpKernel\Kernel->handle() (vendor/shopware/core/HttpKernel.php:178) at Shopware\Core\HttpKernel->doHandle() (vendor/shopware/core/HttpKernel.php:81) at Shopware\Core\HttpKernel->handle() (public/index.php:83) |