return new JsonResponse([ 'url' =>
$url,
'productId' =>
$productId,
]);
} #[Route(path: '/quickview/{productId}', name: 'widgets.quickview.minimal', defaults: ['XmlHttpRequest' => true], methods: ['GET'])]
public function quickviewMinimal(Request
$request, SalesChannelContext
$context): Response
{ $page =
$this->minimalQuickViewPageLoader->
load($request,
$context);
$this->
hook(new ProductQuickViewWidgetLoadedHook($page,
$context));
return $this->
renderStorefront('@Storefront/storefront/component/product/quickview/minimal.html.twig',
['page' =>
$page]);
} #[Route(path: '/product/{productId}/rating', name: 'frontend.detail.review.save', defaults: ['XmlHttpRequest' => true, '_loginRequired' => true], methods: ['POST'])]
public function saveReview(string
$productId, RequestDataBag
$data, SalesChannelContext
$context): Response
{ $this->
checkReviewsActive($context);
try { $this->productReviewSaveRoute->
save($productId,
$data,
$context);
}