@@ -28,7 +28,7 @@ $type = 'widget-product-grid';
28
28
$ title = $ block ->getTitle ();
29
29
$ blockId = $ block ->getSliderId () . uniqid ('- ' , false );
30
30
$ items = $ block ->getProductCollection ();
31
- if ($ items && $ items ->getSize ()) : ?>
31
+ if ($ items && $ items ->getSize ()): ?>
32
32
<div class="mp-product-slider-block block widget block-products-list <?= /** @noEscape */ $ mode ?> ">
33
33
<h2 class="mp-product-slider-title"><?= $ block ->escapeHtml ($ title ) ?> </h2>
34
34
<p class="mp-ps-info"><?= $ block ->escapeHtml ($ block ->getDescription ()) ?> </p>
@@ -38,7 +38,7 @@ if ($items && $items->getSize()) : ?>
38
38
<ol class="product-items widget-viewed-grid">
39
39
<?php $ iterator = 1 ; ?>
40
40
<div id="mp-list-items-<?= /** @noEscape */ $ blockId ?> " class="owl-carousel owl-theme">
41
- <?php foreach ($ items as $ _item ) : ?>
41
+ <?php foreach ($ items as $ _item ): ?>
42
42
<?= ($ iterator ++ == 1 ) ? '<li class="product-item product-slider""> ' : '</li><li class="product-item product-slider""> ' ?>
43
43
<div class="slider-product-item-info">
44
44
<a href="<?= $ block ->escapeUrl ($ block ->getProductUrl ($ _item )) ?> "
@@ -53,20 +53,20 @@ if ($items && $items->getSize()) : ?>
53
53
</a>
54
54
</strong>
55
55
56
- <?php if ($ block ->canShowReview ()) : ?>
56
+ <?php if ($ block ->canShowReview ()): ?>
57
57
<?= $ block ->getReviewsSummaryHtml ($ _item , 'short ' , true ) ?>
58
58
<?php endif ; ?>
59
59
60
60
<?= /** @noEscape */ $ block ->getProductDetailsHtml ($ _item ) ?>
61
61
62
- <?php if ($ block ->canShowPrice ()) : ?>
62
+ <?php if ($ block ->canShowPrice ()): ?>
63
63
<?= /** @noEscape */ $ block ->getProductPriceHtml ($ _item , $ type ) ?>
64
64
<?php endif ; ?>
65
65
66
66
<div class="product actions slider-product-item-actions product-item-actions">
67
- <?php if ($ block ->canShowAddToCart ()) : ?>
67
+ <?php if ($ block ->canShowAddToCart ()): ?>
68
68
<div class="actions-primary">
69
- <?php if ($ _item ->isSaleable ()) : ?>
69
+ <?php if ($ _item ->isSaleable ()): ?>
70
70
<?php $ postParams = $ block ->getAddToCartPostParams ($ _item ); ?>
71
71
<form data-role="tocart-form" data-product-sku="<?= $ block ->escapeHtml ($ _item ->getSku ()) ?> " action="<?= /* @NoEscape */ $ postParams ['action ' ] ?> " method="post">
72
72
<input type="hidden" name="product" value="<?= /* @escapeNotVerified */ $ postParams ['data ' ]['product ' ] ?> ">
@@ -78,25 +78,25 @@ if ($items && $items->getSize()) : ?>
78
78
<span><?= /** @noEscape */ __ ('Add to Cart ' ) ?> </span>
79
79
</button>
80
80
</form>
81
- <?php else : ?>
82
- <?php if ($ _item ->getIsSalable ()) : ?>
81
+ <?php else : ?>
82
+ <?php if ($ _item ->getIsSalable ()): ?>
83
83
<div class="stock available"><span><?= $ block ->escapeHtml (__ ('In stock ' )) ?> </span></div>
84
- <?php else : ?>
84
+ <?php else : ?>
85
85
<div class="stock unavailable"><span><?= $ block ->escapeHtml (__ ('Out of stock ' )) ?> </span></div>
86
86
<?php endif ; ?>
87
87
<?php endif ; ?>
88
88
</div>
89
89
<div class="secondary-addto-links actions-secondary"
90
90
data-role="add-to-links">
91
- <?php if ($ this ->helper ('Magento\Wishlist\Helper\Data ' )->isAllow ()) : ?>
91
+ <?php if ($ this ->helper ('Magento\Wishlist\Helper\Data ' )->isAllow ()): ?>
92
92
<a href="#"
93
93
data-post='<?= /** @noEscape */ $ block ->getAddToWishlistParams ($ _item ); ?> '
94
94
class="action towishlist" data-action="add-to-wishlist"
95
95
title="<?= /** @noEscape */ __ ('Add to Wish List ' ) ?> ">
96
96
<span><?= /** @noEscape */ __ ('Add to Wish List ' ) ?> </span>
97
97
</a>
98
98
<?php endif ; ?>
99
- <?php if ($ block ->getAddToCompareUrl ()) : ?>
99
+ <?php if ($ block ->getAddToCompareUrl ()): ?>
100
100
<?php $ compareHelper = $ this ->helper ('Magento\Catalog\Helper\Product\Compare ' ); ?>
101
101
<a href="#" class="action tocompare"
102
102
data-post='<?= /** @noEscape */ $ compareHelper ->getPostDataParams ($ _item ); ?> '
0 commit comments