Skip to content

Commit e920d24

Browse files
author
Oleg Zinoviev
committed
MAGETWO-35091: UI improvements
- Merge branch 'MAGETWO-35091' into UI - Conflicts: - app/design/adminhtml/Magento/backend/web/css/override.less - app/design/adminhtml/Magento/backend/web/css/styles-migration.less - app/design/adminhtml/Magento/backend/web/css/styles-old.less
1 parent f1fb203 commit e920d24

File tree

64 files changed

+765
-318
lines changed

Some content is hidden

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

64 files changed

+765
-318
lines changed

app/code/Magento/Backend/Block/System/Design/Edit/Tab/General.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,6 @@ protected function _prepareForm()
100100
'label' => __('Date From'),
101101
'title' => __('Date From'),
102102
'name' => 'date_from',
103-
'image' => $this->getViewFileUrl('images/grid-cal.png'),
104103
'date_format' => $dateFormat
105104
//'required' => true
106105
]
@@ -112,7 +111,6 @@ protected function _prepareForm()
112111
'label' => __('Date To'),
113112
'title' => __('Date To'),
114113
'name' => 'date_to',
115-
'image' => $this->getViewFileUrl('images/grid-cal.png'),
116114
'date_format' => $dateFormat
117115
//'required' => true
118116
]

