Skip to content

Commit 7c852d1

Browse files
🔃 [EngCom] Public Pull Requests - 2.2-develop
Accepted Public Pull Requests: - #17543: Link logo in web setup wizard to back-end base URL (by @arnoudhgz) - #17575: Translated validation error messages (by @yogeshks) - #17527: Refactor JS code and added JS component file (by @yogeshks) - #16777: Fix Translation of error message on cart for deleted bundle option. (by @swnsma) Fixed GitHub Issues: - #13948: Sidebar shortcut to admin dashboard (Magento logo on top left) has no link in web setup wizard (reported by @doctormess) has been fixed in #17543 by @arnoudhgz in 2.2-develop branch Related commits: 1. d10de87
2 parents 226354f + eef9628 commit 7c852d1

File tree

10 files changed

+50
-29
lines changed

10 files changed

+50
-29
lines changed

app/code/Magento/Catalog/view/adminhtml/templates/catalog/product/attribute/form.phtml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@
2121
<input name="form_key" type="hidden" value="<?= $block->escapeHtml($block->getFormKey()) ?>" />
2222
<?= $block->getChildHtml('form') ?>
2323
</form>
24-
25-
26-
<script>
27-
require(['jquery', "mage/mage"], function(jQuery){
28-
29-
jQuery('#edit_form').mage('form').mage('validation', {validationUrl: '<?= /* @escapeNotVerified */ $block->getValidationUrl() ?>'});
30-
31-
});
24+
<script type="text/x-magento-init">
25+
{
26+
"#edit_form": {
27+
"Magento_Catalog/catalog/product/edit/attribute": {
28+
"validationUrl": "<?= /* @escapeNotVerified */ $block->getValidationUrl() ?>"
29+
}
30+
}
31+
}
3232
</script>
3333
<?= /* @escapeNotVerified */ $block->getFormScripts() ?>

app/code/Magento/Catalog/view/adminhtml/templates/catalog/product/edit/action/attribute.phtml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,12 @@
1111
<form action="<?= /* @escapeNotVerified */ $block->getSaveUrl() ?>" method="post" id="attributes-edit-form" class="attributes-edit-form" enctype="multipart/form-data">
1212
<?= $block->getBlockHtml('formkey') ?>
1313
</form>
14-
<script>
15-
require(['jquery', "mage/mage"], function(jQuery){
16-
17-
jQuery('#attributes-edit-form').mage('form')
18-
.mage('validation', {validationUrl: '<?= /* @escapeNotVerified */ $block->getValidationUrl() ?>'});
19-
20-
});
14+
<script type="text/x-magento-init">
15+
{
16+
"#attributes-edit-form": {
17+
"Magento_Catalog/catalog/product/edit/attribute": {
18+
"validationUrl": "<?= /* @escapeNotVerified */ $block->getValidationUrl() ?>"
19+
}
20+
}
21+
}
2122
</script>
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/**
2+
* Copyright © Magento, Inc. All rights reserved.
3+
* See COPYING.txt for license details.
4+
*/
5+
6+
define([
7+
'jquery',
8+
'mage/mage'
9+
], function ($) {
10+
'use strict';
11+
12+
return function (config, element) {
13+
14+
$(element).mage('form').mage('validation', {
15+
validationUrl: config.validationUrl
16+
});
17+
};
18+
});

app/code/Magento/CatalogSearch/i18n/en_US.csv

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,3 +37,4 @@ name,name
3737
"Minimal Query Length","Minimal Query Length"
3838
"Maximum Query Length","Maximum Query Length"
3939
"Rebuild Catalog product fulltext search index","Rebuild Catalog product fulltext search index"
40+
"Please enter a valid price range.","Please enter a valid price range."

app/code/Magento/CatalogSearch/view/frontend/templates/advanced/form.phtml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,8 +147,8 @@ require([
147147
}
148148
},
149149
messages: {
150-
'price[to]': {'greater-than-equals-to': 'Please enter a valid price range.'},
151-
'price[from]': {'less-than-equals-to': 'Please enter a valid price range.'}
150+
'price[to]': {'greater-than-equals-to': '<?= /* @escapeNotVerified */ __('Please enter a valid price range.') ?>'},
151+
'price[from]': {'less-than-equals-to': '<?= /* @escapeNotVerified */ __('Please enter a valid price range.') ?>'}
152152
}
153153
});
154154
});

app/code/Magento/Multishipping/etc/frontend/di.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,6 @@
4343
<plugin name="multishipping_session_mapper" type="Magento\Multishipping\Model\Checkout\Type\Multishipping\Plugin" sortOrder="50" />
4444
</type>
4545
<type name="Magento\Checkout\Controller\Cart">
46-
<plugin name="multishipping_clear_addresses" type="Magento\Multishipping\Model\Cart\Controller\CartPlugin" />
46+
<plugin name="multishipping_clear_addresses" type="Magento\Multishipping\Model\Cart\Controller\CartPlugin" sortOrder="50" />
4747
</type>
4848
</config>

app/code/Magento/Store/etc/di.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
<preference for="Magento\Framework\App\Router\PathConfigInterface" type="Magento\Store\Model\PathConfig" />
6666
<type name="Magento\Framework\App\Action\AbstractAction">
6767
<plugin name="storeCheck" type="Magento\Store\App\Action\Plugin\StoreCheck" sortOrder="10"/>
68-
<plugin name="designLoader" type="Magento\Framework\App\Action\Plugin\Design" sortOrder="30"/>
68+
<plugin name="designLoader" type="Magento\Framework\App\Action\Plugin\Design" />
6969
</type>
7070
<type name="Magento\Framework\Url\SecurityInfo">
7171
<plugin name="storeUrlSecurityInfo" type="Magento\Store\Url\Plugin\SecurityInfo"/>

app/design/adminhtml/Magento/backend/web/app/setup/styles/less/pages/_common.less

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,6 @@
1919
padding-top: @main__indent-top;
2020
}
2121

22-
.menu-wrapper {
23-
.logo-static {
24-
pointer-events: none;
25-
}
26-
}
27-
2822
//
2923
// Header
3024
// _____________________________________________

setup/pub/styles/setup.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

setup/view/magento/setup/navigation/side-menu.phtml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,13 @@
66

77
// @codingStandardsIgnoreFile
88

9+
use Magento\Backend\Model\UrlInterface;
10+
use Magento\Framework\App\ObjectManager;
11+
12+
$objectManager = ObjectManager::getInstance();
13+
/** @var Magento\Backend\Model\UrlInterface $backendUrl */
14+
$backendUrl = $objectManager->get(UrlInterface::class);
15+
916
?>
1017
<?php $expressions = []; foreach ( $this->main as $item ): ?>
1118
<?php $expressions[] = '!$state.is(\'' . $item['id'] . '\')';
@@ -20,13 +27,13 @@
2027
ng-show="<?= implode( '&&', $expressions) ?>"
2128
>
2229
<nav class="admin__menu" ng-controller="mainController">
23-
<span
24-
class="logo logo-static"
30+
<a href="<?= $backendUrl->getBaseUrl() . $backendUrl->getAreaFrontName(); ?>"
31+
class="logo"
2532
data-edition="Community Edition">
2633
<img class="logo-img"
2734
src="./pub/images/logo.svg"
2835
alt="Magento Admin Panel">
29-
</span>
36+
</a>
3037
<ul id="nav" role="menubar">
3138
<li class="item-home level-0" ng-class="{_active: $state.current.name === 'root.home'}">
3239
<a href="" ui-sref="root.home">

0 commit comments

Comments
 (0)