Skip to content

Commit ede25ae

Browse files
🔃 [Magento Community Engineering] Community Contributions - 2.3-develop expedited
Accepted Community Pull Requests: - #23607: Default filter for reports set to past month (by @rogyar) - #23593: A small fix to improve format customer acl xml. (by @mrkhoa99) - #23272: hide or show the select for regions instead of enabling/disabling in customer registration (by @UB3RL33T) - #23226: Spacing issue for Gift message section in my account (by @amjadm61) Fixed GitHub Issues: - #23606: Default value for report filters might result in errors (reported by @rogyar) has been fixed in #23607 by @rogyar in 2.3-develop branch Related commits: 1. 9aa4744 - #22950: Spacing issue for Gift message section in my account (reported by @bhavik43) has been fixed in #23226 by @amjadm61 in 2.3-develop branch Related commits: 1. 878ea22 2. 02ff91b
2 parents adb5dff + 51e47eb commit ede25ae

File tree

4 files changed

+13
-12
lines changed

4 files changed

+13
-12
lines changed

app/code/Magento/Checkout/view/frontend/web/js/region-updater.js

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ define([
157157
regionInput = $(this.options.regionInputId),
158158
postcode = $(this.options.postcodeId),
159159
label = regionList.parent().siblings('label'),
160-
requiredLabel = regionList.parents('div.field');
160+
container = regionList.parents('div.field');
161161

162162
this._clearError();
163163
this._checkRegionRequired(country);
@@ -181,15 +181,16 @@ define([
181181

182182
if (this.options.isRegionRequired) {
183183
regionList.addClass('required-entry').removeAttr('disabled');
184-
requiredLabel.addClass('required');
184+
container.addClass('required').show();
185185
} else {
186186
regionList.removeClass('required-entry validate-select').removeAttr('data-validate');
187-
requiredLabel.removeClass('required');
187+
container.removeClass('required');
188188

189189
if (!this.options.optionalRegionAllowed) { //eslint-disable-line max-depth
190-
regionList.attr('disabled', 'disabled');
190+
regionList.hide();
191+
container.hide();
191192
} else {
192-
regionList.removeAttr('disabled');
193+
regionList.show();
193194
}
194195
}
195196

@@ -201,12 +202,13 @@ define([
201202

202203
if (this.options.isRegionRequired) {
203204
regionInput.addClass('required-entry').removeAttr('disabled');
204-
requiredLabel.addClass('required');
205+
container.addClass('required').show();
205206
} else {
206207
if (!this.options.optionalRegionAllowed) { //eslint-disable-line max-depth
207208
regionInput.attr('disabled', 'disabled');
209+
container.hide();
208210
}
209-
requiredLabel.removeClass('required');
211+
container.removeClass('required');
210212
regionInput.removeClass('required-entry');
211213
}
212214

app/code/Magento/Customer/etc/acl.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
<resource id="Magento_Customer::config_customer" title="Customers Section" translate="title" sortOrder="50" />
2727
</resource>
2828
</resource>
29-
</resource>
29+
</resource>
3030
</resource>
3131
</resources>
3232
</acl>

app/code/Magento/Reports/Block/Adminhtml/Grid.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,8 @@ protected function _prepareCollection()
135135
$data = $this->parameters->toArray();
136136

137137
if (!isset($data['report_from'])) {
138-
// getting all reports from 2001 year
139-
$date = (new \DateTime())->setTimestamp(mktime(0, 0, 0, 1, 1, 2001));
138+
// Get records for the past month
139+
$date = new \DateTime('-1 month');
140140
$data['report_from'] = $this->_localeDate->formatDateTime(
141141
$date,
142142
\IntlDateFormatter::SHORT,
@@ -145,7 +145,6 @@ protected function _prepareCollection()
145145
}
146146

147147
if (!isset($data['report_to'])) {
148-
// getting all reports from 2001 year
149148
$date = new \DateTime();
150149
$data['report_to'] = $this->_localeDate->formatDateTime(
151150
$date,

app/design/frontend/Magento/luma/Magento_Sales/web/css/source/_module.less

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@
9797
}
9898

9999
&.options {
100-
padding: 0 0 15px;
100+
padding: 10px 10px 15px;
101101
}
102102
}
103103

0 commit comments

Comments
 (0)