Skip to content

Commit 062662d

Browse files
🔃 [EngCom] Public Pull Requests - 2.3-develop
Accepted Public Pull Requests: - #21421: Improve swatch table overflow handling (by @Cyanoxide) - #21426: fixes-for-product-page-product-in-website-multi-store-view-not-displa� (by @priti2jcommerce) - #21429: Correct spelling (by @ravi-chandra3197) - #21431: Fix grammar (by @DanielRuf) - #21295: Fix empty cart validation (by @wojtekn) - #21395: As low as displays incorrect pricing on category page, tax appears to be added twice #21383 (by @Jitheesh) - #21405: Removed unused else block and corrected return types (by @yogeshsuhagiya) - #21401: Show error message when customer click on Add to cart button without selecting atleast one product from recently orderred list (by @mageprince) - #21105: Fixed pagination issue in admin review grid (by @dominicfernando) - #21330: Change comment to "database" (by @DanielRuf) - #21302: Misconfigured aria-labelledby for product tabs (by @mageho) - #20858: Update details.phtml (by @mageho) - #20578: Added original exception as the cause to the new exception on product delete error (by @woutersamaey) - #20339: issue fixed #20337 Option Title breaking in two line because applying� (by @cedarvinda) - #20044: Sitemap filename can't exceed 32 characters #13937 (by @irajneeshgupta) Fixed GitHub Issues: - #21294: Cart can't be emptied if any product is out of stock (reported by @wojtekn) has been fixed in #21295 by @wojtekn in 2.3-develop branch Related commits: 1. 4cdcb74 2. f6656f9 3. 96793fe 4. f82299b 5. a1578b5 - #21383: As low as displays incorrect pricing on category page, tax appears to be added twice (reported by @devchris79) has been fixed in #21395 by @Jitheesh in 2.3-develop branch Related commits: 1. c9fff89 2. 70f2599 - #21398: Doesn't show any error message when customer click on Add to cart button without selecting atleast one product from recently orderred list (reported by @mageprince) has been fixed in #21401 by @mageprince in 2.3-develop branch Related commits: 1. 0df8d31 2. adccc57 3. d4a5b46 4. fa95b94 - #20337: Option Title breaking in two line because applying wrong css for manage width (reported by @swetacedcoss) has been fixed in #20339 by @cedarvinda in 2.3-develop branch Related commits: 1. 74b2098 2. d7ba787 - #13937: Sitemap filename can't exceed 32 characters (reported by @erikhansen) has been fixed in #20044 by @irajneeshgupta in 2.3-develop branch Related commits: 1. 55cf2dc 2. 035e8d7 3. 417ffa2 4. e9f4981 5. 94c176f
2 parents 9afd4c6 + 09847e4 commit 062662d

File tree

20 files changed

+305
-91
lines changed

20 files changed

+305
-91
lines changed

app/code/Magento/Backend/etc/adminhtml/system.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@
112112
<group id="debug" translate="label" type="text" sortOrder="20" showInDefault="1" showInWebsite="1" showInStore="1">
113113
<label>Debug</label>
114114
<field id="template_hints_storefront" translate="label" type="select" sortOrder="20" showInDefault="1" showInWebsite="1" showInStore="1">
115-
<label>Enabled Template Path Hints for Storefront</label>
115+
<label>Enable Template Path Hints for Storefront</label>
116116
<source_model>Magento\Config\Model\Config\Source\Yesno</source_model>
117117
</field>
118118
<field id="template_hints_storefront_show_with_parameter" translate="label" type="select" sortOrder="20" showInDefault="1" showInWebsite="1" showInStore="1">
@@ -132,7 +132,7 @@
132132
<comment>Add the following parameter to the URL to show template hints ?templatehints=[parameter_value]</comment>
133133
</field>
134134
<field id="template_hints_admin" translate="label" type="select" sortOrder="20" showInDefault="1" showInWebsite="0" showInStore="0">
135-
<label>Enabled Template Path Hints for Admin</label>
135+
<label>Enable Template Path Hints for Admin</label>
136136
<source_model>Magento\Config\Model\Config\Source\Yesno</source_model>
137137
</field>
138138
<field id="template_hints_blocks" translate="label" type="select" sortOrder="21" showInDefault="1" showInWebsite="1" showInStore="1">

