Skip to content

Commit 0a91fff

Browse files
authored
Merge pull request #3809 from magento-arcticfoxes/2.3-develop-pr
[2.3-develop] Sync with 2.3.1-release
2 parents 16036cd + d1e3e9f commit 0a91fff

File tree

39 files changed

+169
-468
lines changed

39 files changed

+169
-468
lines changed

app/code/Magento/AuthorizenetAcceptjs/etc/payment.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Payment:etc/payment.xsd">
1010
<methods>
1111
<method name="authorizenet_acceptjs">
12-
<allow_multiple_address>1</allow_multiple_address>
12+
<allow_multiple_address>0</allow_multiple_address>
1313
</method>
1414
</methods>
1515
</payment>

app/code/Magento/AuthorizenetAcceptjs/view/base/requirejs-config.js

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,10 @@
44
*/
55

66
var config = {
7-
shim: {
8-
acceptjs: {
9-
exports: 'Accept'
10-
},
11-
acceptjssandbox: {
12-
exports: 'Accept'
7+
map: {
8+
'*': {
9+
acceptjssandbox: 'https://jstest.authorize.net/v1/Accept.js',
10+
acceptjs: 'https://js.authorize.net/v1/Accept.js'
1311
}
14-
},
15-
paths: {
16-
acceptjssandbox: 'https://jstest.authorize.net/v1/Accept',
17-
acceptjs: 'https://js.authorize.net/v1/Accept'
1812
}
1913
};

app/code/Magento/AuthorizenetAcceptjs/view/base/web/js/view/payment/acceptjs-factory.js

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ define([
1616
dependency = 'acceptjssandbox';
1717
}
1818

19-
require([dependency], function (accept) {
19+
require([dependency], function () {
2020
var $body = $('body');
2121

2222
/*
@@ -26,7 +26,16 @@ define([
2626
* Dynamically-loading-Accept-js-E-WC-03-Accept-js-is-not-loaded/td-p/63283
2727
*/
2828
$body.on('handshake.acceptjs', function () {
29-
deferred.resolve(accept);
29+
/*
30+
* Accept.js doesn't return the library when loading
31+
* and requirejs "shim" can't be used because it only works with the "paths" config option
32+
* and we can't use "paths" because require will try to load ".min.js" in production
33+
* and that doesn't work because it doesn't exist
34+
* and we can't add a query string to force a URL because accept.js will reject it
35+
* and we can't include it locally because they check in the script before loading more scripts
36+
* So, we use the global version as "shim" would
37+
*/
38+
deferred.resolve(window.Accept);
3039
$body.off('handshake.acceptjs');
3140
});
3241
},

app/code/Magento/Backup/Controller/Adminhtml/Index.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
namespace Magento\Backup\Controller\Adminhtml;
77

88
use Magento\Backend\App\Action;
9-
use Magento\Framework\App\Action\HttpGetActionInterface;
109
use Magento\Backup\Helper\Data as Helper;
1110
use Magento\Framework\App\ObjectManager;
1211

@@ -18,7 +17,7 @@
1817
* @since 100.0.2
1918
* @SuppressWarnings(PHPMD.AllPurposeAction)
2019
*/
21-
abstract class Index extends Action implements HttpGetActionInterface
20+
abstract class Index extends Action
2221
{
2322
/**
2423
* Authorization level of a basic admin session

app/code/Magento/Backup/Controller/Adminhtml/Index/Create.php

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,18 @@
11
<?php
22
/**
3-
*
43
* Copyright © Magento, Inc. All rights reserved.
54
* See COPYING.txt for license details.
65
*/
76
namespace Magento\Backup\Controller\Adminhtml\Index;
87

8+
use Magento\Framework\App\Action\HttpPostActionInterface;
99
use Magento\Framework\App\Filesystem\DirectoryList;
1010
use Magento\Framework\Filesystem;
1111

12-
class Create extends \Magento\Backup\Controller\Adminhtml\Index
12+
/**
13+
* Create backup controller
14+
*/
15+
class Create extends \Magento\Backup\Controller\Adminhtml\Index implements HttpPostActionInterface
1316
{
1417
/**
1518
* Create backup action.

app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateCategoryWithProductsGridFilter.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
<actionGroup ref="deleteProductUsingProductGrid" stepKey="deleteProduct2">
2929
<argument name="product" value="SimpleProduct"/>
3030
</actionGroup>
31+
<actionGroup ref="NavigateToAndResetProductGridToDefaultView" stepKey="NavigateToAndResetProductGridToDefaultView"/>
3132
<actionGroup ref="logout" stepKey="logout"/>
3233
</after>
3334
<amOnPage url="{{AdminProductIndexPage.url}}" stepKey="amOnProductList"/>

app/code/Magento/Catalog/view/adminhtml/web/catalog/product/edit/attribute.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@
55

66
define([
77
'jquery',
8-
'mage/mage'
8+
'mage/mage',
9+
'validation'
910
], function ($) {
1011
'use strict';
1112

1213
return function (config, element) {
13-
14-
$(element).mage('form').mage('validation', {
14+
$(element).mage('form').validation({
1515
validationUrl: config.validationUrl
1616
});
1717
};

app/code/Magento/Cms/Test/Mftf/Page/CmsPageEditPage.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
-->
88
<pages xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
99
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/PageObject.xsd">
10-
<page name="CmsPageEditPage" area="admin" url="admin/cms_page/edit/page_id/{{var}}" module="Magento_Cms" parameterized="true">
10+
<page name="CmsPageEditPage" area="admin" url="admin/cms_page/edit/page_id/{{var}}" parameterized="true" module="Magento_Cms">
1111
<section name="CmsNewPagePageActionsSection"/>
1212
<section name="CmsNewPagePageBasicFieldsSection"/>
1313
<section name="CmsNewPagePageContentSection"/>

app/code/Magento/ConfigurableProduct/Test/Mftf/Section/AdminProductFormConfigurationsSection.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
<element name="confProductSkuMessage" type="text" selector="//*[@name='configurable-matrix[{{arg}}][sku]']/following-sibling::label" parameterized="true"/>
2828
<element name="variationsSkuInputByRow" selector="[data-index='configurable-matrix'] table > tbody > tr:nth-of-type({{row}}) input[name*='sku']" type="input" parameterized="true"/>
2929
<element name="variationsSkuInputErrorByRow" selector="[data-index='configurable-matrix'] table > tbody > tr:nth-of-type({{row}}) .admin__field-error" type="text" parameterized="true"/>
30+
<element name="variationLabel" type="text" selector="//div[@data-index='configurable-matrix']/label"/>
3031
</section>
3132
<section name="AdminConfigurableProductFormSection">
3233
<element name="productWeight" type="input" selector=".admin__control-text[name='product[weight]']"/>

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

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
</actionGroup>
3737

3838
<!-- assert color configurations on the admin create product page -->
39+
<dontSee selector="{{AdminProductFormConfigurationsSection.variationLabel}}" stepKey="seeLabelNotVisible"/>
3940
<seeNumberOfElements selector="{{AdminProductFormConfigurationsSection.currentVariationsRows}}" userInput="3" stepKey="seeNumberOfRows"/>
4041
<see selector="{{AdminProductFormConfigurationsSection.currentVariationsNameCells}}" userInput="{{colorProductAttribute1.name}}" stepKey="seeAttributeName1InField"/>
4142
<see selector="{{AdminProductFormConfigurationsSection.currentVariationsNameCells}}" userInput="{{colorProductAttribute2.name}}" stepKey="seeAttributeName2InField"/>

app/code/Magento/Downloadable/Ui/DataProvider/Product/Form/Modifier/Links.php

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public function __construct(
8686
}
8787

8888
/**
89-
* {@inheritdoc}
89+
* @inheritdoc
9090
*/
9191
public function modifyData(array $data)
9292
{
@@ -101,7 +101,7 @@ public function modifyData(array $data)
101101
}
102102

103103
/**
104-
* {@inheritdoc}
104+
* @inheritdoc
105105
* @SuppressWarnings(PHPMD.ExcessiveMethodLength)
106106
*/
107107
public function modifyMeta(array $meta)
@@ -160,6 +160,8 @@ public function modifyMeta(array $meta)
160160
}
161161

162162
/**
163+
* Returns configuration for dynamic rows
164+
*
163165
* @return array
164166
*/
165167
protected function getDynamicRows()
@@ -180,6 +182,8 @@ protected function getDynamicRows()
180182
}
181183

182184
/**
185+
* Returns Record column configuration
186+
*
183187
* @return array
184188
*/
185189
protected function getRecord()
@@ -221,6 +225,8 @@ protected function getRecord()
221225
}
222226

223227
/**
228+
* Returns Title column configuration
229+
*
224230
* @return array
225231
*/
226232
protected function getTitleColumn()
@@ -238,6 +244,7 @@ protected function getTitleColumn()
238244
'componentType' => Form\Field::NAME,
239245
'dataType' => Form\Element\DataType\Text::NAME,
240246
'dataScope' => 'title',
247+
'labelVisible' => false,
241248
'validation' => [
242249
'required-entry' => true,
243250
],
@@ -247,6 +254,8 @@ protected function getTitleColumn()
247254
}
248255

249256
/**
257+
* Returns Price column configuration
258+
*
250259
* @return array
251260
*/
252261
protected function getPriceColumn()
@@ -265,6 +274,7 @@ protected function getPriceColumn()
265274
'dataType' => Form\Element\DataType\Number::NAME,
266275
'component' => 'Magento_Downloadable/js/components/price-handler',
267276
'dataScope' => 'price',
277+
'labelVisible' => false,
268278
'addbefore' => $this->locator->getStore()->getBaseCurrency()
269279
->getCurrencySymbol(),
270280
'validation' => [
@@ -281,6 +291,8 @@ protected function getPriceColumn()
281291
}
282292

283293
/**
294+
* Returns File column configuration
295+
*
284296
* @return array
285297
*/
286298
protected function getFileColumn()
@@ -302,6 +314,7 @@ protected function getFileColumn()
302314
'options' => $this->typeUpload->toOptionArray(),
303315
'typeFile' => 'links_file',
304316
'typeUrl' => 'link_url',
317+
'labelVisible' => false,
305318
];
306319
$fileLinkUrl['arguments']['data']['config'] = [
307320
'formElement' => Form\Element\Input::NAME,
@@ -344,6 +357,8 @@ protected function getFileColumn()
344357
}
345358

346359
/**
360+
* Returns Sample column configuration
361+
*
347362
* @return array
348363
*/
349364
protected function getSampleColumn()
@@ -363,6 +378,7 @@ protected function getSampleColumn()
363378
'dataType' => Form\Element\DataType\Text::NAME,
364379
'dataScope' => 'sample.type',
365380
'options' => $this->typeUpload->toOptionArray(),
381+
'labelVisible' => false,
366382
'typeFile' => 'sample_file',
367383
'typeUrl' => 'sample_url',
368384
];
@@ -382,6 +398,7 @@ protected function getSampleColumn()
382398
'component' => 'Magento_Downloadable/js/components/file-uploader',
383399
'elementTmpl' => 'Magento_Downloadable/components/file-uploader',
384400
'fileInputName' => 'link_samples',
401+
'labelVisible' => false,
385402
'uploaderConfig' => [
386403
'url' => $this->urlBuilder->addSessionParam()->getUrl(
387404
'adminhtml/downloadable_file/upload',
@@ -403,6 +420,8 @@ protected function getSampleColumn()
403420
}
404421

405422
/**
423+
* Returns Sharable columns configuration
424+
*
406425
* @return array
407426
*/
408427
protected function getShareableColumn()
@@ -420,6 +439,8 @@ protected function getShareableColumn()
420439
}
421440

422441
/**
442+
* Returns max downloads column configuration
443+
*
423444
* @return array
424445
*/
425446
protected function getMaxDownloadsColumn()
@@ -437,6 +458,7 @@ protected function getMaxDownloadsColumn()
437458
'componentType' => Form\Field::NAME,
438459
'dataType' => Form\Element\DataType\Number::NAME,
439460
'dataScope' => 'number_of_downloads',
461+
'labelVisible' => false,
440462
'value' => 0,
441463
'validation' => [
442464
'validate-zero-or-greater' => true,

app/code/Magento/Downloadable/Ui/DataProvider/Product/Form/Modifier/Samples.php

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public function __construct(
7777
}
7878

7979
/**
80-
* {@inheritdoc}
80+
* @inheritdoc
8181
*/
8282
public function modifyData(array $data)
8383
{
@@ -90,7 +90,7 @@ public function modifyData(array $data)
9090
}
9191

9292
/**
93-
* {@inheritdoc}
93+
* @inheritdoc
9494
* @SuppressWarnings(PHPMD.ExcessiveMethodLength)
9595
*/
9696
public function modifyMeta(array $meta)
@@ -135,6 +135,8 @@ public function modifyMeta(array $meta)
135135
}
136136

137137
/**
138+
* Returns configuration for dynamic rows
139+
*
138140
* @return array
139141
*/
140142
protected function getDynamicRows()
@@ -155,6 +157,8 @@ protected function getDynamicRows()
155157
}
156158

157159
/**
160+
* Returns Record column configuration
161+
*
158162
* @return array
159163
*/
160164
protected function getRecord()
@@ -192,6 +196,8 @@ protected function getRecord()
192196
}
193197

