Skip to content

Commit 76d3d79

Browse files
author
Joan He
committed
Merge pull request #97 from magento-extensibility/develop
[Extensibility] Sprint 45 CE
2 parents 3941c63 + b11a447 commit 76d3d79

File tree

224 files changed

+2054
-2298
lines changed

Some content is hidden

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

224 files changed

+2054
-2298
lines changed

app/code/Magento/AdminNotification/Model/System/Message/Baseurl.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88

99
namespace Magento\AdminNotification\Model\System\Message;
1010

11+
use Magento\Store\Model\Store;
12+
1113
class Baseurl implements \Magento\Framework\Notification\MessageInterface
1214
{
1315
/**
@@ -56,9 +58,9 @@ public function __construct(
5658
protected function _getConfigUrl()
5759
{
5860
$output = '';
59-
$defaultUnsecure = $this->_config->getValue(\Magento\Store\Model\Store::XML_PATH_UNSECURE_BASE_URL, 'default');
61+
$defaultUnsecure = $this->_config->getValue(Store::XML_PATH_UNSECURE_BASE_URL, 'default');
6062

61-
$defaultSecure = $this->_config->getValue(\Magento\Store\Model\Store::XML_PATH_SECURE_BASE_URL, 'default');
63+
$defaultSecure = $this->_config->getValue(Store::XML_PATH_SECURE_BASE_URL, 'default');
6264

6365
if ($defaultSecure == \Magento\Store\Model\Store::BASE_URL_PLACEHOLDER ||
6466
$defaultUnsecure == \Magento\Store\Model\Store::BASE_URL_PLACEHOLDER

app/code/Magento/AdminNotification/Model/System/Message/Security.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88

99
namespace Magento\AdminNotification\Model\System\Message;
1010

11+
use Magento\Store\Model\Store;
12+
1113
class Security implements \Magento\Framework\Notification\MessageInterface
1214
{
1315
/**
@@ -93,7 +95,7 @@ private function _canShowNotification()
9395
*/
9496
private function _isFileAccessible()
9597
{
96-
$unsecureBaseURL = $this->_config->getValue(\Magento\Store\Model\Store::XML_PATH_UNSECURE_BASE_URL, 'default');
98+
$unsecureBaseURL = $this->_config->getValue(Store::XML_PATH_UNSECURE_BASE_URL, 'default');
9799

98100
/** @var $http \Magento\Framework\HTTP\Adapter\Curl */
99101
$http = $this->_curlFactory->create();

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ abstract class AbstractAction extends \Magento\Framework\App\Action\Action
7272
protected $_canUseBaseUrl;
7373

7474
/**
75-
* @var \Magento\Core\App\Action\FormKeyValidator
75+
* @var \Magento\Framework\Data\Form\FormKey\Validator
7676
*/
7777
protected $_formKeyValidator;
7878

app/code/Magento/Backend/App/Action/Context.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class Context extends \Magento\Framework\App\Action\Context
3232
protected $_backendUrl;
3333

3434
/**
35-
* @var \Magento\Core\App\Action\FormKeyValidator
35+
* @var \Magento\Framework\Data\Form\FormKey\Validator
3636
*/
3737
protected $_formKeyValidator;
3838

@@ -66,7 +66,7 @@ class Context extends \Magento\Framework\App\Action\Context
6666
* @param \Magento\Backend\Model\Auth $auth
6767
* @param \Magento\Backend\Helper\Data $helper
6868
* @param \Magento\Backend\Model\UrlInterface $backendUrl
69-
* @param \Magento\Core\App\Action\FormKeyValidator $formKeyValidator
69+
* @param \Magento\Framework\Data\Form\FormKey\Validator $formKeyValidator
7070
* @param \Magento\Framework\Locale\ResolverInterface $localeResolver
7171
* @param bool $canUseBaseUrl
7272
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
@@ -86,7 +86,7 @@ public function __construct(
8686
\Magento\Backend\Model\Auth $auth,
8787
\Magento\Backend\Helper\Data $helper,
8888
\Magento\Backend\Model\UrlInterface $backendUrl,
89-
\Magento\Core\App\Action\FormKeyValidator $formKeyValidator,
89+
\Magento\Framework\Data\Form\FormKey\Validator $formKeyValidator,
9090
\Magento\Framework\Locale\ResolverInterface $localeResolver,
9191
$canUseBaseUrl = false
9292
) {
@@ -146,7 +146,7 @@ public function getCanUseBaseUrl()
146146
}
147147

148148
/**
149-
* @return \Magento\Core\App\Action\FormKeyValidator
149+
* @return \Magento\Framework\Data\Form\FormKey\Validator
150150
*/
151151
public function getFormKeyValidator()
152152
{

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

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99
namespace Magento\Backend\App;
1010

11-
class Router extends \Magento\Core\App\Router\Base
11+
class Router extends \Magento\Framework\App\Router\Base
1212
{
1313
/**
1414
* @var \Magento\Backend\App\ConfigInterface
@@ -53,11 +53,9 @@ class Router extends \Magento\Core\App\Router\Base
5353
* @param \Magento\Framework\App\ResponseFactory $responseFactory
5454
* @param \Magento\Framework\App\Route\ConfigInterface $routeConfig
5555
* @param \Magento\Framework\UrlInterface $url
56-
* @param \Magento\Store\Model\StoreManagerInterface $storeManager
57-
* @param \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig
58-
* @param \Magento\Framework\Url\SecurityInfoInterface $urlSecurityInfo
5956
* @param string $routerId
6057
* @param \Magento\Framework\Code\NameBuilder $nameBuilder
58+
* @param \Magento\Framework\App\Router\PathConfigInterface $pathConfig
6159
* @param \Magento\Framework\App\Config\ScopeConfigInterface $coreConfig
6260
* @param \Magento\Backend\App\ConfigInterface $backendConfig
6361
*
@@ -70,11 +68,9 @@ public function __construct(
7068
\Magento\Framework\App\ResponseFactory $responseFactory,
7169
\Magento\Framework\App\Route\ConfigInterface $routeConfig,
7270
\Magento\Framework\UrlInterface $url,
73-
\Magento\Store\Model\StoreManagerInterface $storeManager,
74-
\Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig,
75-
\Magento\Framework\Url\SecurityInfoInterface $urlSecurityInfo,
7671
$routerId,
7772
\Magento\Framework\Code\NameBuilder $nameBuilder,
73+
\Magento\Framework\App\Router\PathConfigInterface $pathConfig,
7874
\Magento\Framework\App\Config\ScopeConfigInterface $coreConfig,
7975
\Magento\Backend\App\ConfigInterface $backendConfig
8076
) {
@@ -85,11 +81,9 @@ public function __construct(
8581
$responseFactory,
8682
$routeConfig,
8783
$url,
88-
$storeManager,
89-
$scopeConfig,
90-
$urlSecurityInfo,
9184
$routerId,
92-
$nameBuilder
85+
$nameBuilder,
86+
$pathConfig
9387
);
9488
$this->_coreConfig = $coreConfig;
9589
$this->_backendConfig = $backendConfig;

app/code/Magento/Backend/Block/System/Cache/Form.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,25 +13,25 @@
1313
class Form extends \Magento\Backend\Block\Widget\Form\Generic
1414
{
1515
/**
16-
* @var \Magento\Core\Helper\Data
16+
* @var \Magento\Framework\App\Cache\TypeListInterface
1717
*/
18-
protected $_coreData;
18+
protected $cacheTypeList;
1919

2020
/**
2121
* @param \Magento\Backend\Block\Template\Context $context
2222
* @param \Magento\Framework\Registry $registry
2323
* @param \Magento\Framework\Data\FormFactory $formFactory
24-
* @param \Magento\Core\Helper\Data $coreData
24+
* @param \Magento\Framework\App\Cache\TypeListInterface $cacheTypeList
2525
* @param array $data
2626
*/
2727
public function __construct(
2828
\Magento\Backend\Block\Template\Context $context,
2929
\Magento\Framework\Registry $registry,
3030
\Magento\Framework\Data\FormFactory $formFactory,
31-
\Magento\Core\Helper\Data $coreData,
31+
\Magento\Framework\App\Cache\TypeListInterface $cacheTypeList,
3232
array $data = []
3333
) {
34-
$this->_coreData = $coreData;
34+
$this->cacheTypeList = $cacheTypeList;
3535
parent::__construct($context, $registry, $formFactory, $data);
3636
}
3737

@@ -63,7 +63,7 @@ public function initForm()
6363
]
6464
);
6565

66-
foreach ($this->_coreData->getCacheTypes() as $type => $label) {
66+
foreach ($this->cacheTypeList->getTypeLabels() as $type => $label) {
6767
$fieldset->addField(
6868
'enable_' . $type,
6969
'checkbox',

app/code/Magento/Backend/Helper/Dashboard/AbstractDashboard.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,10 @@
55
*/
66
namespace Magento\Backend\Helper\Dashboard;
77

8-
use Magento\Core\Helper\Data as HelperData;
9-
108
/**
119
* Adminhtml abstract dashboard helper.
1210
*/
13-
abstract class AbstractDashboard extends HelperData
11+
abstract class AbstractDashboard extends \Magento\Framework\App\Helper\AbstractHelper
1412
{
1513
/**
1614
* Helper collection

app/code/Magento/Backend/Helper/Dashboard/Data.php

Lines changed: 9 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/**
1111
* Data helper for dashboard
1212
*/
13-
class Data extends \Magento\Core\Helper\Data
13+
class Data extends \Magento\Framework\App\Helper\AbstractHelper
1414
{
1515
/**
1616
* @var \Magento\Framework\Data\Collection\Db
@@ -27,33 +27,26 @@ class Data extends \Magento\Core\Helper\Data
2727
*/
2828
const INSTALL_DATE = 'install/date';
2929

30+
/**
31+
* @var \Magento\Store\Model\StoreManagerInterface
32+
*/
33+
private $_storeManager;
34+
3035
/**
3136
* @param \Magento\Framework\App\Helper\Context $context
32-
* @param \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig
3337
* @param \Magento\Store\Model\StoreManagerInterface $storeManager
34-
* @param \Magento\Framework\App\State $appState
35-
* @param \Magento\Framework\Pricing\PriceCurrencyInterface $priceCurrency
3638
* @param DeploymentConfig $deploymentConfig
37-
* @param bool $dbCompatibleMode
3839
*/
3940
public function __construct(
4041
\Magento\Framework\App\Helper\Context $context,
41-
\Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig,
4242
\Magento\Store\Model\StoreManagerInterface $storeManager,
43-
\Magento\Framework\App\State $appState,
44-
\Magento\Framework\Pricing\PriceCurrencyInterface $priceCurrency,
45-
DeploymentConfig $deploymentConfig,
46-
$dbCompatibleMode = true
43+
DeploymentConfig $deploymentConfig
4744
) {
4845
parent::__construct(
49-
$context,
50-
$scopeConfig,
51-
$storeManager,
52-
$appState,
53-
$priceCurrency,
54-
$dbCompatibleMode
46+
$context
5547
);
5648
$this->_installDate = $deploymentConfig->get(self::INSTALL_DATE);
49+
$this->_storeManager = $storeManager;
5750
}
5851

5952
/**

app/code/Magento/Backend/Helper/Dashboard/Order.php

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -17,30 +17,15 @@ class Order extends \Magento\Backend\Helper\Dashboard\AbstractDashboard
1717

1818
/**
1919
* @param \Magento\Framework\App\Helper\Context $context
20-
* @param \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig
21-
* @param \Magento\Store\Model\StoreManagerInterface $storeManager
22-
* @param \Magento\Framework\App\State $appState
23-
* @param \Magento\Framework\Pricing\PriceCurrencyInterface $priceCurrency
2420
* @param \Magento\Reports\Model\Resource\Order\Collection $orderCollection
25-
* @param bool $dbCompatibleMode
2621
*/
2722
public function __construct(
2823
\Magento\Framework\App\Helper\Context $context,
29-
\Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig,
30-
\Magento\Store\Model\StoreManagerInterface $storeManager,
31-
\Magento\Framework\App\State $appState,
32-
\Magento\Framework\Pricing\PriceCurrencyInterface $priceCurrency,
33-
\Magento\Reports\Model\Resource\Order\Collection $orderCollection,
34-
$dbCompatibleMode = true
24+
\Magento\Reports\Model\Resource\Order\Collection $orderCollection
3525
) {
3626
$this->_orderCollection = $orderCollection;
3727
parent::__construct(
38-
$context,
39-
$scopeConfig,
40-
$storeManager,
41-
$appState,
42-
$priceCurrency,
43-
$dbCompatibleMode
28+
$context
4429
);
4530
}
4631

app/code/Magento/Backend/Model/Translate/Inline/Config.php

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,36 +13,38 @@ class Config implements \Magento\Framework\Translate\Inline\ConfigInterface
1313
/**
1414
* @var \Magento\Backend\App\ConfigInterface
1515
*/
16-
protected $_config;
16+
protected $config;
1717

1818
/**
19-
* @var \Magento\Core\Helper\Data
19+
* @var \Magento\Developer\Helper\Data
2020
*/
21-
protected $_helper;
21+
protected $devHelper;
2222

2323
/**
2424
* @param \Magento\Backend\App\ConfigInterface $config
25-
* @param \Magento\Core\Helper\Data $helper
25+
* @param \Magento\Developer\Helper\Data $devHelper
2626
*/
27-
public function __construct(\Magento\Backend\App\ConfigInterface $config, \Magento\Core\Helper\Data $helper)
28-
{
29-
$this->_config = $config;
30-
$this->_helper = $helper;
27+
public function __construct(
28+
\Magento\Backend\App\ConfigInterface $config,
29+
\Magento\Developer\Helper\Data $devHelper
30+
) {
31+
$this->config = $config;
32+
$this->devHelper = $devHelper;
3133
}
3234

3335
/**
3436
* {@inheritdoc}
3537
*/
3638
public function isActive($scope = null)
3739
{
38-
return $this->_config->isSetFlag('dev/translate_inline/active_admin');
40+
return $this->config->isSetFlag('dev/translate_inline/active_admin');
3941
}
4042

4143
/**
4244
* {@inheritdoc}
4345
*/
4446
public function isDevAllowed($scope = null)
4547
{
46-
return $this->_helper->isDevAllowed($scope);
48+
return $this->devHelper->isDevAllowed($scope);
4749
}
4850
}

app/code/Magento/Backend/composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
"magento/module-store": "0.42.0-beta8",
77
"magento/module-directory": "0.42.0-beta8",
88
"magento/module-core": "0.42.0-beta8",
9+
"magento/module-developer": "0.42.0-beta8",
910
"magento/module-eav": "0.42.0-beta8",
1011
"magento/module-cron": "0.42.0-beta8",
1112
"magento/module-theme": "0.42.0-beta8",

app/code/Magento/Bundle/Block/Catalog/Product/View/Type/Bundle/Option.php

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@
88

99
namespace Magento\Bundle\Block\Catalog\Product\View\Type\Bundle;
1010

11-
use Magento\Bundle\Model\Product\Price;
12-
1311
/**
1412
* Bundle option renderer
1513
*/
@@ -30,9 +28,9 @@ class Option extends \Magento\Bundle\Block\Catalog\Product\Price
3028
protected $_showSingle;
3129

3230
/**
33-
* @var \Magento\Core\Helper\Data
31+
* @var \Magento\Framework\Pricing\Helper\Data
3432
*/
35-
protected $_coreHelper;
33+
protected $pricingHelper;
3634

3735
/**
3836
* @var \Magento\Tax\Helper\Data
@@ -53,7 +51,7 @@ class Option extends \Magento\Bundle\Block\Catalog\Product\Price
5351
* @param \Magento\Framework\Math\Random $mathRandom
5452
* @param \Magento\Checkout\Helper\Cart $cartHelper
5553
* @param \Magento\Tax\Helper\Data $taxData
56-
* @param \Magento\Core\Helper\Data $coreHelper
54+
* @param \Magento\Framework\Pricing\Helper\Data $pricingHelper
5755
* @param array $data
5856
*
5957
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
@@ -67,10 +65,10 @@ public function __construct(
6765
\Magento\Framework\Math\Random $mathRandom,
6866
\Magento\Checkout\Helper\Cart $cartHelper,
6967
\Magento\Tax\Helper\Data $taxData,
70-
\Magento\Core\Helper\Data $coreHelper,
68+
\Magento\Framework\Pricing\Helper\Data $pricingHelper,
7169
array $data = []
7270
) {
73-
$this->_coreHelper = $coreHelper;
71+
$this->pricingHelper = $pricingHelper;
7472
$this->_catalogHelper = $catalogData;
7573
$this->_taxHelper = $taxData;
7674
parent::__construct(
@@ -248,7 +246,7 @@ public function getSelectionPrice($selection)
248246
1
249247
);
250248
if (is_numeric($price)) {
251-
$price = $this->_coreHelper->currencyByStore($price, $store, false);
249+
$price = $this->pricingHelper->currencyByStore($price, $store, false);
252250
}
253251
}
254252
return is_numeric($price) ? $price : 0;

0 commit comments

Comments
 (0)