Skip to content

Commit bdcaeaf

Browse files
🔃 [Magento Community Engineering] Community Contributions - 2.3-develop
Accepted Community Pull Requests: - #24101: Resolve "Number of results" and "Number of Uses" in edit "Search Term" missing validate number (issue 24100) (by @edenduong) - #24097: Resolve "Integrations" Grid missing header label (issue 24096) (by @edenduong) - #23533: implement rss feed image size based on view.xml file (by @sunilit42) - #24076: Replace Cyrillic with appropriate characters (by @dshevtsov) - #24036: Fix external links to the Magento technical documentation (by @dshevtsov) - #23144: #23143: Code optimization for the offline shipping methods (by @atwixfirster) - #24086: Fixed critical error 'Undefined constant formName' (by @cpini) - #24099: Resolve No asterisk symbol (required entry) when changing "Encryption Key" (issue 24098) (by @edenduong) - #24088: Database Media Storage : Fixed error in database deleteFolder function. Now correctly deletes folder (by @gwharton) - #23684: Resolve Send friend sender email should be static not user defined (by @edenduong) - #23739: Resolve Bad style on Validate VAT number messages issue23738 (by @edenduong) Fixed GitHub Issues: - #24100: "Number of results" and "Number of Uses" in edit "Search Term" missing validate number (reported by @edenduong) has been fixed in #24101 by @edenduong in 2.3-develop branch Related commits: 1. 20f88ec - #24096: "Integrations" Grid missing header label (reported by @edenduong) has been fixed in #24097 by @edenduong in 2.3-develop branch Related commits: 1. 3945a4c - #23516: Product Images are very small in RSS Product Feed (reported by @jigar48) has been fixed in #23533 by @sunilit42 in 2.3-develop branch Related commits: 1. 5853484 2. 5bb1358 3. 3a2f5c4 4. 521e950 5. 06a91b8 6. 9e497bf 7. 3e655f7 8. 4755552 9. 13a7c75 10. f968f85 11. 2f9d572 12. e8ca488 13. 9f088cf 14. af94999 15. 1fa9615 16. 70afacd 17. d6bd1d6 18. 0413854 19. f3ef0ce 20. 9775528 21. c086ab2 22. c4906f1 23. 04d3451 24. 9c0ca37 25. 52b9939 26. f301d5f - #23143: Code optimization for the offline shipping methods. (reported by @atwixfirster) has been fixed in #23144 by @atwixfirster in 2.3-develop branch Related commits: 1. 85bd3ec 2. dda454d - #24098: No asterisk symbol (required entry) when changing "Encryption Key" (reported by @edenduong) has been fixed in #24099 by @edenduong in 2.3-develop branch Related commits: 1. fa78bfa - #23936: Database Media Storage : clearing image cache does not clear cached image files from database (reported by @gwharton) has been fixed in #24088 by @gwharton in 2.3-develop branch Related commits: 1. 2e3c569 - #23646: Send friend sender email should be static not user defined (reported by @juhanihaapala) has been fixed in #23684 by @edenduong in 2.3-develop branch Related commits: 1. 2048b40 2. 6ae0223 - #23738: Bad style on Validate VAT number messages (reported by @edenduong) has been fixed in #23739 by @edenduong in 2.3-develop branch Related commits: 1. d8b4d82 2. 101a9f3
2 parents 421f825 + 96242ab commit bdcaeaf

File tree

66 files changed

+9190
-157
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+9190
-157
lines changed

