Skip to content

Commit 04140ba

Browse files
Merge pull request #1625 from magento-engcom/2.2-develop-prs
[EngCom] Public Pull Requests - 2.2-develop - MAGETWO-82724 Allow coupon code with special charater to be applied to order in checkout #11710 - MAGETWO-82675 Add a health check to the NGINX configuration sample #11690 - MAGETWO-82562 Coupon codes not showing in invoice #11635 - MAGETWO-82535 Fixed ability to set field config from layout xml #11302 [backport 2.2] #11643 - MAGETWO-81146 Fixing #10275 keyboard submit of adminhtml suggest form. #11250 - MAGETWO-82761 [Backport 2.2-develop] Dashboard Fix Y Axis for range #11751 - MAGETWO-82748 Fix Notice: freePackageValue is undefined #11720 - MAGETWO-82747 [TASK] Updated user.ini according to Magento DevDocs #11734 - MAGETWO-82537 MAGETWO-81311: Check the length of the array before attempting to sli… #11637 - MAGETWO-81970 Add missing translations in Magento_UI #11440 - MAGETWO-81904 FIX #11022 in 2.2-develop: Filter Groups of search criteria parameter have not been included for further processing #11421 - MAGETWO-82179 Fix Filter Customer Report Review 2.2-develop [Backport] #11522
2 parents 08f0056 + 30746ae commit 04140ba

File tree

19 files changed

+112
-45
lines changed

19 files changed

+112
-45
lines changed

.htaccess

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
############################################
3737
## adjust memory limit
3838

39-
php_value memory_limit 768M
39+
php_value memory_limit 756M
4040
php_value max_execution_time 18000
4141

4242
############################################
@@ -59,7 +59,7 @@
5959
############################################
6060
## adjust memory limit
6161

62-
php_value memory_limit 768M
62+
php_value memory_limit 756M
6363
php_value max_execution_time 18000
6464

6565
############################################

.htaccess.sample

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
############################################
3636
## adjust memory limit
3737

38-
php_value memory_limit 768M
38+
php_value memory_limit 756M
3939
php_value max_execution_time 18000
4040

4141
############################################

.user.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
memory_limit = 768M
1+
memory_limit = 756M
22
max_execution_time = 18000
33
session.auto_start = off
44
suhosin.session.cryptua = off

app/code/Magento/Backend/Block/Dashboard/Graph.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -421,6 +421,8 @@ public function getChartUrl($directUrl = true)
421421
$tmpstring = implode('|', $this->_axisLabels[$idx]);
422422

