Skip to content

Commit b5b73f9

Browse files
author
Volodymyr Zaets
committed
Merge remote-tracking branch 'origin/MAGETWO-52009' into PR
2 parents 584af4d + 372f1d5 commit b5b73f9

File tree

3 files changed

+25
-10
lines changed

3 files changed

+25
-10
lines changed

app/code/Magento/Backend/view/adminhtml/ui_component/design_config_form.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
</field>
7575
<field name="theme">
7676
<argument name="data" xsi:type="array">
77-
<item name="options" xsi:type="object">Magento\Framework\View\Design\Theme\Label</item>
77+
<item name="options" xsi:type="object">Magento\Theme\Model\Design\Theme\Label</item>
7878
<item name="config" xsi:type="array">
7979
<item name="formElement" xsi:type="string">select</item>
8080
<item name="dataType" xsi:type="string">text</item>
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<?php
2+
/**
3+
* Copyright © 2016 Magento. All rights reserved.
4+
* See COPYING.txt for license details.
5+
*/
6+
namespace Magento\Theme\Model\Design\Theme;
7+
8+
class Label extends \Magento\Framework\View\Design\Theme\Label
9+
{
10+
/**
11+
* Return labels collection array
12+
*
13+
* @param bool|string $label add empty values to result with specific label
14+
* @return array
15+
*/
16+
public function getLabelsCollection($label = false)
17+
{
18+
$options = parent::getLabelsCollection();
19+
if ($label) {
20+
array_unshift($options, ['value' => 0, 'label' => $label]);
21+
}
22+
return $options;
23+
}
24+
}

app/code/Magento/Ui/view/base/web/js/dynamic-rows/dynamic-rows.js

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -556,15 +556,6 @@ define([
556556
this.setMaxPosition();
557557
}
558558

559-
elems.forEach(function (record) {
560-
_.where(record.elems(),
561-
{
562-
formElement: 'select'
563-
}).forEach(function (elem) {
564-
elem.value(undefined);
565-
});
566-
});
567-
568559
path = this.dataScope + '.' + this.index + '.' + (this.startIndex + idx);
569560
this.source.set(path, rec);
570561
}, this);

0 commit comments

Comments
 (0)