194198
/**
199+
* Returns Title column configuration
200+
*
195201
* @return array
196202
*/
197203
protected function getTitleColumn()
@@ -209,6 +215,7 @@ protected function getTitleColumn()
209215
'componentType' => Form\Field::NAME,
210216
'dataType' => Form\Element\DataType\Text::NAME,
211217
'dataScope' => 'title',
218+
'labelVisible' => false,
212219
'validation' => [
213220
'required-entry' => true,
214221
],
@@ -218,6 +225,8 @@ protected function getTitleColumn()
218225
}
219226

220227
/**
228+
* Returns Sample column configuration
229+
*
221230
* @return array
222231
*/
223232
protected function getSampleColumn()
@@ -236,6 +245,7 @@ protected function getSampleColumn()
236245
'component' => 'Magento_Downloadable/js/components/upload-type-handler',
237246
'dataType' => Form\Element\DataType\Text::NAME,
238247
'dataScope' => 'type',
248+
'labelVisible' => false,
239249
'options' => $this->typeUpload->toOptionArray(),
240250
'typeFile' => 'sample_file',
241251
'typeUrl' => 'sample_url',
@@ -246,6 +256,7 @@ protected function getSampleColumn()
246256
'dataType' => Form\Element\DataType\Text::NAME,
247257
'dataScope' => 'sample_url',
248258
'placeholder' => 'URL',
259+
'labelVisible' => false,
249260
'validation' => [
250261
'required-entry' => true,
251262
'validate-url' => true,

app/code/Magento/Elasticsearch/Model/Adapter/FieldMapper/Product/FieldProvider/DynamicField.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ public function getFields(array $context = []): array
126126
foreach ($groups as $group) {
127127
$groupPriceKey = $this->fieldNameResolver->getFieldName(
128128
$priceAttribute,
129-
array_merge($context, ['customerGroupId' => $group->getId()])
129+
['customerGroupId' => $group->getId(), 'websiteId' => $context['websiteId']]
130130
);
131131
$allAttributes[$groupPriceKey] = [
132132
'type' => $this->fieldTypeConverter->convert(FieldTypeConverterInterface::INTERNAL_DATA_TYPE_FLOAT),

app/code/Magento/Elasticsearch/SearchAdapter/Aggregation/Builder/Term.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,13 @@ public function build(
2222
array $queryResult,
2323
DataProviderInterface $dataProvider
2424
) {
25-
$buckets = $queryResult['aggregations'][$bucket->getName()]['buckets'] ?? [];
2625
$values = [];
27-
foreach ($buckets as $resultBucket) {
26+
foreach ($queryResult['aggregations'][$bucket->getName()]['buckets'] as $resultBucket) {
2827
$values[$resultBucket['key']] = [
2928
'value' => $resultBucket['key'],
3029
'count' => $resultBucket['doc_count'],
3130
];
3231
}
33-
3432
return $values;
3533
}
3634
}

0 commit comments

Comments
 (0)