Skip to content

Commit 7e418f3

Browse files
author
Mykhailo Miroshnikov
committed
Merge branch 'develop' into MAGETWO-34476
2 parents 693960f + 10d1600 commit 7e418f3

File tree

1,167 files changed

+17210
-16887
lines changed

Some content is hidden

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

1,167 files changed

+17210
-16887
lines changed

CHANGELOG.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,36 @@
1+
0.42.0-beta11
2+
=============
3+
* Various improvements:
4+
* Added LICENSE to Developer module
5+
* Refactored Catalog and related module to use mutable data object interface
6+
* Refactored Sales and related modules to use mutable data interfaces
7+
* Setup:
8+
* Added styles for new module enabling / disabling section in Installation wizard
9+
* Modules Install and upgrade capabilities are refactored to implement interfaces used by Setup application
10+
* Framework:
11+
* Moved/refactored Magento\IO\Sftp adapter into Filesystem library
12+
* Removed Magento IO library
13+
* Implemented Dynamic Types Binding in SOAP
14+
* Implemented Extensible Attributes generation
15+
* Improved Web API Related Code Quality
16+
* Moved Specific Helper Components From the Magento/Core Module to Magento/Framework
17+
* Performance:
18+
* Inline JS code is eliminated
19+
* Created fixture for changing Magento config update via Performance Toolkit Generator
20+
* Fixed bugs:
21+
* Issue with multiple addresses checkout
22+
* Issue with catalog page update after a product status changes
23+
* Issue with distance between "Log in" & "or" & "Register" in Frontend header
24+
* Issue with tax details and amounts in frontend and backend order
25+
* JavaScript error when clicking on toggle arrow to show FPT in shopping cart
26+
* PHP Warning when trying to checkout with Multiple Addresses on review order page
27+
* Functional tests:
28+
* Refactored end-to-end test for order placement from backend and for OnePageCheckout
29+
* GitHub requests:
30+
* [#1035] (https://github.com/magento/magento2/issues/1035) -- Bug in Magento\Framework\Simplexml\Element::appendChild
31+
* [#1053] (https://github.com/magento/magento2/issues/1053) -- #865: add getParams/setParam to RequestInterface
32+
* [#1066] (https://github.com/magento/magento2/issues/1066) -- PHP 5.5.16-1+deb.sury.org~precise+1
33+
134
0.42.0-beta10
235
=============
336
* Framework

app/bootstrap.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,5 +35,5 @@
3535
\Magento\Framework\Profiler::applyConfig($_SERVER['MAGE_PROFILER'], BP, !empty($_REQUEST['isAjax']));
3636
}
3737
if (ini_get('date.timezone') == '') {
38-
date_default_timezone_set(\Magento\Framework\Stdlib\DateTime\TimezoneInterface::DEFAULT_TIMEZONE);
38+
date_default_timezone_set('UTC');
3939
}

app/code/Magento/AdminNotification/Block/ToolbarEntry.php

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -99,13 +99,18 @@ public function getLatestUnreadNotifications()
9999
*/
100100
public function formatNotificationDate($dateString)
101101
{
102-
if (date('Ymd') == date('Ymd', strtotime($dateString))) {
103-
return $this->formatTime(
104-
$dateString,
105-
\Magento\Framework\Stdlib\DateTime\TimezoneInterface::FORMAT_TYPE_SHORT,
106-
false
102+
$date = new \DateTime($dateString);
103+
if ($date == new \DateTime('today')) {
104+
return $this->_localeDate->formatDateTime(
105+
$date,
106+
\IntlDateFormatter::NONE,
107+
\IntlDateFormatter::SHORT
107108
);
108109
}
109-
return $this->formatDate($dateString, \Magento\Framework\Stdlib\DateTime\TimezoneInterface::FORMAT_TYPE_MEDIUM, true);
110+
return $this->_localeDate->formatDateTime(
111+
$date,
112+
\IntlDateFormatter::MEDIUM,
113+
\IntlDateFormatter::MEDIUM
114+
);
110115
}
111116
}

app/code/Magento/AdminNotification/composer.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@
33
"description": "N/A",
44
"require": {
55
"php": "~5.5.0|~5.6.0",
6-
"magento/module-store": "0.42.0-beta10",
7-
"magento/module-backend": "0.42.0-beta10",
8-
"magento/module-media-storage": "0.42.0-beta10",
9-
"magento/framework": "0.42.0-beta10",
6+
"magento/module-store": "0.42.0-beta11",
7+
"magento/module-backend": "0.42.0-beta11",
8+
"magento/module-media-storage": "0.42.0-beta11",
9+
"magento/framework": "0.42.0-beta11",
1010
"lib-libxml": "*",
1111
"magento/magento-composer-installer": "*"
1212
},
1313
"type": "magento2-module",
14-
"version": "0.42.0-beta10",
14+
"version": "0.42.0-beta11",
1515
"license": [
1616
"OSL-3.0",
1717
"AFL-3.0"

app/code/Magento/Authorization/composer.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
"description": "Authorization module provides access to Magento ACL functionality.",
44
"require": {
55
"php": "~5.5.0|~5.6.0",
6-
"magento/module-backend": "0.42.0-beta10",
7-
"magento/framework": "0.42.0-beta10",
6+
"magento/module-backend": "0.42.0-beta11",
7+
"magento/framework": "0.42.0-beta11",
88
"magento/magento-composer-installer": "*"
99
},
1010
"type": "magento2-module",
11-
"version": "0.42.0-beta10",
11+
"version": "0.42.0-beta11",
1212
"license": [
1313
"OSL-3.0",
1414
"AFL-3.0"

app/code/Magento/Backend/App/AbstractAction.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ protected function _processLocaleSettings()
290290
}
291291

292292
if (is_null($this->_getSession()->getLocale())) {
293-
$this->_getSession()->setLocale($this->_localeResolver->getLocaleCode());
293+
$this->_getSession()->setLocale($this->_localeResolver->getLocale());
294294
}
295295

296296
return $this;

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

Lines changed: 18 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -99,27 +99,19 @@ class Graph extends \Magento\Backend\Block\Dashboard\AbstractDashboard
9999
*/
100100
protected $_dashboardData = null;
101101

102-
/**
103-
* @var \Magento\Framework\Locale\ListsInterface
104-
*/
105-
protected $_localeLists = null;
106-
107102
/**
108103
* @param \Magento\Backend\Block\Template\Context $context
109104
* @param \Magento\Reports\Model\Resource\Order\CollectionFactory $collectionFactory
110105
* @param \Magento\Backend\Helper\Dashboard\Data $dashboardData
111-
* @param \Magento\Framework\Locale\ListsInterface $localeLists
112106
* @param array $data
113107
*/
114108
public function __construct(
115109
\Magento\Backend\Block\Template\Context $context,
116110
\Magento\Reports\Model\Resource\Order\CollectionFactory $collectionFactory,
117111
\Magento\Backend\Helper\Dashboard\Data $dashboardData,
118-
\Magento\Framework\Locale\ListsInterface $localeLists,
119112
array $data = []
120113
) {
121114
$this->_dashboardData = $dashboardData;
122-
$this->_localeLists = $localeLists;
123115
parent::__construct($context, $collectionFactory, $data);
124116
}
125117

@@ -213,34 +205,36 @@ public function getChartUrl($directUrl = true)
213205
\Magento\Store\Model\ScopeInterface::SCOPE_STORE
214206
);
215207

208+
/** @var \DateTime $dateStart */
209+
/** @var \DateTime $dateEnd */
216210
list($dateStart, $dateEnd) = $this->_collectionFactory->create()->getDateRange(
217211
$this->getDataHelper()->getParam('period'),
218212
'',
219213
'',
220214
true
221215
);
222216

223-
$dateStart->setTimezone($timezoneLocal);
224-
$dateEnd->setTimezone($timezoneLocal);
217+
$dateStart->setTimezone(new \DateTimeZone($timezoneLocal));
218+
$dateEnd->setTimezone(new \DateTimeZone($timezoneLocal));
225219

226220
$dates = [];
227221
$datas = [];
228222

229-
while ($dateStart->compare($dateEnd) < 0) {
223+
while ($dateStart < $dateEnd) {
230224
switch ($this->getDataHelper()->getParam('period')) {
231225
case '7d':
232226
case '1m':
233-
$d = $dateStart->toString('yyyy-MM-dd');
234-
$dateStart->addDay(1);
227+
$d = $dateStart->format('Y-m-d');
228+
$dateStart->modify('+1 day');
235229
break;
236230
case '1y':
237231
case '2y':
238-
$d = $dateStart->toString('yyyy-MM');
239-
$dateStart->addMonth(1);
232+
$d = $dateStart->format('Y-m');
233+
$dateStart->modify('+1 month');
240234
break;
241235
default:
242-
$d = $dateStart->toString('yyyy-MM-dd HH:00');
243-
$dateStart->addHour(1);
236+
$d = $dateStart->format('Y-m-d H:00');
237+
$dateStart->modify('+1 hour');
244238
}
245239
foreach ($this->getAllSeries() as $index => $serie) {
246240
if (in_array($d, $this->_axisLabels['x'])) {
@@ -393,26 +387,22 @@ public function getChartUrl($directUrl = true)
393387
*/
394388
foreach ($this->_axisLabels[$idx] as $_index => $_label) {
395389
if ($_label != '') {
390+
$period = new \DateTime($_label);
396391
switch ($this->getDataHelper()->getParam('period')) {
397392
case '24h':
398-
$this->_axisLabels[$idx][$_index] = $this->formatTime(
399-
new \Magento\Framework\Stdlib\DateTime\Date($_label, 'yyyy-MM-dd HH:00'),
400-
'short',
401-
false
393+
$this->_axisLabels[$idx][$_index] = $this->_localeDate->formatDateTime(
394+
$period->setTime($period->format('H'), 0, 0),
395+
\IntlDateFormatter::NONE,
396+
\IntlDateFormatter::SHORT
402397
);
403398
break;
404399
case '7d':
405400
case '1m':
406-
$this->_axisLabels[$idx][$_index] = $this->formatDate(
407-
new \Magento\Framework\Stdlib\DateTime\Date($_label, 'yyyy-MM-dd')
408-
);
401+
$this->_axisLabels[$idx][$_index] = $this->_localeDate->formatDateTime($period);
409402
break;
410403
case '1y':
411404
case '2y':
412-
$formats = $this->_localeLists->getTranslationList('datetime');
413-
$format = isset($formats['yyMM']) ? $formats['yyMM'] : 'MM/yyyy';
414-
$format = str_replace(["yyyy", "yy", "MM"], ["Y", "y", "m"], $format);
415-
$this->_axisLabels[$idx][$_index] = date($format, strtotime($_label));
405+
$this->_axisLabels[$idx][$_index] = date('m/Y', strtotime($_label));
416406
break;
417407
}
418408
} else {

app/code/Magento/Backend/Block/Dashboard/Tab/Amounts.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,20 +17,18 @@ class Amounts extends \Magento\Backend\Block\Dashboard\Graph
1717
* @param \Magento\Backend\Block\Template\Context $context
1818
* @param \Magento\Reports\Model\Resource\Order\CollectionFactory $collectionFactory
1919
* @param \Magento\Backend\Helper\Dashboard\Data $dashboardData
20-
* @param \Magento\Framework\Locale\ListsInterface $localeLists
2120
* @param \Magento\Backend\Helper\Dashboard\Order $dataHelper
2221
* @param array $data
2322
*/
2423
public function __construct(
2524
\Magento\Backend\Block\Template\Context $context,
2625
\Magento\Reports\Model\Resource\Order\CollectionFactory $collectionFactory,
2726
\Magento\Backend\Helper\Dashboard\Data $dashboardData,
28-
\Magento\Framework\Locale\ListsInterface $localeLists,
2927
\Magento\Backend\Helper\Dashboard\Order $dataHelper,
3028
array $data = []
3129
) {
3230
$this->_dataHelper = $dataHelper;
33-
parent::__construct($context, $collectionFactory, $dashboardData, $localeLists, $data);
31+
parent::__construct($context, $collectionFactory, $dashboardData, $data);
3432
}
3533

3634
/**

app/code/Magento/Backend/Block/Dashboard/Tab/Orders.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,20 +17,18 @@ class Orders extends \Magento\Backend\Block\Dashboard\Graph
1717
* @param \Magento\Backend\Block\Template\Context $context
1818
* @param \Magento\Reports\Model\Resource\Order\CollectionFactory $collectionFactory
1919
* @param \Magento\Backend\Helper\Dashboard\Data $dashboardData
20-
* @param \Magento\Framework\Locale\ListsInterface $localeLists
2120
* @param \Magento\Backend\Helper\Dashboard\Order $dataHelper
2221
* @param array $data
2322
*/
2423
public function __construct(
2524
\Magento\Backend\Block\Template\Context $context,
2625
\Magento\Reports\Model\Resource\Order\CollectionFactory $collectionFactory,
2726
\Magento\Backend\Helper\Dashboard\Data $dashboardData,
28-
\Magento\Framework\Locale\ListsInterface $localeLists,
2927
\Magento\Backend\Helper\Dashboard\Order $dataHelper,
3028
array $data = []
3129
) {
3230
$this->_dataHelper = $dataHelper;
33-
parent::__construct($context, $collectionFactory, $dashboardData, $localeLists, $data);
31+
parent::__construct($context, $collectionFactory, $dashboardData, $data);
3432
}
3533

3634
/**

app/code/Magento/Backend/Block/Menu.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ public function getCacheKeyInfo()
286286
'admin_top_nav',
287287
$this->getActive(),
288288
$this->_authSession->getUser()->getId(),
289-
$this->_localeResolver->getLocaleCode(),
289+
$this->_localeResolver->getLocale(),
290290
];
291291
// Add additional key parameters if needed
292292
$newCacheKeyInfo = $this->getAdditionalCacheKeyInfo();

0 commit comments

Comments
 (0)