app/code/Magento/Backend/Block/Widget/Form.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,6 @@ protected function _applyTypeSpecificConfig($inputType, $element, \Magento\Eav\M
226226
$element->setCanBeEmpty(true);
227227
break;
228228
case 'date':
229-
$element->setImage($this->getViewFileUrl('images/grid-cal.png'));
230229
$element->setDateFormat($this->_localeDate->getDateFormatWithLongYear());
231230
break;
232231
case 'multiline':

app/code/Magento/Backend/Block/Widget/Grid/Column/Filter/Date.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,10 +95,6 @@ public function getHtml()
9595
dateFormat: "' .
9696
$format .
9797
'",
98-
buttonImage: "' .
99-
$this->getViewFileUrl(
100-
'images/grid-cal.png'
101-
) . '",
10298
buttonText: "' . $this->escapeHtml(__('Date selector')) .
10399
'",
104100
from: {

app/code/Magento/Backend/Block/Widget/Grid/Column/Filter/Datetime.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,6 @@ public function getHtml()
129129
dateFormat: "' . $format . '",
130130
timeFormat: "' . $timeFormat . '",
131131
showsTime: ' . ($this->getColumn()->getFilterTime() ? 'true' : 'false') . ',
132-
buttonImage: "' . $this->getViewFileUrl('images/grid-cal.png') . '",
133132
buttonText: "' . $this->escapeHtml(__('Date selector')) . '",
134133
from: {
135134
id: "' . $htmlId . '_from"

app/code/Magento/Backend/view/adminhtml/templates/page/js/calendar.phtml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,8 @@ require([
4141
showAnim: "",
4242
changeMonth: true,
4343
changeYear: true,
44-
buttonImageOnly: true,
44+
buttonImageOnly: null,
45+
buttonImage: null,
4546
showButtonPanel: true,
4647
showOtherMonths: true,
4748
showWeek: false,

app/code/Magento/Catalog/Block/Adminhtml/Product/Attribute/Edit/Tab/Advanced.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,6 @@ protected function _prepareForm()
123123
'name' => 'default_value_date',
124124
'label' => __('Default Value'),
125125
'title' => __('Default Value'),
126-
'image' => $this->getViewFileUrl('images/grid-cal.png'),
127126
'value' => $attributeObject->getDefaultValue(),
128127
'date_format' => $dateFormat
129128
]

app/code/Magento/Catalog/view/frontend/templates/product/view/options/type/date.phtml

Lines changed: 31 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -12,37 +12,38 @@
1212
<?php $class = ($_option->getIsRequire()) ? ' required' : ''; ?>
1313
<div class="field date<?php echo $class; ?>"
1414
data-mage-init='{"priceOptionDate":{"fromSelector":"#product_addtocart_form"}}'>
15-
<label class="label">
16-
<span><?php echo $block->escapeHtml($_option->getTitle()) ?></span>
17-
<?php echo $block->getFormatedPrice() ?>
18-
</label>
19-
<div class="control">
20-
<?php if ($_option->getType() == \Magento\Catalog\Model\Product\Option::OPTION_TYPE_DATE_TIME
21-
|| $_option->getType() == \Magento\Catalog\Model\Product\Option::OPTION_TYPE_DATE): ?>
15+
<fieldset class="fieldset fieldset-product-options-inner<?php echo $class; ?>">
16+
<legend class="legend">
17+
<span><?php echo $block->escapeHtml($_option->getTitle()) ?></span>
18+
<?php echo $block->getFormatedPrice() ?>
19+
</legend>
20+
<div class="control">
21+
<?php if ($_option->getType() == \Magento\Catalog\Model\Product\Option::OPTION_TYPE_DATE_TIME
22+
|| $_option->getType() == \Magento\Catalog\Model\Product\Option::OPTION_TYPE_DATE): ?>
2223

23-
<?php echo $block->getDateHtml() ?>
24+
<?php echo $block->getDateHtml() ?>
2425

25-
<?php endif; ?>
26+
<?php endif; ?>
2627

27-
<?php if ($_option->getType() == \Magento\Catalog\Model\Product\Option::OPTION_TYPE_DATE_TIME
28-
|| $_option->getType() == \Magento\Catalog\Model\Product\Option::OPTION_TYPE_TIME): ?>
29-
<span class="time-picker"><?php echo $block->getTimeHtml() ?></span>
30-
<?php endif; ?>
28+
<?php if ($_option->getType() == \Magento\Catalog\Model\Product\Option::OPTION_TYPE_DATE_TIME
29+
|| $_option->getType() == \Magento\Catalog\Model\Product\Option::OPTION_TYPE_TIME): ?>
30+
<span class="time-picker"><?php echo $block->getTimeHtml() ?></span>
31+
<?php endif; ?>
3132

32-
<?php if ($_option->getIsRequire()): ?>
33-
<input type="hidden"
34-
name="validate_datetime_<?php echo $_optionId ?>"
35-
class="validate-datetime-<?php echo $_optionId ?>"
36-
value=""
37-
data-validate="{'validate-required-datetime':<?php echo $_optionId?>}"/>
38-
<?php else: ?>
39-
<input type="hidden"
40-
name="validate_datetime_<?php echo $_optionId ?>"
41-
class="validate-datetime-<?php echo $_optionId ?>"
42-
value=""
43-
data-validate="{'validate-optional-datetime':<?php echo $_optionId?>}"/>
44-
<?php endif; ?>
45-
<script type="text/x-magento-init">
33+
<?php if ($_option->getIsRequire()): ?>
34+
<input type="hidden"
35+
name="validate_datetime_<?php echo $_optionId ?>"
36+
class="validate-datetime-<?php echo $_optionId ?>"
37+
value=""
38+
data-validate="{'validate-required-datetime':<?php echo $_optionId?>}"/>
39+
<?php else: ?>
40+
<input type="hidden"
41+
name="validate_datetime_<?php echo $_optionId ?>"
42+
class="validate-datetime-<?php echo $_optionId ?>"
43+
value=""
44+
data-validate="{'validate-optional-datetime':<?php echo $_optionId?>}"/>
45+
<?php endif; ?>
46+
<script type="text/x-magento-init">
4647
{
4748
"#product_addtocart_form": {
4849
"validation": {
@@ -51,5 +52,7 @@
5152
}
5253
}
5354
</script>
54-
</div>
55+
</div>
56+
</fieldset>
57+
5558
</div>

app/code/Magento/CatalogRule/Block/Adminhtml/Promo/Catalog/Edit/Tab/Main.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,6 @@ protected function _prepareForm()
196196
'name' => 'from_date',
197197
'label' => __('From Date'),
198198
'title' => __('From Date'),
199-
'image' => $this->getViewFileUrl('images/grid-cal.png'),
200199
'input_format' => \Magento\Framework\Stdlib\DateTime::DATE_INTERNAL_FORMAT,
201200
'date_format' => $dateFormat
202201
]
@@ -208,7 +207,6 @@ protected function _prepareForm()
208207
'name' => 'to_date',
209208
'label' => __('To Date'),
210209
'title' => __('To Date'),
211-
'image' => $this->getViewFileUrl('images/grid-cal.png'),
212210
'input_format' => \Magento\Framework\Stdlib\DateTime::DATE_INTERNAL_FORMAT,
213211
'date_format' => $dateFormat
214212
]

app/code/Magento/Cms/Block/Adminhtml/Page/Edit/Tab/Design.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,6 @@ protected function _prepareForm()
125125
[
126126
'name' => 'custom_theme_from',
127127
'label' => __('Custom Design From'),
128-
'image' => $this->getViewFileUrl('images/grid-cal.png'),
129128
'date_format' => $dateFormat,
130129
'disabled' => $isElementDisabled,
131130
'class' => 'validate-date validate-date-range date-range-custom_theme-from'
@@ -138,7 +137,6 @@ protected function _prepareForm()
138137
[
139138
'name' => 'custom_theme_to',
140139
'label' => __('Custom Design To'),
141-
'image' => $this->getViewFileUrl('images/grid-cal.png'),
142140
'date_format' => $dateFormat,
143141
'disabled' => $isElementDisabled,
144142
'class' => 'validate-date validate-date-range date-range-custom_theme-to'

app/code/Magento/Customer/Block/Adminhtml/Edit/Tab/GenericMetadata.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,6 @@ protected function _applyTypeSpecificConfigCustomer(
9898
$element->setCanBeEmpty(true);
9999
break;
100100
case 'date':
101-
$element->setImage($this->getViewFileUrl('images/grid-cal.png'));
102101
$element->setDateFormat($this->_localeDate->getDateFormatWithLongYear());
103102
break;
104103
case 'multiline':

0 commit comments

Comments
 (0)