Skip to content

Commit 6cb7032

Browse files
Merge remote-tracking branch 'remotes/github/2.3-develop' into MAGETWO-70599-V2
2 parents f00cbe8 + 6494c9f commit 6cb7032

File tree

146 files changed

+3016
-632
lines changed

Some content is hidden

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

146 files changed

+3016
-632
lines changed

app/code/Magento/AdvancedSearch/view/adminhtml/web/js/testconnection.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ define([
4040
element = $('#' + this.options.elementId),
4141
self = this,
4242
params = {},
43-
msg = '';
43+
msg = '',
44+
fieldToCheck = this.options.fieldToCheck || 'success';
4445

4546
element.removeClass('success').addClass('fail');
4647
$.each($.parseJSON(this.options.fieldMapping), function (key, el) {
@@ -49,9 +50,10 @@ define([
4950
$.ajax({
5051
url: this.options.url,
5152
showLoader: true,
52-
data: params
53+
data: params,
54+
headers: this.options.headers || {}
5355
}).done(function (response) {
54-
if (response.success) {
56+
if (response[fieldToCheck]) {
5557
element.removeClass('fail').addClass('success');
5658
result = self.options.successText;
5759
} else {

app/code/Magento/Backend/Test/Mftf/Test/AdminDashboardWithChartsChart.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
<test name="AdminDashboardWithChartsTest">
1212
<annotations>
1313
<features value="Backend"/>
14+
<stories value="Dashboard"/>
1415
<title value="Google chart on Magento dashboard"/>
1516
<description value="Google chart on Magento dashboard page is not broken"/>
1617
<severity value="MAJOR"/>

app/code/Magento/Backend/Test/Mftf/Test/AdminLoginAfterJSMinificationTest.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,11 @@
1111
<test name="AdminLoginAfterJSMinificationTest">
1212
<annotations>
1313
<features value="Backend"/>
14+
<stories value="Login"/>
1415
<title value="Admin panel should be accessible with JS minification enabled"/>
1516
<description value="Admin panel should be accessible with JS minification enabled"/>
1617
<testCaseId value="MC-14104" />
18+
<severity value="MAJOR"/>
1719
<group value="backend"/>
1820
<group value="mtf_migrated"/>
1921
</annotations>

app/code/Magento/Backend/Test/Mftf/Test/AdminUserLoginWithStoreCodeInUrlTest.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,11 @@
1111
<test name="AdminUserLoginWithStoreCodeInUrlTest">
1212
<annotations>
1313
<features value="Backend"/>
14+
<stories value="Login"/>
1415
<title value="Admin panel should be accessible with Add Store Code to URL setting enabled"/>
1516
<description value="Admin panel should be accessible with Add Store Code to URL setting enabled"/>
1617
<testCaseId value="MC-14279" />
18+
<severity value="CRITICAL"/>
1719
<group value="backend"/>
1820
<group value="mtf_migrated"/>
1921
</annotations>

app/code/Magento/Bundle/Test/Mftf/Test/StorefrontAddBundleOptionsToCartTest.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
<severity value="MAJOR"/>
1818
<testCaseId value="MAGETWO-95933"/>
1919
<group value="Bundle"/>
20+
<skip>
21+
<issueId value="MC-16684"/>
22+
</skip>
2023
</annotations>
2124
<before>
2225
<actionGroup ref="LoginAsAdmin" stepKey="login"/>

app/code/Magento/Bundle/etc/db_schema.xml

Lines changed: 33 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@
9797
comment="Website Id"/>
9898
<column xsi:type="smallint" name="selection_price_type" padding="5" unsigned="true" nullable="false"
9999
identity="false" default="0" comment="Selection Price Type"/>
100-
<column xsi:type="decimal" name="selection_price_value" scale="4" precision="12" unsigned="false"
100+
<column xsi:type="decimal" name="selection_price_value" scale="6" precision="20" unsigned="false"
101101
nullable="false" default="0" comment="Selection Price Value"/>
102102
<column xsi:type="int" name="parent_product_id" padding="10" unsigned="true" nullable="false" identity="false"
103103
comment="Parent Product Id"/>
@@ -125,9 +125,9 @@
125125
comment="Website Id"/>
126126
<column xsi:type="int" name="customer_group_id" padding="10" unsigned="true" nullable="false" identity="false"
127127
comment="Customer Group ID"/>
128-
<column xsi:type="decimal" name="min_price" scale="4" precision="12" unsigned="false" nullable="false"
128+
<column xsi:type="decimal" name="min_price" scale="6" precision="20" unsigned="false" nullable="false"
129129
comment="Min Price"/>
130-
<column xsi:type="decimal" name="max_price" scale="4" precision="12" unsigned="false" nullable="false"
130+
<column xsi:type="decimal" name="max_price" scale="6" precision="20" unsigned="false" nullable="false"
131131
comment="Max Price"/>
132132
<constraint xsi:type="primary" referenceId="PRIMARY">
133133
<column name="entity_id"/>
@@ -181,21 +181,21 @@
181181
default="0" comment="Tax Class ID"/>
182182
<column xsi:type="smallint" name="price_type" padding="5" unsigned="true" nullable="false" identity="false"
183183
comment="Price Type"/>
184-
<column xsi:type="decimal" name="special_price" scale="4" precision="12" unsigned="false" nullable="true"
184+
<column xsi:type="decimal" name="special_price" scale="6" precision="20" unsigned="false" nullable="true"
185185
comment="Special Price"/>
186-
<column xsi:type="decimal" name="tier_percent" scale="4" precision="12" unsigned="false" nullable="true"
186+
<column xsi:type="decimal" name="tier_percent" scale="6" precision="20" unsigned="false" nullable="true"
187187
comment="Tier Percent"/>
188-
<column xsi:type="decimal" name="orig_price" scale="4" precision="12" unsigned="false" nullable="true"
188+
<column xsi:type="decimal" name="orig_price" scale="6" precision="20" unsigned="false" nullable="true"
189189
comment="Orig Price"/>
190-
<column xsi:type="decimal" name="price" scale="4" precision="12" unsigned="false" nullable="true"
190+
<column xsi:type="decimal" name="price" scale="6" precision="20" unsigned="false" nullable="true"
191191
comment="Price"/>
192-
<column xsi:type="decimal" name="min_price" scale="4" precision="12" unsigned="false" nullable="true"
192+
<column xsi:type="decimal" name="min_price" scale="6" precision="20" unsigned="false" nullable="true"
193193
comment="Min Price"/>
194-
<column xsi:type="decimal" name="max_price" scale="4" precision="12" unsigned="false" nullable="true"
194+
<column xsi:type="decimal" name="max_price" scale="6" precision="20" unsigned="false" nullable="true"
195195
comment="Max Price"/>
196-
<column xsi:type="decimal" name="tier_price" scale="4" precision="12" unsigned="false" nullable="true"
196+
<column xsi:type="decimal" name="tier_price" scale="6" precision="20" unsigned="false" nullable="true"
197197
comment="Tier Price"/>
198-
<column xsi:type="decimal" name="base_tier" scale="4" precision="12" unsigned="false" nullable="true"
198+
<column xsi:type="decimal" name="base_tier" scale="6" precision="20" unsigned="false" nullable="true"
199199
comment="Base Tier"/>
200200
<constraint xsi:type="primary" referenceId="PRIMARY">
201201
<column name="entity_id"/>
@@ -215,21 +215,21 @@
215215
default="0" comment="Tax Class ID"/>
216216
<column xsi:type="smallint" name="price_type" padding="5" unsigned="true" nullable="false" identity="false"
217217
comment="Price Type"/>
218-
<column xsi:type="decimal" name="special_price" scale="4" precision="12" unsigned="false" nullable="true"
218+
<column xsi:type="decimal" name="special_price" scale="6" precision="20" unsigned="false" nullable="true"
219219
comment="Special Price"/>
220-
<column xsi:type="decimal" name="tier_percent" scale="4" precision="12" unsigned="false" nullable="true"
220+
<column xsi:type="decimal" name="tier_percent" scale="6" precision="20" unsigned="false" nullable="true"
221221
comment="Tier Percent"/>
222-
<column xsi:type="decimal" name="orig_price" scale="4" precision="12" unsigned="false" nullable="true"
222+
<column xsi:type="decimal" name="orig_price" scale="6" precision="20" unsigned="false" nullable="true"
223223
comment="Orig Price"/>
224-
<column xsi:type="decimal" name="price" scale="4" precision="12" unsigned="false" nullable="true"
224+
<column xsi:type="decimal" name="price" scale="6" precision="20" unsigned="false" nullable="true"
225225
comment="Price"/>
226-
<column xsi:type="decimal" name="min_price" scale="4" precision="12" unsigned="false" nullable="true"
226+
<column xsi:type="decimal" name="min_price" scale="6" precision="20" unsigned="false" nullable="true"
227227
comment="Min Price"/>
228-
<column xsi:type="decimal" name="max_price" scale="4" precision="12" unsigned="false" nullable="true"
228+
<column xsi:type="decimal" name="max_price" scale="6" precision="20" unsigned="false" nullable="true"
229229
comment="Max Price"/>
230-
<column xsi:type="decimal" name="tier_price" scale="4" precision="12" unsigned="false" nullable="true"
230+
<column xsi:type="decimal" name="tier_price" scale="6" precision="20" unsigned="false" nullable="true"
231231
comment="Tier Price"/>
232-
<column xsi:type="decimal" name="base_tier" scale="4" precision="12" unsigned="false" nullable="true"
232+
<column xsi:type="decimal" name="base_tier" scale="6" precision="20" unsigned="false" nullable="true"
233233
comment="Base Tier"/>
234234
<constraint xsi:type="primary" referenceId="PRIMARY">
235235
<column name="entity_id"/>
@@ -253,9 +253,9 @@
253253
default="0" comment="Group Type"/>
254254
<column xsi:type="smallint" name="is_required" padding="5" unsigned="true" nullable="true" identity="false"
255255
default="0" comment="Is Required"/>
256-
<column xsi:type="decimal" name="price" scale="4" precision="12" unsigned="false" nullable="true"
256+
<column xsi:type="decimal" name="price" scale="6" precision="20" unsigned="false" nullable="true"
257257
comment="Price"/>
258-
<column xsi:type="decimal" name="tier_price" scale="4" precision="12" unsigned="false" nullable="true"
258+
<column xsi:type="decimal" name="tier_price" scale="6" precision="20" unsigned="false" nullable="true"
259259
comment="Tier Price"/>
260260
<constraint xsi:type="primary" referenceId="PRIMARY">
261261
<column name="entity_id"/>
@@ -281,9 +281,9 @@
281281
default="0" comment="Group Type"/>
282282
<column xsi:type="smallint" name="is_required" padding="5" unsigned="true" nullable="true" identity="false"
283283
default="0" comment="Is Required"/>
284-
<column xsi:type="decimal" name="price" scale="4" precision="12" unsigned="false" nullable="true"
284+
<column xsi:type="decimal" name="price" scale="6" precision="20" unsigned="false" nullable="true"
285285
comment="Price"/>
286-
<column xsi:type="decimal" name="tier_price" scale="4" precision="12" unsigned="false" nullable="true"
286+
<column xsi:type="decimal" name="tier_price" scale="6" precision="20" unsigned="false" nullable="true"
287287
comment="Tier Price"/>
288288
<constraint xsi:type="primary" referenceId="PRIMARY">
289289
<column name="entity_id"/>
@@ -303,15 +303,15 @@
303303
comment="Website ID"/>
304304
<column xsi:type="int" name="option_id" padding="10" unsigned="true" nullable="false" identity="false"
305305
default="0" comment="Option Id"/>
306-
<column xsi:type="decimal" name="min_price" scale="4" precision="12" unsigned="false" nullable="true"
306+
<column xsi:type="decimal" name="min_price" scale="6" precision="20" unsigned="false" nullable="true"
307307
comment="Min Price"/>
308-
<column xsi:type="decimal" name="alt_price" scale="4" precision="12" unsigned="false" nullable="true"
308+
<column xsi:type="decimal" name="alt_price" scale="6" precision="20" unsigned="false" nullable="true"
309309
comment="Alt Price"/>
310-
<column xsi:type="decimal" name="max_price" scale="4" precision="12" unsigned="false" nullable="true"
310+
<column xsi:type="decimal" name="max_price" scale="6" precision="20" unsigned="false" nullable="true"
311311
comment="Max Price"/>
312-
<column xsi:type="decimal" name="tier_price" scale="4" precision="12" unsigned="false" nullable="true"
312+
<column xsi:type="decimal" name="tier_price" scale="6" precision="20" unsigned="false" nullable="true"
313313
comment="Tier Price"/>
314-
<column xsi:type="decimal" name="alt_tier_price" scale="4" precision="12" unsigned="false" nullable="true"
314+
<column xsi:type="decimal" name="alt_tier_price" scale="6" precision="20" unsigned="false" nullable="true"
315315
comment="Alt Tier Price"/>
316316
<constraint xsi:type="primary" referenceId="PRIMARY">
317317
<column name="entity_id"/>
@@ -330,15 +330,15 @@
330330
comment="Website ID"/>
331331
<column xsi:type="int" name="option_id" padding="10" unsigned="true" nullable="false" identity="false"
332332
default="0" comment="Option Id"/>
333-
<column xsi:type="decimal" name="min_price" scale="4" precision="12" unsigned="false" nullable="true"
333+
<column xsi:type="decimal" name="min_price" scale="6" precision="20" unsigned="false" nullable="true"
334334
comment="Min Price"/>
335-
<column xsi:type="decimal" name="alt_price" scale="4" precision="12" unsigned="false" nullable="true"
335+
<column xsi:type="decimal" name="alt_price" scale="6" precision="20" unsigned="false" nullable="true"
336336
comment="Alt Price"/>
337-
<column xsi:type="decimal" name="max_price" scale="4" precision="12" unsigned="false" nullable="true"
337+
<column xsi:type="decimal" name="max_price" scale="6" precision="20" unsigned="false" nullable="true"
338338
comment="Max Price"/>
339-
<column xsi:type="decimal" name="tier_price" scale="4" precision="12" unsigned="false" nullable="true"
339+
<column xsi:type="decimal" name="tier_price" scale="6" precision="20" unsigned="false" nullable="true"
340340
comment="Tier Price"/>
341-
<column xsi:type="decimal" name="alt_tier_price" scale="4" precision="12" unsigned="false" nullable="true"
341+
<column xsi:type="decimal" name="alt_tier_price" scale="6" precision="20" unsigned="false" nullable="true"
342342
comment="Alt Tier Price"/>
343343
<constraint xsi:type="primary" referenceId="PRIMARY">
344344
<column name="entity_id"/>

app/code/Magento/Catalog/Model/Product/Attribute/Backend/TierPrice/UpdateHandler.php

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,9 @@
77

88
namespace Magento\Catalog\Model\Product\Attribute\Backend\TierPrice;
99

10-
use Magento\Framework\EntityManager\Operation\ExtensionInterface;
1110
use Magento\Catalog\Api\Data\ProductInterface;
11+
use Magento\Framework\App\ObjectManager;
12+
use Magento\Framework\Locale\FormatInterface;
1213
use Magento\Store\Model\StoreManagerInterface;
1314
use Magento\Catalog\Api\ProductAttributeRepositoryInterface;
1415
use Magento\Customer\Api\GroupManagementInterface;
@@ -40,26 +41,34 @@ class UpdateHandler extends AbstractHandler
4041
*/
4142
private $tierPriceResource;
4243

44+
/**
45+
* @var FormatInterface
46+
*/
47+
private $localeFormat;
48+
4349
/**
4450
* @param \Magento\Store\Model\StoreManagerInterface $storeManager
4551
* @param \Magento\Catalog\Api\ProductAttributeRepositoryInterface $attributeRepository
4652
* @param \Magento\Customer\Api\GroupManagementInterface $groupManagement
4753
* @param \Magento\Framework\EntityManager\MetadataPool $metadataPool
4854
* @param \Magento\Catalog\Model\ResourceModel\Product\Attribute\Backend\Tierprice $tierPriceResource
55+
* @param FormatInterface|null $localeFormat
4956
*/
5057
public function __construct(
5158
StoreManagerInterface $storeManager,
5259
ProductAttributeRepositoryInterface $attributeRepository,
5360
GroupManagementInterface $groupManagement,
5461
MetadataPool $metadataPool,
55-
Tierprice $tierPriceResource
62+
Tierprice $tierPriceResource,
63+
FormatInterface $localeFormat = null
5664
) {
5765
parent::__construct($groupManagement);
5866

5967
$this->storeManager = $storeManager;
6068
$this->attributeRepository = $attributeRepository;
6169
$this->metadataPoll = $metadataPool;
6270
$this->tierPriceResource = $tierPriceResource;
71+
$this->localeFormat = $localeFormat ?: ObjectManager::getInstance()->get(FormatInterface::class);
6372
}
6473

6574
/**
@@ -125,8 +134,9 @@ private function updateValues(array $valuesToUpdate, array $oldValues): bool
125134
{
126135
$isChanged = false;
127136
foreach ($valuesToUpdate as $key => $value) {
128-
if ((!empty($value['value']) && (float)$oldValues[$key]['price'] !== (float)$value['value'])
129-
|| $this->getPercentage($oldValues[$key]) !== $this->getPercentage($value)
137+
if ((!empty($value['value'])
138+
&& (float)$oldValues[$key]['price'] !== $this->localeFormat->getNumber($value['value'])
139+
) || $this->getPercentage($oldValues[$key]) !== $this->getPercentage($value)
130140
) {
131141
$price = new \Magento\Framework\DataObject(
132142
[

0 commit comments

Comments
 (0)