Skip to content

Commit 9f90a44

Browse files
Merge branch '2.3-develop' into ENGCOM-5580-magento-magento2-23867
2 parents 91b450c + 2bc471e commit 9f90a44

File tree

88 files changed

+2165
-525
lines changed

Some content is hidden

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

88 files changed

+2165
-525
lines changed
Lines changed: 29 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,30 @@
1-
# Admin Notification
1+
# Magento_AdminNotification module
22

3-
**Admin Notification** provides the ability to alert administrators via
4-
system messages and provides a message inbox for surveys and notifications.
3+
The Magento_AdminNotification module provides the ability to alert administrators via system messages and provides a message inbox for surveys and notifications.
4+
5+
## Installation details
6+
7+
Before disabling or uninstalling this module, note that the Magento_Indexer module depends on this module.
8+
9+
For information about module installation in Magento 2, see [Enable or disable modules](https://devdocs.magento.com/guides/v2.3/install-gde/install/cli/install-cli-subcommands-enable.html).
10+
11+
### Events
12+
13+
This module observes the following events:
14+
15+
- `controller_action_predispatch` event in `Magento\AdminNotification\Observer\PredispatchAdminActionControllerObserver`
16+
17+
### Layouts
18+
19+
This module introduces the following layouts and layout handles in the `view/adminhtml/layout` directory:
20+
21+
- `adminhtml_notification_index`
22+
- `adminhtml_notification_block`
23+
24+
For more information about layouts in Magento 2, see the [Layout documentation](https://devdocs.magento.com/guides/v2.3/frontend-dev-guide/layouts/layout-overview.html).
25+
26+
### UI components
27+
28+
You can extend admin notifications using the `view/adminhtml/ui_component/notification_area.xml` configuration file.
29+
30+
For information about UI components in Magento 2, see [Overview of UI components](https://devdocs.magento.com/guides/v2.3/ui_comp_guide/bk-ui_comps.html).
Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,4 @@
1-
The Magento_AdvancedPricingImportExport module handles the import and export of the advanced pricing.
1+
# Magento_AdvancedPricingImportExport module
2+
3+
The Magento_AdvancedPricingImportExport module handles the import and export of the advanced pricing.
4+

app/code/Magento/Backend/view/adminhtml/templates/widget/grid.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ $numColumns = $block->getColumns() !== null ? count($block->getColumns()) : 0;
2323
<?php if ($block->canDisplayContainer()) : ?>
2424
<div id="<?= $block->escapeHtml($block->getId()) ?>" data-grid-id="<?= $block->escapeHtml($block->getId()) ?>">
2525
<?php else : ?>
26-
<?= $block->getLayout()->getMessagesBlock()->getGroupedHtml() ?>
26+
<?= $block->getLayout()->getMessagesBlock()->getGroupedHtml() ?>
2727
<?php endif; ?>
2828

2929
<div class="admin__data-grid-header admin__data-grid-toolbar">

app/code/Magento/Catalog/Model/Product/Attribute/OptionManagement.php

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -43,17 +43,6 @@ public function getItems($attributeCode)
4343
*/
4444
public function add($attributeCode, $option)
4545
{
46-
/** @var \Magento\Eav\Api\Data\AttributeOptionInterface[] $currentOptions */
47-
$currentOptions = $this->getItems($attributeCode);
48-
if (is_array($currentOptions)) {
49-
array_walk($currentOptions, function (&$attributeOption) {
50-
/** @var \Magento\Eav\Api\Data\AttributeOptionInterface $attributeOption */
51-
$attributeOption = $attributeOption->getLabel();
52-
});
53-
if (in_array($option->getLabel(), $currentOptions, true)) {
54-
return false;
55-
}
56-
}
5746
return $this->eavOptionManagement->add(
5847
\Magento\Catalog\Api\Data\ProductAttributeInterface::ENTITY_TYPE_CODE,
5948
$attributeCode,

app/code/Magento/CatalogSearch/Model/Layer/Filter/Attribute.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
* Copyright © Magento, Inc. All rights reserved.
44
* See COPYING.txt for license details.
55
*/
6+
declare(strict_types=1);
7+
68
namespace Magento\CatalogSearch\Model\Layer\Filter;
79

810
use Magento\Catalog\Model\Layer\Filter\AbstractFilter;
@@ -62,6 +64,9 @@ public function apply(\Magento\Framework\App\RequestInterface $request)
6264
->getProductCollection();
6365
$productCollection->addFieldToFilter($attribute->getAttributeCode(), $attributeValue);
6466
$label = $this->getOptionText($attributeValue);
67+
if (is_array($label)) {
68+
$label = implode(',', $label);
69+
}
6570
$this->getLayer()
6671
->getState()
6772
->addFilter($this->_createItem($label, $attributeValue));

app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
use Magento\CatalogUrlRewrite\Model\CategoryUrlPathGenerator;
1010
use Magento\CatalogUrlRewrite\Service\V1\StoreViewService;
1111
use Magento\Catalog\Api\CategoryRepositoryInterface;
12-
use Magento\Framework\Event\Observer;
1312
use Magento\CatalogUrlRewrite\Model\Category\ChildrenCategoriesProvider;
1413
use Magento\Framework\Event\ObserverInterface;
1514
use Magento\Store\Model\Store;
@@ -68,13 +67,15 @@ public function execute(\Magento\Framework\Event\Observer $observer)
6867
{
6968
/** @var Category $category */
7069
$category = $observer->getEvent()->getCategory();
71-
$useDefaultAttribute = !$category->isObjectNew() && !empty($category->getData('use_default')['url_key']);
70+
$useDefaultAttribute = !empty($category->getData('use_default')['url_key']);
7271
if ($category->getUrlKey() !== false && !$useDefaultAttribute) {
7372
$resultUrlKey = $this->categoryUrlPathGenerator->getUrlKey($category);
7473
$this->updateUrlKey($category, $resultUrlKey);
75-
} else if ($useDefaultAttribute) {
76-
$resultUrlKey = $category->formatUrlKey($category->getOrigData('name'));
77-
$this->updateUrlKey($category, $resultUrlKey);
74+
} elseif ($useDefaultAttribute) {
75+
if (!$category->isObjectNew()) {
76+
$resultUrlKey = $category->formatUrlKey($category->getOrigData('name'));
77+
$this->updateUrlKey($category, $resultUrlKey);
78+
}
7879
$category->setUrlKey(null)->setUrlPath(null);
7980
}
8081
}

0 commit comments

Comments
 (0)