CHANGELOG.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -612,11 +612,11 @@ To get detailed information about changes in Magento 2.3.0, see the [Release Not
612612

613613
2.2.0
614614
=============
615-
To get detailed information about changes in Magento 2.2.0, see the [Release Notes](https://devdocs.magento.com/guides/v2.2/release-notes/bk-release-notes.html)
615+
To get detailed information about changes in Magento 2.2.0, see the [Release Notes](https://devdocs.magento.com/guides/v2.3/release-notes/bk-release-notes.html)
616616

617617
2.1.0
618618
=============
619-
To get detailed information about changes in Magento 2.1.0, please visit [Magento Community Edition (CE) Release Notes](https://devdocs.magento.com/guides/v2.1/release-notes/ReleaseNotes2.1.0CE.html "Magento Community Edition (CE) Release Notes")
619+
To get detailed information about changes in Magento 2.1.0, please visit [Magento Community Edition (CE) Release Notes](https://devdocs.magento.com/guides/v2.3/release-notes/ReleaseNotes2.1.0CE.html "Magento Community Edition (CE) Release Notes")
620620

621621
2.0.0
622622
=============
@@ -1637,7 +1637,7 @@ Tests:
16371637
* Improved backend menu keyboard accessibility
16381638
* Accessibility improvements: WAI-ARIA in a product item on a category page and related products
16391639
* Checkout flow code can work with a separate DB storage
1640-
* <a href="https://devdocs.magento.com/guides/v1.0/release-notes/changes.html#change-devrc-unit">Unit tests moved to module directories</a>
1640+
* Unit tests moved to module directories
16411641
* Addressed naming inconsistencies in REST routes
16421642
* Added Advanced Developer workflow for frontend developers
16431643
* Setup

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ To learn about issues, click [here][2]. To open an issue, click [here][3].
2020

2121
To suggest documentation improvements, click [here][4].
2222

23-
[1]: <https://devdocs.magento.com/guides/v2.3/contributor-guide/contributing.html>
24-
[2]: <https://devdocs.magento.com/guides/v2.3/contributor-guide/contributing.html#report>
25-
[3]: <https://github.com/magento/magento2/issues>
26-
[4]: <https://devdocs.magento.com>
23+
[1]: https://devdocs.magento.com/guides/v2.3/contributor-guide/contributing.html
24+
[2]: https://devdocs.magento.com/guides/v2.3/contributor-guide/contributing.html#report
25+
[3]: https://github.com/magento/magento2/issues
26+
[4]: https://devdocs.magento.com
2727

2828
<h3>Community Maintainers</h3>
2929
The members of this team have been recognized for their outstanding commitment to maintaining and improving Magento. Magento has granted them permission to accept, merge, and reject pull requests, as well as review issues, and thanks these Community Maintainers for their valuable contributions.

app/code/Magento/Analytics/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Magento_Analytics Module
22

3-
The Magento_Analytics module integrates your Magento instance with the [Magento Business Intelligence (MBI)](https://magento.com/products/business-intelligence) to use [Advanced Reporting](https://devdocs.magento.com/guides/v2.2/advanced-reporting/modules.html) functionality.
3+
The Magento_Analytics module integrates your Magento instance with the [Magento Business Intelligence (MBI)](https://magento.com/products/business-intelligence) to use [Advanced Reporting](https://devdocs.magento.com/guides/v2.3/advanced-reporting/modules.html) functionality.
44

55
The module implements the following functionality:
66

@@ -16,8 +16,8 @@ The module implements the following functionality:
1616

1717
## Structure
1818

19-
Beyond the [usual module file structure](https://devdocs.magento.com/guides/v2.2/architecture/archi_perspectives/components/modules/mod_intro.html) the module contains a directory `ReportXml`.
20-
[Report XML](https://devdocs.magento.com/guides/v2.2/advanced-reporting/report-xml.html) is a markup language used to build reports for Advanced Reporting.
19+
Beyond the [usual module file structure](https://devdocs.magento.com/guides/v2.3/architecture/archi_perspectives/components/modules/mod_intro.html) the module contains a directory `ReportXml`.
20+
[Report XML](https://devdocs.magento.com/guides/v2.3/advanced-reporting/report-xml.html) is a markup language used to build reports for Advanced Reporting.
2121
The language declares SQL queries using XML declaration.
2222

2323
## Subscription Process

app/code/Magento/Catalog/Block/Rss/Category.php

Lines changed: 28 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,16 @@
1111

1212
/**
1313
* Class Category
14+
*
1415
* @package Magento\Catalog\Block\Rss
16+
*
1517
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
1618
*/
1719
class Category extends \Magento\Framework\View\Element\AbstractBlock implements DataProviderInterface
1820
{
19-
/**
20-
* @var \Magento\Catalog\Model\CategoryFactory
21-
*/
21+
/**
22+
* @var \Magento\Catalog\Model\CategoryFactory
23+
*/
2224
protected $categoryFactory;
2325

2426
/**
@@ -50,7 +52,6 @@ class Category extends \Magento\Framework\View\Element\AbstractBlock implements
5052
* @var CategoryRepositoryInterface
5153
*/
5254
protected $categoryRepository;
53-
5455
/**
5556
* @param \Magento\Framework\View\Element\Template\Context $context
5657
* @param \Magento\Catalog\Model\CategoryFactory $categoryFactory
@@ -83,6 +84,8 @@ public function __construct(
8384
}
8485

8586
/**
87+
* Set Block cache key
88+
*
8689
* @return void
8790
*/
8891
protected function _construct()
@@ -97,7 +100,9 @@ protected function _construct()
97100
}
98101

99102
/**
100-
* {@inheritdoc}
103+
* Get info about category by category id
104+
*
105+
* @return array
101106
*/
102107
public function getRssData()
103108
{
@@ -116,7 +121,9 @@ public function getRssData()
116121
$newUrl = $category->getUrl();
117122
$title = $category->getName();
118123
$data = ['title' => $title, 'description' => $title, 'link' => $newUrl, 'charset' => 'UTF-8'];
119-
124+
$attributes = $this->_viewConfig
125+
->getViewConfig()
126+
->getMediaAttributes('Magento_Catalog', $this->imageHelper::MEDIA_TYPE_CONFIG_NODE, 'rss_thumbnail');
120127
/** @var $product \Magento\Catalog\Model\Product */
121128
foreach ($this->rssModel->getProductCollection($category, $this->getStoreId()) as $product) {
122129
$product->setAllowedInRss(true);
@@ -130,7 +137,7 @@ public function getRssData()
130137

131138
$description = '
132139
<table><tr>
133-
<td><a href="%s"><img src="%s" border="0" align="left" height="75" width="75"></a></td>
140+
<td><a href="%s"><img src="%s" border="0" align="left" height="%s" width="%s"></a></td>
134141
<td style="text-decoration:none;">%s %s</td>
135142
</tr></table>
136143
';
@@ -139,6 +146,8 @@ public function getRssData()
139146
$description,
140147
$product->getProductUrl(),
141148
$this->imageHelper->init($product, 'rss_thumbnail')->getUrl(),
149+
isset($attributes['height']) ? $attributes['height'] : 75,
150+
isset($attributes['width']) ? $attributes['width'] : 75,
142151
$product->getDescription(),
143152
$product->getAllowedPriceInRss() ? $this->renderPriceHtml($product) : ''
144153
);
@@ -187,6 +196,8 @@ protected function renderPriceHtml(\Magento\Catalog\Model\Product $product)
187196
}
188197

189198
/**
199+
* Get current Store Id
200+
*
190201
* @return int
191202
*/
192203
protected function getStoreId()
@@ -199,6 +210,8 @@ protected function getStoreId()
199210
}
200211

201212
/**
213+
* Cache lifetime for RSS feed
214+
*
202215
* @return int
203216
*/
204217
public function getCacheLifetime()
@@ -207,7 +220,9 @@ public function getCacheLifetime()
207220
}
208221

209222
/**
210-
* {@inheritdoc}
223+
* Retrieve rss feed enable for category page
224+
*
225+
* @return bool
211226
*/
212227
public function isAllowed()
213228
{
@@ -218,6 +233,8 @@ public function isAllowed()
218233
}
219234

220235
/**
236+
* Get category feed collection
237+
*
221238
* @return array
222239
*/
223240
public function getFeeds()
@@ -257,7 +274,9 @@ public function getFeeds()
257274
}
258275

259276
/**
260-
* {@inheritdoc}
277+
* Check isAuthRequired Required
278+
*
279+
* @return bool
261280
*/
262281
public function isAuthRequired()
263282
{

app/code/Magento/Catalog/Test/Unit/Block/Rss/CategoryTest.php

Lines changed: 51 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
* Copyright © Magento, Inc. All rights reserved.
44
* See COPYING.txt for license details.
55
*/
6+
67
namespace Magento\Catalog\Test\Unit\Block\Rss;
78

89
use Magento\Framework\TestFramework\Unit\Helper\ObjectManager as ObjectManagerHelper;
@@ -73,6 +74,16 @@ class CategoryTest extends \PHPUnit\Framework\TestCase
7374
*/
7475
protected $categoryRepository;
7576

77+
/**
78+
* @var \Magento\Framework\View\ConfigInterface|\PHPUnit_Framework_MockObject_MockObject
79+
*/
80+
protected $viewConfig;
81+
82+
/**
83+
* @var \Magento\Framework\Config\View
84+
*/
85+
protected $configView;
86+
7687
/**
7788
* @var array
7889
*/
@@ -115,6 +126,8 @@ protected function setUp()
115126
$this->storeManager->expects($this->any())->method('getStore')->will($this->returnValue($store));
116127
$this->scopeConfig = $this->createMock(\Magento\Framework\App\Config\ScopeConfigInterface::class);
117128
$this->categoryRepository = $this->createMock(\Magento\Catalog\Api\CategoryRepositoryInterface::class);
129+
$this->viewConfig = $this->getMockBuilder(\Magento\Framework\View\ConfigInterface::class)
130+
->getMockForAbstractClass();
118131
$objectManagerHelper = new ObjectManagerHelper($this);
119132
$this->block = $objectManagerHelper->getObject(
120133
\Magento\Catalog\Block\Rss\Category::class,
@@ -130,6 +143,7 @@ protected function setUp()
130143
'customerSession' => $this->customerSession,
131144
'storeManager' => $this->storeManager,
132145
'categoryRepository' => $this->categoryRepository,
146+
'viewConfig' => $this->viewConfig,
133147
]
134148
);
135149
}
@@ -145,16 +159,26 @@ public function testGetRssData()
145159

146160
$this->categoryRepository->expects($this->once())->method('get')->will($this->returnValue($category));
147161

162+
$configViewMock = $this->getMockBuilder(\Magento\Framework\Config\View::class)
163+
->disableOriginalConstructor()
164+
->getMock();
165+
166+
$this->viewConfig->expects($this->once())
167+
->method('getViewConfig')
168+
->willReturn($configViewMock);
169+
148170
$product = $this->getMockBuilder(\Magento\catalog\Model\Product::class)
149-
->setMethods([
150-
'__sleep',
151-
'__wakeup',
152-
'getName',
153-
'getAllowedInRss',
154-
'getProductUrl',
155-
'getDescription',
156-
'getAllowedPriceInRss',
157-
])->disableOriginalConstructor()->getMock();
171+
->setMethods(
172+
[
173+
'__sleep',
174+
'__wakeup',
175+
'getName',
176+
'getAllowedInRss',
177+
'getProductUrl',
178+
'getDescription',
179+
'getAllowedPriceInRss'
180+
]
181+
)->disableOriginalConstructor()->getMock();
158182
$product->expects($this->once())->method('getName')->will($this->returnValue('Product Name'));
159183
$product->expects($this->once())->method('getAllowedInRss')->will($this->returnValue(true));
160184
$product->expects($this->exactly(2))->method('getProductUrl')
@@ -213,23 +237,23 @@ public function testGetFeeds()
213237
->disableOriginalConstructor()->getMock();
214238

215239
$collection = $this->getMockBuilder(\Magento\Catalog\Model\ResourceModel\Category\Collection::class)
216-
->setMethods([
217-
'addIdFilter',
218-
'addAttributeToSelect',
219-
'addAttributeToSort',
220-
'load',
221-
'addAttributeToFilter',
222-
'getIterator',
223-
])->disableOriginalConstructor()->getMock();
240+
->setMethods(
241+
[
242+
'addIdFilter',
243+
'addAttributeToSelect',
244+
'addAttributeToSort',
245+
'load',
246+
'addAttributeToFilter',
247+
'getIterator'
248+
]
249+
)->disableOriginalConstructor()->getMock();
224250
$collection->expects($this->once())->method('addIdFilter')->will($this->returnSelf());
225251
$collection->expects($this->exactly(3))->method('addAttributeToSelect')->will($this->returnSelf());
226252
$collection->expects($this->once())->method('addAttributeToSort')->will($this->returnSelf());
227253
$collection->expects($this->once())->method('addAttributeToFilter')->will($this->returnSelf());
228254
$collection->expects($this->once())->method('load')->will($this->returnSelf());
229-
$collection->expects($this->once())->method('getIterator')->will($this->returnValue(
230-
new \ArrayIterator([$category])
231-
));
232-
255+
$collection->expects($this->once())->method('getIterator')
256+
->will($this->returnValue(new \ArrayIterator([$category])));
233257
$category->expects($this->once())->method('getId')->will($this->returnValue(1));
234258
$category->expects($this->once())->method('getName')->will($this->returnValue('Category Name'));
235259
$category->expects($this->once())->method('getResourceCollection')->will($this->returnValue($collection));
@@ -250,9 +274,12 @@ public function testGetFeeds()
250274

251275
$this->rssUrlBuilder->expects($this->once())->method('getUrl')
252276
->will($this->returnValue('http://magento.com/category-name.html'));
253-
$feeds = ['group' => 'Categories', 'feeds' => [
254-
['label' => 'Category Name', 'link' => 'http://magento.com/category-name.html'],
255-
]];
277+
$feeds = [
278+
'group' => 'Categories',
279+
'feeds' => [
280+
['label' => 'Category Name', 'link' => 'http://magento.com/category-name.html'],
281+
]
282+
];
256283
$this->assertEquals($feeds, $this->block->getFeeds());
257284
}
258285
}

app/code/Magento/Catalog/view/adminhtml/templates/catalog/product/helper/gallery.phtml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ $formName = $block->getFormName();
3737
type="hidden"
3838
value="<?= $block->escapeHtmlAttr($typeData['value']) ?>"/>
3939
<?php
40-
} ?>
40+
} ?>
4141

4242
<script id="<?= $block->getHtmlId() ?>-template" type="text/x-magento-template">
4343
<div class="image item<% if (data.disabled == 1) { %> hidden-for-front<% } %>"
@@ -61,7 +61,7 @@ $formName = $block->getFormName();
6161
value="<%- data.label %>"/>
6262
<input type="hidden"
6363
name="<?= $block->escapeHtmlAttr($elementName) ?>[<%- data.file_id %>][disabled]"
64-
data-form-part="<?= $block->escapeHtmlAttr(formName) ?>"
64+
data-form-part="<?= $block->escapeHtmlAttr($formName) ?>"
6565
value="<%- data.disabled %>"/>
6666
<input type="hidden"
6767
name="<?= $block->escapeHtmlAttr($elementName) ?>[<%- data.file_id %>][media_type]"
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# Magento_CatalogAnalytics module
22

3-
The Magento_CatalogAnalytics module configures data definitions for a data collection related to the Catalog module entities to be used in [Advanced Reporting](https://devdocs.magento.com/guides/v2.2/advanced-reporting/modules.html).
3+
The Magento_CatalogAnalytics module configures data definitions for a data collection related to the Catalog module entities to be used in [Advanced Reporting](https://devdocs.magento.com/guides/v2.3/advanced-reporting/modules.html).

app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontSortingByPriceForConfigurableWithCatalogRuleAppliedTest.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
<description value="Sort by price should be correct if the apply Catalog Rule to child product of configurable product"/>
1717
<severity value="CRITICAL"/>
1818
<testCaseId value="MAGETWO-69988"/>
19-
<group value="сonfigurable_product"/>
19+
<group value="configurable_product"/>
2020
</annotations>
2121
<before>
2222
<createData entity="ApiCategory" stepKey="createCategory"/>

app/code/Magento/Customer/view/adminhtml/templates/system/config/validatevat.phtml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,13 @@ require(['prototype'], function(){
2828
result = response.message;
2929
}
3030
if (response.valid == 1) {
31-
validationMessage.removeClassName('hidden').addClassName('success')
31+
validationMessage.removeClassName('hidden').removeClassName('admin__field-error').addClassName('note');
32+
validationMessage.setStyle({color:'green'});
3233
} else {
33-
validationMessage.removeClassName('hidden').addClassName('error')
34+
validationMessage.removeClassName('hidden').addClassName('admin__field-error');
3435
}
3536
} catch (e) {
36-
validationMessage.removeClassName('hidden').addClassName('error')
37+
validationMessage.removeClassName('hidden').addClassName('admin__field-error');
3738
}
3839
validationMessage.update(result);
3940
}
@@ -46,8 +47,9 @@ require(['prototype'], function(){
4647
});
4748
</script>
4849
<div class="actions actions-validate-vat">
49-
<div id="validation_result" class="message-validation hidden"></div>
50+
<p class="admin__field-error hidden" id="validation_result" style="margin-bottom:10px;"></p>
5051
<button onclick="javascript:validateVat(); return false;" class="action-validate-vat" type="button" id="<?= $block->escapeHtmlAttr($block->getHtmlId()) ?>">
5152
<span><?= $block->escapeHtml($block->getButtonLabel()) ?></span>
5253
</button>
5354
</div>
55+
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# Magento_CustomerAnalytics module
22

3-
The Magento_CustomerAnalytics module configures data definitions for a data collection related to the Customer module entities to be used in [Advanced Reporting](https://devdocs.magento.com/guides/v2.2/advanced-reporting/modules.html).
3+
The Magento_CustomerAnalytics module configures data definitions for a data collection related to the Customer module entities to be used in [Advanced Reporting](https://devdocs.magento.com/guides/v2.3/advanced-reporting/modules.html).

0 commit comments

Comments
 (0)