app/code/Magento/Catalog/Model/ProductRepository.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -644,10 +644,11 @@ public function delete(ProductInterface $product)
644644
unset($this->instancesById[$product->getId()]);
645645
$this->resourceModel->delete($product);
646646
} catch (ValidatorException $e) {
647-
throw new CouldNotSaveException(__($e->getMessage()));
647+
throw new CouldNotSaveException(__($e->getMessage()), $e);
648648
} catch (\Exception $e) {
649649
throw new \Magento\Framework\Exception\StateException(
650-
__('The "%1" product couldn\'t be removed.', $sku)
650+
__('The "%1" product couldn\'t be removed.', $sku),
651+
$e
651652
);
652653
}
653654
$this->removeProductFromLocalCache($sku);

app/code/Magento/Catalog/Pricing/Price/MinimalTierPriceCalculator.php

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,10 @@ public function __construct(CalculatorInterface $calculator)
2929
}
3030

3131
/**
32-
* Get raw value of "as low as" as a minimal among tier prices
33-
* {@inheritdoc}
32+
* Get raw value of "as low as" as a minimal among tier prices{@inheritdoc}
33+
*
34+
* @param SaleableInterface $saleableItem
35+
* @return float|null
3436
*/
3537
public function getValue(SaleableInterface $saleableItem)
3638
{
@@ -49,15 +51,17 @@ public function getValue(SaleableInterface $saleableItem)
4951
}
5052

5153
/**
52-
* Return calculated amount object that keeps "as low as" value
53-
* {@inheritdoc}
54+
* Return calculated amount object that keeps "as low as" value{@inheritdoc}
55+
*
56+
* @param SaleableInterface $saleableItem
57+
* @return AmountInterface|null
5458
*/
5559
public function getAmount(SaleableInterface $saleableItem)
5660
{
5761
$value = $this->getValue($saleableItem);
5862

5963
return $value === null
6064
? null
61-
: $this->calculator->getAmount($value, $saleableItem);
65+
: $this->calculator->getAmount($value, $saleableItem, 'tax');
6266
}
6367
}

app/code/Magento/Catalog/view/frontend/templates/product/view/details.phtml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,17 @@
2222
$label = $block->getChildData($alias, 'title');
2323
?>
2424
<div class="data item title"
25-
aria-labelledby="tab-label-<?= /* @escapeNotVerified */ $alias ?>-title"
2625
data-role="collapsible" id="tab-label-<?= /* @escapeNotVerified */ $alias ?>">
2726
<a class="data switch"
2827
tabindex="-1"
29-
data-toggle="switch"
28+
data-toggle="trigger"
3029
href="#<?= /* @escapeNotVerified */ $alias ?>"
3130
id="tab-label-<?= /* @escapeNotVerified */ $alias ?>-title">
3231
<?= /* @escapeNotVerified */ $label ?>
3332
</a>
3433
</div>
35-
<div class="data item content" id="<?= /* @escapeNotVerified */ $alias ?>" data-role="content">
34+
<div class="data item content"
35+
aria-labelledby="tab-label-<?= /* @escapeNotVerified */ $alias ?>-title" id="<?= /* @escapeNotVerified */ $alias ?>" data-role="content">
3636
<?= /* @escapeNotVerified */ $html ?>
3737
</div>
3838
<?php endforeach;?>

app/code/Magento/Checkout/Controller/Cart/Addgroup.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,21 @@
44
* Copyright © Magento, Inc. All rights reserved.
55
* See COPYING.txt for license details.
66
*/
7+
78
namespace Magento\Checkout\Controller\Cart;
89