423423
$valueBuffer[] = $indexid . ":|" . $tmpstring;
424+
} elseif ($idx == 'y') {
425+
$valueBuffer[] = $indexid . ":|" . implode('|', $yLabels);
424426
}
425427
$indexid++;
426428
}

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

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ public function save(\Magento\Eav\Api\Data\AttributeSetInterface $attributeSet)
6262
*/
6363
public function getList(\Magento\Framework\Api\SearchCriteriaInterface $searchCriteria)
6464
{
65+
$this->searchCriteriaBuilder->setFilterGroups((array)$searchCriteria->getFilterGroups());
6566
$this->searchCriteriaBuilder->addFilters(
6667
[
6768
$this->filterBuilder
@@ -71,9 +72,15 @@ public function getList(\Magento\Framework\Api\SearchCriteriaInterface $searchCr
7172
->create(),
7273
]
7374
);
75+
76+
$this->searchCriteriaBuilder->setSortOrders((array)$searchCriteria->getSortOrders());
7477
$this->searchCriteriaBuilder->setCurrentPage($searchCriteria->getCurrentPage());
7578
$this->searchCriteriaBuilder->setPageSize($searchCriteria->getPageSize());
76-
return $this->attributeSetRepository->getList($this->searchCriteriaBuilder->create());
79+
80+
$searchResult = $this->attributeSetRepository->getList($this->searchCriteriaBuilder->create());
81+
$searchResult->setSearchCriteria($searchCriteria);
82+
83+
return $searchResult;
7784
}
7885

7986
/**

app/code/Magento/Checkout/Block/Checkout/AttributeMerger.php

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -168,20 +168,19 @@ protected function getFieldConfig(
168168

169169
$element = [
170170
'component' => isset($additionalConfig['component']) ? $additionalConfig['component'] : $uiComponent,
171-
'config' => [
172-
// customScope is used to group elements within a single form (e.g. they can be validated separately)
173-
'customScope' => $dataScopePrefix,
174-
'customEntry' => isset($additionalConfig['config']['customEntry'])
175-
? $additionalConfig['config']['customEntry']
176-
: null,
177-
'template' => 'ui/form/field',
178-
'elementTmpl' => isset($additionalConfig['config']['elementTmpl'])
179-
? $additionalConfig['config']['elementTmpl']
180-
: $elementTemplate,
181-
'tooltip' => isset($additionalConfig['config']['tooltip'])
182-
? $additionalConfig['config']['tooltip']
183-
: null
184-
],
171+
'config' => $this->mergeConfigurationNode(
172+
'config',
173+
$additionalConfig,
174+
[
175+
'config' => [
176+
// customScope is used to group elements within a single
177+
// form (e.g. they can be validated separately)
178+
'customScope' => $dataScopePrefix,
179+
'template' => 'ui/form/field',
180+
'elementTmpl' => $elementTemplate,
181+
],
182+
]
183+
),
185184
'dataScope' => $dataScopePrefix . '.' . $attributeCode,
186185
'label' => $attributeConfig['label'],
187186
'provider' => $providerName,

app/code/Magento/Checkout/view/frontend/web/js/model/resource-url-manager.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,8 @@ define([
7575
quoteId: quoteId
7676
} : {},
7777
urls = {
78-
'guest': '/guest-carts/' + quoteId + '/coupons/' + couponCode,
79-
'customer': '/carts/mine/coupons/' + couponCode
78+
'guest': '/guest-carts/' + quoteId + '/coupons/' + encodeURIComponent(couponCode),
79+
'customer': '/carts/mine/coupons/' + encodeURIComponent(couponCode)
8080
};
8181

8282
return this.getUrl(urls, params);

app/code/Magento/OfflineShipping/Model/Carrier/Tablerate.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,8 +113,9 @@ public function collectRates(RateRequest $request)
113113

114114
// Free shipping by qty
115115
$freeQty = 0;
116+
$freePackageValue = 0;
117+
116118
if ($request->getAllItems()) {
117-
$freePackageValue = 0;
118119
foreach ($request->getAllItems() as $item) {
119120
if ($item->getProduct()->isVirtual() || $item->getParentItem()) {
120121
continue;

app/code/Magento/Reports/Model/ResourceModel/Review/Customer/Collection.php

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,21 @@ protected function _joinCustomers()
103103
return $this;
104104
}
105105

106+
/**
107+
* {@inheritdoc}
108+
*
109+
* Additional processing of 'customer_name' field is required, as it is a concat field, which can not be aliased.
110+
* @see _joinCustomers
111+
*/
112+
public function addFieldToFilter($field, $condition = null)
113+
{
114+
if ($field === 'customer_name') {
115+
$field = $this->getConnection()->getConcatSql(['customer.firstname', 'customer.lastname'], ' ');
116+
}
117+
118+
return parent::addFieldToFilter($field, $condition);
119+
}
120+
106121
/**
107122
* Get select count sql
108123
*

app/code/Magento/Sales/etc/fieldset.xml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -486,6 +486,12 @@
486486
<aspect name="to_quote_address_shipping" />
487487
<aspect name="to_cm"/>
488488
</field>
489+
<field name="discount_description">
490+
<aspect name="to_quote" />
491+
<aspect name="to_invoice" />
492+
<aspect name="to_shipment" />
493+
<aspect name="to_cm" />
494+
</field>
489495
<field name="shipping_amount">
490496
<aspect name="to_quote_address_shipping" />
491497
<aspect name="to_cm"/>

app/code/Magento/SampleData/Console/Command/SampleDataDeployCommand.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,8 @@ private function updateMemoryLimit()
136136
if (function_exists('ini_set')) {
137137
@ini_set('display_errors', 1);
138138
$memoryLimit = trim(ini_get('memory_limit'));
139-
if ($memoryLimit != -1 && $this->getMemoryInBytes($memoryLimit) < 768 * 1024 * 1024) {
140-
@ini_set('memory_limit', '768M');
139+
if ($memoryLimit != -1 && $this->getMemoryInBytes($memoryLimit) < 756 * 1024 * 1024) {
140+
@ini_set('memory_limit', '756M');
141141
}
142142
}
143143
}

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

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,3 +179,25 @@ settings/addAfter,settings/addAfter
179179
Action,Action
180180
CSV,CSV
181181
"Excel XML","Excel XML"
182+
"Please select one of the options above.","Please select one of the options above."
183+
"Please select a file.","Please select a file."
184+
"Please select one of the options.","Please select one of the options."
185+
"Please enter a value less than or equal to %s.","Please enter a value less than or equal to %s."
186+
"Please enter a value greater than or equal to %s.","Please enter a value greater than or equal to %s."
187+
"Card type does not match credit card number.","Card type does not match credit card number."
188+
"Credit card number does not match credit card type.","Credit card number does not match credit card type."
189+
"Incorrect credit card expiration date.","Incorrect credit card expiration date."
190+
"Please enter less or equal than %1 symbols.","Please enter less or equal than %1 symbols."
191+
"Please enter more or equal than %1 symbols.","Please enter more or equal than %1 symbols."
192+
"Please enter a valid value from list","Please enter a valid value from list"
193+
"Please enter valid SKU key.","Please enter valid SKU key."
194+
"Please enter a valid number.","Please enter a valid number."
195+
"Admin is a required field in the each row.","Admin is a required field in the each row."
196+
"Please fix this field.","Please fix this field."
197+
"Please enter a valid date (ISO).","Please enter a valid date (ISO)."
198+
"Please enter only digits.","Please enter only digits."
199+
"Please enter the same value again.","Please enter the same value again."
200+
"Please enter no more than {0} characters.","Please enter no more than {0} characters."
201+
"Please enter at least {0} characters.","Please enter at least {0} characters."
202+
"Please enter a value between {0} and {1} characters long.","Please enter a value between {0} and {1} characters long."
203+
"Please enter a value between {0} and {1}.","Please enter a value between {0} and {1}."

app/code/Magento/Ui/view/base/web/js/form/element/abstract.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,8 @@ define([
118118

119119
this._super();
120120

121-
scope = this.dataScope;
122-
name = scope.split('.').slice(1);
121+
scope = this.dataScope.split('.');
122+
name = scope.length > 1 ? scope.slice(1) : scope;
123123

124124
valueUpdate = this.showFallbackReset ? 'afterkeydown' : this.valueUpdate;
125125

dev/tests/api-functional/testsuite/Magento/Catalog/Api/AttributeSetRepositoryTest.php

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -165,19 +165,9 @@ public function testGetList()
165165
{
166166
$searchCriteria = [
167167
'searchCriteria' => [
168-
'filter_groups' => [
169-
[
170-
'filters' => [
171-
[
172-
'field' => 'entity_type_code',
173-
'value' => 'catalog_product',
174-
'condition_type' => 'eq',
175-
],
176-
],
177-
],
178-
],
168+
'filter_groups' => [],
179169
'current_page' => 1,
180-
'page_size' => 2,
170+
'page_size' => 2
181171
],
182172
];
183173

dev/tests/integration/testsuite/Magento/Reports/Model/ResourceModel/Review/Customer/CollectionTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ protected function setUp()
3030
*/
3131
public function testSelectCountSql()
3232
{
33-
$this->collection->addFieldToFilter('customer_name', ['like' => '%john%']);
33+
$this->collection->addFieldToFilter('customer_name', ['like' => '%John%'])->getItems();
3434
$this->assertEquals(1, $this->collection->getSize());
3535
}
3636
}

