File tree 1 file changed +17
-2
lines changed
app/code/Magento/CatalogWidget/Block/Product
1 file changed +17
-2
lines changed Original file line number Diff line number Diff line change @@ -198,7 +198,7 @@ public function getProductPriceHtml(
198
198
? $ arguments ['display_minimal_price ' ]
199
199
: true ;
200
200
201
- /** @var \Magento\Framework\Pricing\Render $priceRender */
201
+ /** @var \Magento\Framework\Pricing\Render $priceRender */
202
202
$ priceRender = $ this ->getLayout ()->getBlock ('product.price.render.default ' );
203
203
if (!$ priceRender ) {
204
204
$ priceRender = $ this ->getLayout ()->createBlock (
@@ -347,7 +347,7 @@ public function getPagerHtml()
347
347
if (!$ this ->pager ) {
348
348
$ this ->pager = $ this ->getLayout ()->createBlock (
349
349
\Magento \Catalog \Block \Product \Widget \Html \Pager::class,
350
- ' widget.products.list.pager '
350
+ $ this -> getWidgetPagerBlockName ()
351
351
);
352
352
353
353
$ this ->pager ->setUseContainer (true )
@@ -408,4 +408,19 @@ private function getPriceCurrency()
408
408
}
409
409
return $ this ->priceCurrency ;
410
410
}
411
+
412
+ /**
413
+ * @return string
414
+ */
415
+ private function getWidgetPagerBlockName ()
416
+ {
417
+ $ pageName = $ this ->getData ('page_var_name ' );
418
+ $ pagerBlockName = 'widget.products.list.pager ' ;
419
+
420
+ if (!$ pageName ) {
421
+ return $ pagerBlockName ;
422
+ }
423
+
424
+ return $ pagerBlockName . '. ' . $ pageName ;
425
+ }
411
426
}
You can’t perform that action at this time.
0 commit comments