910
use Magento\Checkout\Model\Cart as CustomerCart;
11+
use Magento\Framework\App\Action\HttpPostActionInterface;
1012
use Magento\Framework\Escaper;
1113
use Magento\Framework\App\ObjectManager;
1214
use Magento\Sales\Model\Order\Item;
1315

1416
/**
17+
* Add grouped items controller.
18+
*
1519
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
1620
*/
17-
class Addgroup extends \Magento\Checkout\Controller\Cart
21+
class Addgroup extends \Magento\Checkout\Controller\Cart implements HttpPostActionInterface
1822
{
1923
/**
2024
* @var Escaper
@@ -44,6 +48,8 @@ public function __construct(
4448
}
4549

4650
/**
51+
* Add items in group.
52+
*
4753
* @return \Magento\Framework\Controller\Result\Redirect
4854
*/
4955
public function execute()
@@ -74,6 +80,8 @@ public function execute()
7480
}
7581
}
7682
$this->cart->save();
83+
} else {
84+
$this->messageManager->addErrorMessage(__('Please select at least one product to add to cart'));
7785
}
7886
return $this->_goBack();
7987
}

app/code/Magento/Checkout/view/frontend/templates/cart/form.phtml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414
method="post"
1515
id="form-validate"
1616
data-mage-init='{"Magento_Checkout/js/action/update-shopping-cart":
17-
{"validationURL" : "/checkout/cart/updateItemQty"}
17+
{"validationURL" : "/checkout/cart/updateItemQty",
18+
"updateCartActionContainer": "#update_cart_action_container"}
1819
}'
1920
class="form form-cart">
2021
<?= $block->getBlockHtml('formkey') ?>

app/code/Magento/Checkout/view/frontend/web/js/action/update-shopping-cart.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@ define([
1414
$.widget('mage.updateShoppingCart', {
1515
options: {
1616
validationURL: '',
17-
eventName: 'updateCartItemQty'
17+
eventName: 'updateCartItemQty',
18+
updateCartActionContainer: ''
1819
},
1920

2021
/** @inheritdoc */
@@ -31,7 +32,9 @@ define([
3132
* @return {Boolean}
3233
*/
3334
onSubmit: function (event) {
34-
if (!this.options.validationURL) {
35+
var action = this.element.find(this.options.updateCartActionContainer).val();
36+
37+
if (!this.options.validationURL || action === 'empty_cart') {
3538
return true;
3639
}
3740

app/code/Magento/Fedex/Model/Carrier.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,6 @@ public function setRequest(RateRequest $request)
363363

364364
if ($request->getDestPostcode()) {
365365
$r->setDestPostal($request->getDestPostcode());
366-
} else {
367366
}
368367

369368
if ($request->getDestCity()) {

app/code/Magento/GiftMessage/Block/Adminhtml/Sales/Order/View/Items.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ public function getMessage()
171171
/**
172172
* Retrieve save url
173173
*
174-
* @return array
174+
* @return string
175175
* @codeCoverageIgnore
176176
*/
177177
public function getSaveUrl()

app/code/Magento/GiftMessage/Block/Cart/GiftOptions.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,16 @@
33
* Copyright © Magento, Inc. All rights reserved.
44
* See COPYING.txt for license details.
55
*/
6+
67
namespace Magento\GiftMessage\Block\Cart;
78

89
use Magento\Backend\Block\Template\Context;
910
use Magento\Framework\Json\Encoder;
1011
use Magento\GiftMessage\Model\CompositeConfigProvider;
1112

1213
/**
14+
* Gift options cart block.
15+
*
1316
* @api
1417
* @since 100.0.2
1518
*/
@@ -63,6 +66,8 @@ public function __construct(
6366
}
6467

6568
/**
69+
* Retrieve encoded js layout.
70+
*
6671
* @return string
6772
*/
6873
public function getJsLayout()
@@ -76,7 +81,7 @@ public function getJsLayout()
7681
/**
7782
* Retrieve gift message configuration
7883
*
79-
* @return array
84+
* @return string
8085
*/
8186
public function getGiftOptionsConfigJson()
8287
{

0 commit comments

Comments
 (0)