lib/web/mage/backend/suggest.js

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,7 @@
245245

246246
case keyCode.ENTER:
247247
case keyCode.NUMPAD_ENTER:
248+
this._toggleEnter(event);
248249

249250
if (this.isDropdownShown() && this._focused) {
250251
this._proxyEvents(event);
@@ -314,6 +315,30 @@
314315
this._bindDropdown();
315316
},
316317

318+
/**
319+
* @param {Object} event - event object
320+
* @private
321+
*/
322+
_toggleEnter: function (event) {
323+
var suggestList,
324+
activeItems,
325+
selectedItem;
326+
327+
suggestList = $(event.currentTarget.parentNode).find('ul').first();
328+
activeItems = suggestList.find('._active');
329+
330+
if (activeItems.length >= 0) {
331+
selectedItem = activeItems.first();
332+
333+
if (selectedItem.find('a') && selectedItem.find('a').attr('href') !== undefined) {
334+
window.location = selectedItem.find('a').attr('href');
335+
event.preventDefault();
336+
337+
return false;
338+
}
339+
}
340+
},
341+
317342
/**
318343
* @param {Object} e - event object
319344
* @private

nginx.conf.sample

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ location ~* ^/setup($|/) {
4141
fastcgi_pass fastcgi_backend;
4242

4343
fastcgi_param PHP_FLAG "session.auto_start=off \n suhosin.session.cryptua=off";
44-
fastcgi_param PHP_VALUE "memory_limit=768M \n max_execution_time=600";
44+
fastcgi_param PHP_VALUE "memory_limit=756M \n max_execution_time=600";
4545
fastcgi_read_timeout 600s;
4646
fastcgi_connect_timeout 600s;
4747

@@ -162,13 +162,13 @@ location /media/import/ {
162162
}
163163

164164
# PHP entry point for main application
165-
location ~ (index|get|static|report|404|503)\.php$ {
165+
location ~ (index|get|static|report|404|503|health_check)\.php$ {
166166
try_files $uri =404;
167167
fastcgi_pass fastcgi_backend;
168168
fastcgi_buffers 1024 4k;
169169

170170
fastcgi_param PHP_FLAG "session.auto_start=off \n suhosin.session.cryptua=off";
171-
fastcgi_param PHP_VALUE "memory_limit=768M \n max_execution_time=18000";
171+
fastcgi_param PHP_VALUE "memory_limit=756M \n max_execution_time=18000";
172172
fastcgi_read_timeout 600s;
173173
fastcgi_connect_timeout 600s;
174174

pub/.htaccess

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
############################################
3838
## Adjust memory limit
3939

40-
php_value memory_limit 768M
40+
php_value memory_limit 756M
4141
php_value max_execution_time 18000
4242

4343
############################################
@@ -60,7 +60,7 @@
6060
############################################
6161
## Adjust memory limit
6262

63-
php_value memory_limit 768M
63+
php_value memory_limit 756M
6464
php_value max_execution_time 18000
6565

6666
############################################

pub/.user.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
memory_limit = 768M
1+
memory_limit = 756M
22
max_execution_time = 18000
33
session.auto_start = off
44
suhosin.session.cryptua = off

0 commit comments

Comments
 (0)