diff --git a/app/code/Magento/Checkout/view/frontend/onepage/review/button.phtml b/app/code/Magento/Checkout/view/frontend/onepage/review/button.phtml
index 1990699641007..91008edae7de1 100644
--- a/app/code/Magento/Checkout/view/frontend/onepage/review/button.phtml
+++ b/app/code/Magento/Checkout/view/frontend/onepage/review/button.phtml
@@ -22,4 +22,4 @@
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
*/
?>
-
+
diff --git a/app/code/Magento/Checkout/view/frontend/success.phtml b/app/code/Magento/Checkout/view/frontend/success.phtml
index 95681ab6f6e26..b13b4eeab3b85 100644
--- a/app/code/Magento/Checkout/view/frontend/success.phtml
+++ b/app/code/Magento/Checkout/view/frontend/success.phtml
@@ -23,36 +23,38 @@
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
*/
?>
-
-getOrderId()):?>
- getCanViewOrder()) :?>
-
%s', $this->escapeHtml($this->getViewOrderUrl()), $this->escapeHtml($this->getOrderId()))) ?>
-
-
escapeHtml($this->getOrderId())) ?>
+
+
+ getOrderId()):?>
+ getCanViewOrder()) :?>
+
%s', $this->escapeHtml($this->getViewOrderUrl()), $this->escapeHtml($this->getOrderId()))) ?>
+
+
escapeHtml($this->getOrderId())) ?>
+
+
+ getCanViewOrder() && $this->getCanPrintOrder()) :?>
+
+ here to print a copy of your order confirmation.', $this->getPrintUrl()) ?>
+ getChildHtml() ?>
+
+
-
- getCanViewOrder() && $this->getCanPrintOrder()) :?>
-
- here to print a copy of your order confirmation.', $this->getPrintUrl()) ?>
- getChildHtml() ?>
-
-
-
-getAgreementRefId()): ?>
-
%s', $this->escapeHtml($this->getAgreementUrl()), $this->escapeHtml($this->getAgreementRefId())))?>
-
+ getAgreementRefId()): ?>
+
%s', $this->escapeHtml($this->getAgreementUrl()), $this->escapeHtml($this->getAgreementRefId())))?>
+
-getRecurringProfiles()):?>
-
-
-
-getCanViewProfiles() ? sprintf('%s', $this->escapeHtml($this->getProfileUrl($profile)), $this->escapeHtml($this->getObjectData($profile, 'reference_id'))) : $this->escapeHtml($this->getObjectData($profile, 'reference_id')));?>
- - escapeHtml($this->getObjectData($profile, 'schedule_description')))?>
-
-
-
+ getRecurringProfiles()):?>
+
+
+
+ getCanViewProfiles() ? sprintf('%s', $this->escapeHtml($this->getProfileUrl($profile)), $this->escapeHtml($this->getObjectData($profile, 'reference_id'))) : $this->escapeHtml($this->getObjectData($profile, 'reference_id')));?>
+ - escapeHtml($this->getObjectData($profile, 'schedule_description')))?>
+
+
+
-
+
+
\ No newline at end of file
diff --git a/app/code/Magento/Cms/Block/Adminhtml/Block/Edit/Form.php b/app/code/Magento/Cms/Block/Adminhtml/Block/Edit/Form.php
index d946aa452c8f5..4a992a8e30c59 100644
--- a/app/code/Magento/Cms/Block/Adminhtml/Block/Edit/Form.php
+++ b/app/code/Magento/Cms/Block/Adminhtml/Block/Edit/Form.php
@@ -94,7 +94,7 @@ protected function _prepareForm()
/** @var \Magento\Data\Form $form */
$form = $this->_formFactory->create(array(
- 'attributes' => array(
+ 'data' => array(
'id' => 'edit_form',
'action' => $this->getData('action'),
'method' => 'post',
diff --git a/app/code/Magento/Cms/Block/Adminhtml/Page/Edit/Form.php b/app/code/Magento/Cms/Block/Adminhtml/Page/Edit/Form.php
index c12d78114687a..191d22ffcfaaa 100644
--- a/app/code/Magento/Cms/Block/Adminhtml/Page/Edit/Form.php
+++ b/app/code/Magento/Cms/Block/Adminhtml/Page/Edit/Form.php
@@ -41,7 +41,7 @@ protected function _prepareForm()
{
/** @var \Magento\Data\Form $form */
$form = $this->_formFactory->create(array(
- 'attributes' => array(
+ 'data' => array(
'id' => 'edit_form',
'action' => $this->getData('action'),
'method' => 'post',
diff --git a/app/code/Magento/Cms/Block/Adminhtml/Page/Edit/Tab/Design.php b/app/code/Magento/Cms/Block/Adminhtml/Page/Edit/Tab/Design.php
index fd7e6462f1f97..7af55766780c0 100644
--- a/app/code/Magento/Cms/Block/Adminhtml/Page/Edit/Tab/Design.php
+++ b/app/code/Magento/Cms/Block/Adminhtml/Page/Edit/Tab/Design.php
@@ -33,7 +33,7 @@ class Design
implements \Magento\Backend\Block\Widget\Tab\TabInterface
{
/**
- * @var \Magento\Core\Model\Theme\LabelFactory
+ * @var \Magento\View\Design\Theme\LabelFactory
*/
protected $_labelFactory;
@@ -47,7 +47,7 @@ class Design
* @param \Magento\Core\Model\Registry $registry
* @param \Magento\Data\FormFactory $formFactory
* @param \Magento\Theme\Model\Layout\Source\Layout $pageLayout
- * @param \Magento\Core\Model\Theme\LabelFactory $labelFactory
+ * @param \Magento\View\Design\Theme\LabelFactory $labelFactory
* @param array $data
*/
public function __construct(
@@ -55,7 +55,7 @@ public function __construct(
\Magento\Core\Model\Registry $registry,
\Magento\Data\FormFactory $formFactory,
\Magento\Theme\Model\Layout\Source\Layout $pageLayout,
- \Magento\Core\Model\Theme\LabelFactory $labelFactory,
+ \Magento\View\Design\Theme\LabelFactory $labelFactory,
array $data = array()
) {
$this->_labelFactory = $labelFactory;
@@ -86,7 +86,7 @@ protected function _prepareForm()
/** @var \Magento\Data\Form $form */
$form = $this->_formFactory->create(array(
- 'attributes' => array(
+ 'data' => array(
'html_id_prefix' => 'page_',
))
);
diff --git a/app/code/Magento/Connect/Block/Adminhtml/Extension/Custom/Edit/Form.php b/app/code/Magento/Connect/Block/Adminhtml/Extension/Custom/Edit/Form.php
index 3dc6b5bdbdb9a..f302d7aeef88c 100644
--- a/app/code/Magento/Connect/Block/Adminhtml/Extension/Custom/Edit/Form.php
+++ b/app/code/Magento/Connect/Block/Adminhtml/Extension/Custom/Edit/Form.php
@@ -44,7 +44,7 @@ protected function _prepareForm()
{
/** @var \Magento\Data\Form $form */
$form = $this->_formFactory->create(array(
- 'attributes' => array(
+ 'data' => array(
'id' => 'edit_form',
'action' => $this->getData('action'),
'method' => 'post',
diff --git a/app/code/Magento/Contacts/view/frontend/layout/contacts_index_index.xml b/app/code/Magento/Contacts/view/frontend/layout/contacts_index_index.xml
index 6f4471a3afab8..d910d951a3846 100644
--- a/app/code/Magento/Contacts/view/frontend/layout/contacts_index_index.xml
+++ b/app/code/Magento/Contacts/view/frontend/layout/contacts_index_index.xml
@@ -24,19 +24,12 @@
*/
-->
+
Contact Us
-
-
- 2columns-right.phtml
-
-
- Contact Us
-
-
diff --git a/app/code/Magento/Core/App/Action/Plugin/Design.php b/app/code/Magento/Core/App/Action/Plugin/Design.php
index 714c9c4c05f9e..8de0812655490 100644
--- a/app/code/Magento/Core/App/Action/Plugin/Design.php
+++ b/app/code/Magento/Core/App/Action/Plugin/Design.php
@@ -27,14 +27,14 @@
class Design
{
/**
- * @var \Magento\Core\Model\DesignLoader
+ * @var \Magento\View\DesignLoader
*/
protected $_designLoader;
/**
- * @param \Magento\Core\Model\DesignLoader $designLoader
+ * @param \Magento\View\DesignLoader $designLoader
*/
- public function __construct(\Magento\Core\Model\DesignLoader $designLoader)
+ public function __construct(\Magento\View\DesignLoader $designLoader)
{
$this->_designLoader = $designLoader;
}
diff --git a/app/code/Magento/Core/Helper/Url.php b/app/code/Magento/Core/Helper/Url.php
index b0f07d5f1b8f7..3a67e2039386d 100644
--- a/app/code/Magento/Core/Helper/Url.php
+++ b/app/code/Magento/Core/Helper/Url.php
@@ -130,9 +130,10 @@ public function addRequestParam($url, $param)
public function removeRequestParam($url, $paramKey, $caseSensitive = false)
{
$regExpression = '/\\?[^#]*?(' . preg_quote($paramKey, '/') . '\\=[^#&]*&?)/' . ($caseSensitive ? '' : 'i');
- while (preg_match($regExpression, $url, $matches) != 0) {
+ while (preg_match($regExpression, $url, $matches) !== 0) {
$paramString = $matches[1];
- if (preg_match('/&$/', $paramString) == 0) {
+ // if ampersand is at the end of $paramString
+ if (substr($paramString, -1, 1) != '&') {
$url = preg_replace('/(&|\\?)?' . preg_quote($paramString, '/') . '/', '', $url);
} else {
$url = str_replace($paramString, '', $url);
diff --git a/app/code/Magento/Core/Model/App.php b/app/code/Magento/Core/Model/App.php
index bb96568d46310..edf27a95d8efb 100644
--- a/app/code/Magento/Core/Model/App.php
+++ b/app/code/Magento/Core/Model/App.php
@@ -53,7 +53,7 @@ class App implements \Magento\Core\Model\AppInterface
/**
* Magento version
*/
- const VERSION = '2.0.0.0-dev55';
+ const VERSION = '2.0.0.0-dev56';
/**
@@ -801,7 +801,7 @@ public function getVersionInfo()
'revision' => '0',
'patch' => '0',
'stability' => 'dev',
- 'number' => '55',
+ 'number' => '56',
);
}
}
diff --git a/app/code/Magento/Core/Model/DataService/Config/Reader.php b/app/code/Magento/Core/Model/DataService/Config/Reader.php
index 71f1a287a6011..f714a3308d339 100644
--- a/app/code/Magento/Core/Model/DataService/Config/Reader.php
+++ b/app/code/Magento/Core/Model/DataService/Config/Reader.php
@@ -33,13 +33,11 @@ class Reader extends \Magento\Config\AbstractXml
private $_modulesReader;
/**
- * @param \Magento\Module\Dir\Reader $moduleReader
* @param array $configFiles
+ * @param \Magento\Module\Dir\Reader $moduleReader
*/
- public function __construct(
- \Magento\Module\Dir\Reader $moduleReader,
- array $configFiles
- ) {
+ public function __construct(array $configFiles, \Magento\Module\Dir\Reader $moduleReader)
+ {
if (count($configFiles)) {
parent::__construct($configFiles);
}
diff --git a/app/code/Magento/Core/Model/File/Uploader.php b/app/code/Magento/Core/Model/File/Uploader.php
index 7b70048ba12b7..22199b3253800 100644
--- a/app/code/Magento/Core/Model/File/Uploader.php
+++ b/app/code/Magento/Core/Model/File/Uploader.php
@@ -63,18 +63,16 @@ class Uploader extends \Magento\File\Uploader
protected $_validator;
/**
- * Init upload
- *
+ * @param string $fileId
* @param \Magento\Core\Helper\File\Storage\Database $coreFileStorageDb
* @param \Magento\Core\Helper\File\Storage $coreFileStorage
* @param \Magento\Core\Model\File\Validator\NotProtectedExtension $validator
- * @param $fileId
*/
public function __construct(
+ $fileId,
\Magento\Core\Helper\File\Storage\Database $coreFileStorageDb,
\Magento\Core\Helper\File\Storage $coreFileStorage,
- \Magento\Core\Model\File\Validator\NotProtectedExtension $validator,
- $fileId
+ \Magento\Core\Model\File\Validator\NotProtectedExtension $validator
) {
$this->_coreFileStorageDb = $coreFileStorageDb;
$this->_coreFileStorage = $coreFileStorage;
diff --git a/app/code/Magento/Core/Model/Layout.php b/app/code/Magento/Core/Model/Layout.php
index 5f06c0c3db669..dabdb6ffe58d5 100644
--- a/app/code/Magento/Core/Model/Layout.php
+++ b/app/code/Magento/Core/Model/Layout.php
@@ -917,7 +917,7 @@ public function getServiceCalls()
* @param array $options
* @throws \Magento\Exception if any of arguments are invalid
*/
- protected function _generateContainer($name, $label = '', array $options)
+ protected function _generateContainer($name, $label, array $options)
{
$this->_structure->setAttribute($name, Element::CONTAINER_OPT_LABEL, $label);
unset($options[Element::CONTAINER_OPT_LABEL]);
diff --git a/app/code/Magento/Core/Model/Layout/Argument/AbstractHandler.php b/app/code/Magento/Core/Model/Layout/Argument/AbstractHandler.php
index 2c72abf591a77..b5551fc61ab19 100644
--- a/app/code/Magento/Core/Model/Layout/Argument/AbstractHandler.php
+++ b/app/code/Magento/Core/Model/Layout/Argument/AbstractHandler.php
@@ -33,8 +33,7 @@
*/
namespace Magento\Core\Model\Layout\Argument;
-abstract class AbstractHandler
- implements \Magento\Core\Model\Layout\Argument\HandlerInterface
+abstract class AbstractHandler implements \Magento\View\Layout\Argument\HandlerInterface
{
/**
* @var \Magento\ObjectManager
diff --git a/app/code/Magento/Core/Model/Layout/Argument/Handler/ArrayHandler.php b/app/code/Magento/Core/Model/Layout/Argument/Handler/ArrayHandler.php
index 3927a804aed87..bc08284bf0505 100644
--- a/app/code/Magento/Core/Model/Layout/Argument/Handler/ArrayHandler.php
+++ b/app/code/Magento/Core/Model/Layout/Argument/Handler/ArrayHandler.php
@@ -36,15 +36,15 @@
class ArrayHandler extends \Magento\Core\Model\Layout\Argument\AbstractHandler
{
/**
- * @var \Magento\Core\Model\Layout\Argument\HandlerFactory
+ * @var \Magento\View\Layout\Argument\HandlerFactory
*/
protected $_handlerFactory;
/**
- * @param \Magento\Core\Model\Layout\Argument\HandlerFactory $handlerFactory
+ * @param \Magento\View\Layout\Argument\HandlerFactory $handlerFactory
*/
public function __construct(
- \Magento\Core\Model\Layout\Argument\HandlerFactory $handlerFactory
+ \Magento\View\Layout\Argument\HandlerFactory $handlerFactory
) {
$this->_handlerFactory = $handlerFactory;
}
diff --git a/app/code/Magento/Core/Model/Layout/Argument/HandlerFactoryInterface.php b/app/code/Magento/Core/Model/Layout/Argument/HandlerFactoryInterface.php
deleted file mode 100644
index 4a8ec64688470..0000000000000
--- a/app/code/Magento/Core/Model/Layout/Argument/HandlerFactoryInterface.php
+++ /dev/null
@@ -1,43 +0,0 @@
-
- */
-namespace Magento\Core\Model\Layout\Argument;
-
-interface HandlerFactoryInterface
-{
- /**
- * Create concrete handler object
- * @return \Magento\Core\Model\Layout\Argument\HandlerInterface
- */
- public function createHandler();
-}
diff --git a/app/code/Magento/Core/Model/Layout/Argument/Processor.php b/app/code/Magento/Core/Model/Layout/Argument/Processor.php
index b4389dd83d647..b44a9e0ecc673 100644
--- a/app/code/Magento/Core/Model/Layout/Argument/Processor.php
+++ b/app/code/Magento/Core/Model/Layout/Argument/Processor.php
@@ -36,7 +36,7 @@
class Processor
{
/**
- * @var \Magento\Core\Model\Layout\Argument\HandlerFactory
+ * @var \Magento\View\Layout\Argument\HandlerFactory
*/
protected $_handlerFactory;
@@ -54,11 +54,11 @@ class Processor
/**
* @param \Magento\Core\Model\Layout\Argument\Updater $argumentUpdater
- * @param \Magento\Core\Model\Layout\Argument\HandlerFactory $handlerFactory
+ * @param \Magento\View\Layout\Argument\HandlerFactory $handlerFactory
*/
public function __construct(
\Magento\Core\Model\Layout\Argument\Updater $argumentUpdater,
- \Magento\Core\Model\Layout\Argument\HandlerFactory $handlerFactory
+ \Magento\View\Layout\Argument\HandlerFactory $handlerFactory
) {
$this->_handlerFactory = $handlerFactory;
$this->_argumentUpdater = $argumentUpdater;
diff --git a/app/code/Magento/Core/Model/Layout/Merge.php b/app/code/Magento/Core/Model/Layout/Merge.php
index 3975d5a91f93d..f7c1d46684aaa 100644
--- a/app/code/Magento/Core/Model/Layout/Merge.php
+++ b/app/code/Magento/Core/Model/Layout/Merge.php
@@ -712,4 +712,26 @@ public function __destruct()
$this->_updates = array();
$this->_layoutUpdatesCache = null;
}
+
+ /**
+ * @inheritdoc
+ */
+ public function isCustomerDesignAbstraction(array $abstraction)
+ {
+ if (!isset($abstraction['design_abstraction'])) {
+ return false;
+ }
+ return $abstraction['design_abstraction'] === self::DESIGN_ABSTRACTION_CUSTOM;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function isPageLayoutDesignAbstraction(array $abstraction)
+ {
+ if (!isset($abstraction['design_abstraction'])) {
+ return false;
+ }
+ return $abstraction['design_abstraction'] === self::DESIGN_ABSTRACTION_PAGE_LAYOUT;
+ }
}
diff --git a/app/code/Magento/Core/Model/Locale/Hierarchy/Config/Reader.php b/app/code/Magento/Core/Model/Locale/Hierarchy/Config/Reader.php
index 998be57d93047..d2ebe44ec1e64 100644
--- a/app/code/Magento/Core/Model/Locale/Hierarchy/Config/Reader.php
+++ b/app/code/Magento/Core/Model/Locale/Hierarchy/Config/Reader.php
@@ -35,25 +35,34 @@ class Reader extends \Magento\Config\Reader\Filesystem
);
/**
- * @param \Magento\Core\Model\Locale\Hierarchy\Config\FileResolver $fileResolver
- * @param \Magento\Core\Model\Locale\Hierarchy\Config\Converter $converter
- * @param \Magento\Core\Model\Locale\Hierarchy\Config\SchemaLocator $schemeLocator
+ * @param FileResolver $fileResolver
+ * @param Converter $converter
+ * @param SchemaLocator $schemaLocator
* @param \Magento\Config\ValidationStateInterface $validationState
* @param string $fileName
* @param array $idAttributes
* @param string $domDocumentClass
+ * @param string $defaultScope
*/
public function __construct(
\Magento\Core\Model\Locale\Hierarchy\Config\FileResolver $fileResolver,
\Magento\Core\Model\Locale\Hierarchy\Config\Converter $converter,
- \Magento\Core\Model\Locale\Hierarchy\Config\SchemaLocator $schemeLocator,
+ \Magento\Core\Model\Locale\Hierarchy\Config\SchemaLocator $schemaLocator,
\Magento\Config\ValidationStateInterface $validationState,
$fileName = 'config.xml',
$idAttributes = array(),
- $domDocumentClass = 'Magento\Config\Dom'
+ $domDocumentClass = 'Magento\Config\Dom',
+ $defaultScope = 'global'
) {
parent::__construct(
- $fileResolver, $converter, $schemeLocator, $validationState, $fileName, $idAttributes, $domDocumentClass
+ $fileResolver,
+ $converter,
+ $schemaLocator,
+ $validationState,
+ $fileName,
+ $idAttributes,
+ $domDocumentClass,
+ $defaultScope
);
}
}
diff --git a/app/code/Magento/Core/Model/Resource/Theme/Collection.php b/app/code/Magento/Core/Model/Resource/Theme/Collection.php
index 4f2a3ace42c8d..05efca13a61d9 100644
--- a/app/code/Magento/Core/Model/Resource/Theme/Collection.php
+++ b/app/code/Magento/Core/Model/Resource/Theme/Collection.php
@@ -29,7 +29,9 @@
*/
namespace Magento\Core\Model\Resource\Theme;
-class Collection extends \Magento\Core\Model\Resource\Db\Collection\AbstractCollection
+class Collection
+ extends \Magento\Core\Model\Resource\Db\Collection\AbstractCollection
+ implements \Magento\View\Design\Theme\Label\ListInterface, \Magento\View\Design\Theme\ListInterface
{
/**
* Default page size
@@ -216,4 +218,16 @@ public function filterThemeCustomizations(
$this->addAreaFilter($area)->addTypeFilter($type);
return $this;
}
+
+ /**
+ * @inheritdoc
+ */
+ public function getLabels()
+ {
+ $this->_reset()->clear();
+ $labels = $this->setOrder('theme_title', \Magento\Data\Collection::SORT_ORDER_ASC)
+ ->filterVisibleThemes()
+ ->addAreaFilter(\Magento\Core\Model\App\Area::AREA_FRONTEND);
+ return $labels->toOptionArray();
+ }
}
diff --git a/app/code/Magento/Core/Model/Session.php b/app/code/Magento/Core/Model/Session.php
index 5ad6862ad6767..dc9c435b5a94a 100644
--- a/app/code/Magento/Core/Model/Session.php
+++ b/app/code/Magento/Core/Model/Session.php
@@ -41,15 +41,15 @@ class Session extends \Magento\Core\Model\Session\AbstractSession
* @param Session\Context $context
* @param \Magento\Session\SidResolverInterface $sidResolver
* @param \Magento\Session\Config\ConfigInterface $sessionConfig
- * @param array $data
* @param null $sessionName
+ * @param array $data
*/
public function __construct(
\Magento\Core\Model\Session\Context $context,
\Magento\Session\SidResolverInterface $sidResolver,
- \Magento\Session\Config\ConfigInterface $sessionConfig,
- array $data = array(),
- $sessionName = null
+ \Magento\Session\Config\ConfigInterface $sessionConfig,
+ $sessionName = null,
+ array $data = array()
) {
parent::__construct($context, $sidResolver, $sessionConfig, $data);
$this->start('core', $sessionName);
diff --git a/app/code/Magento/Core/Model/Session/Generic.php b/app/code/Magento/Core/Model/Session/Generic.php
index f0404480f59f0..60d367e361fd5 100644
--- a/app/code/Magento/Core/Model/Session/Generic.php
+++ b/app/code/Magento/Core/Model/Session/Generic.php
@@ -30,16 +30,16 @@ class Generic extends \Magento\Core\Model\Session\AbstractSession
* @param \Magento\Session\SidResolverInterface $sidResolver
* @param \Magento\Session\Config\ConfigInterface $sessionConfig
* @param string $sessionNamespace
+ * @param mixed $sessionName
* @param array $data
- * @param null $sessionName
*/
public function __construct(
\Magento\Core\Model\Session\Context $context,
\Magento\Session\SidResolverInterface $sidResolver,
\Magento\Session\Config\ConfigInterface $sessionConfig,
$sessionNamespace,
- array $data = array(),
- $sessionName = null
+ $sessionName = null,
+ array $data = array()
) {
parent::__construct($context, $sidResolver, $sessionConfig, $data);
$this->start($sessionNamespace, $sessionName);
diff --git a/app/code/Magento/Core/Model/Theme/Collection.php b/app/code/Magento/Core/Model/Theme/Collection.php
index d0b3f1b46b97d..6f5896b0470b7 100644
--- a/app/code/Magento/Core/Model/Theme/Collection.php
+++ b/app/code/Magento/Core/Model/Theme/Collection.php
@@ -29,7 +29,7 @@
*/
namespace Magento\Core\Model\Theme;
-class Collection extends \Magento\Data\Collection
+class Collection extends \Magento\Data\Collection implements \Magento\View\Design\Theme\ListInterface
{
/**
* @var \Magento\Filesystem
@@ -350,4 +350,19 @@ public function hasTheme(\Magento\View\Design\ThemeInterface $theme)
$themeItems = $this->getItems();
return $theme->getThemePath() && isset($themeItems[$theme->getFullPath()]);
}
+
+ /**
+ * Get theme from file system by area and theme_path
+ *
+ * @param string $fullPath
+ * @return \Magento\View\Design\ThemeInterface
+ */
+ public function getThemeByFullPath($fullPath)
+ {
+ list($area, $themePath) = explode('/', $fullPath, 2);
+ $this->addDefaultPattern($area)
+ ->addFilter('theme_path', $themePath);
+
+ return $this->getFirstItem();
+ }
}
diff --git a/app/code/Magento/Core/Model/Theme/Domain/Physical.php b/app/code/Magento/Core/Model/Theme/Domain/Physical.php
index 2a680d166eeb8..8255611b44377 100644
--- a/app/code/Magento/Core/Model/Theme/Domain/Physical.php
+++ b/app/code/Magento/Core/Model/Theme/Domain/Physical.php
@@ -44,7 +44,7 @@ class Physical implements \Magento\View\Design\Theme\Domain\PhysicalInterface
protected $_themeFactory;
/**
- * @var \Magento\Core\Model\Theme\CopyService
+ * @var \Magento\Theme\Model\CopyService
*/
protected $_themeCopyService;
@@ -56,13 +56,13 @@ class Physical implements \Magento\View\Design\Theme\Domain\PhysicalInterface
/**
* @param \Magento\View\Design\ThemeInterface $theme
* @param \Magento\Core\Model\ThemeFactory $themeFactory
- * @param \Magento\Core\Model\Theme\CopyService $themeCopyService
+ * @param \Magento\Theme\Model\CopyService $themeCopyService
* @param \Magento\Core\Model\Resource\Theme\Collection $themeCollection
*/
public function __construct(
\Magento\View\Design\ThemeInterface $theme,
\Magento\Core\Model\ThemeFactory $themeFactory,
- \Magento\Core\Model\Theme\CopyService $themeCopyService,
+ \Magento\Theme\Model\CopyService $themeCopyService,
\Magento\Core\Model\Resource\Theme\Collection $themeCollection
) {
$this->_theme = $theme;
diff --git a/app/code/Magento/Core/Model/Theme/Domain/Staging.php b/app/code/Magento/Core/Model/Theme/Domain/Staging.php
index 2d2a17582c727..09be9f75cc6b3 100644
--- a/app/code/Magento/Core/Model/Theme/Domain/Staging.php
+++ b/app/code/Magento/Core/Model/Theme/Domain/Staging.php
@@ -39,17 +39,17 @@ class Staging implements \Magento\View\Design\Theme\Domain\StagingInterface
protected $_theme;
/**
- * @var \Magento\Core\Model\Theme\CopyService
+ * @var \Magento\Theme\Model\CopyService
*/
protected $_themeCopyService;
/**
* @param \Magento\View\Design\ThemeInterface $theme
- * @param \Magento\Core\Model\Theme\CopyService $themeCopyService
+ * @param \Magento\Theme\Model\CopyService $themeCopyService
*/
public function __construct(
\Magento\View\Design\ThemeInterface $theme,
- \Magento\Core\Model\Theme\CopyService $themeCopyService
+ \Magento\Theme\Model\CopyService $themeCopyService
) {
$this->_theme = $theme;
$this->_themeCopyService = $themeCopyService;
diff --git a/app/code/Magento/Core/Model/Theme/Domain/Virtual.php b/app/code/Magento/Core/Model/Theme/Domain/Virtual.php
index f538989e18cea..0cd748f576eec 100644
--- a/app/code/Magento/Core/Model/Theme/Domain/Virtual.php
+++ b/app/code/Magento/Core/Model/Theme/Domain/Virtual.php
@@ -51,7 +51,7 @@ class Virtual implements \Magento\View\Design\Theme\Domain\VirtualInterface
protected $_stagingTheme;
/**
- * @var \Magento\Core\Model\Theme\CopyService
+ * @var \Magento\Theme\Model\CopyService
*/
protected $_themeCopyService;
@@ -65,13 +65,13 @@ class Virtual implements \Magento\View\Design\Theme\Domain\VirtualInterface
/**
* @param \Magento\View\Design\ThemeInterface $theme
* @param \Magento\Core\Model\ThemeFactory $themeFactory
- * @param \Magento\Core\Model\Theme\CopyService $themeCopyService
+ * @param \Magento\Theme\Model\CopyService $themeCopyService
* @param \Magento\Theme\Model\Config\Customization $customizationConfig
*/
public function __construct(
\Magento\View\Design\ThemeInterface $theme,
\Magento\Core\Model\ThemeFactory $themeFactory,
- \Magento\Core\Model\Theme\CopyService $themeCopyService,
+ \Magento\Theme\Model\CopyService $themeCopyService,
\Magento\Theme\Model\Config\Customization $customizationConfig
) {
$this->_theme = $theme;
diff --git a/app/code/Magento/Core/Model/Theme/Source/Theme.php b/app/code/Magento/Core/Model/Theme/Source/Theme.php
index 5a65bd8d86bec..9fb385ada9e35 100644
--- a/app/code/Magento/Core/Model/Theme/Source/Theme.php
+++ b/app/code/Magento/Core/Model/Theme/Source/Theme.php
@@ -29,7 +29,7 @@
*/
namespace Magento\Core\Model\Theme\Source;
-use Magento\Core\Model\Theme\Label;
+use Magento\View\Design\Theme\Label;
use Magento\Eav\Model\Entity\Attribute\Source\AbstractSource;
/**
@@ -40,12 +40,12 @@
class Theme extends AbstractSource
{
/**
- * @var Label
+ * @var \Magento\View\Design\Theme\Label
*/
protected $themeLabel;
/**
- * @param Label $themeLabel
+ * @param \Magento\View\Design\Theme\Label $themeLabel
*/
public function __construct(Label $themeLabel)
{
diff --git a/app/code/Magento/Core/Model/View/Design.php b/app/code/Magento/Core/Model/View/Design.php
index b35fc64bacf14..9079857446aac 100644
--- a/app/code/Magento/Core/Model/View/Design.php
+++ b/app/code/Magento/Core/Model/View/Design.php
@@ -31,25 +31,6 @@
class Design implements \Magento\View\DesignInterface
{
- /**
- * Common node path to theme design configuration
- */
- const XML_PATH_THEME_ID = 'design/theme/theme_id';
-
- /**
- * Regular expressions matches cache
- *
- * @var array
- */
- private static $_regexMatchCache = array();
-
- /**
- * Custom theme type cache
- *
- * @var array
- */
- private static $_customThemeTypeCache = array();
-
/**
* Package area
*
@@ -253,33 +234,6 @@ public function getDesignTheme()
return $this->_theme;
}
- /**
- * Return package name based on design exception rules
- *
- * @param array $rules - design exception rules
- * @param string $regexpsConfigPath
- * @return bool|string
- */
- public static function getPackageByUserAgent(array $rules, $regexpsConfigPath = 'path_mock')
- {
- foreach ($rules as $rule) {
- if (!empty(self::$_regexMatchCache[$rule['regexp']][$_SERVER['HTTP_USER_AGENT']])) {
- self::$_customThemeTypeCache[$regexpsConfigPath] = $rule['value'];
- return $rule['value'];
- }
-
- $regexp = '/' . trim($rule['regexp'], '/') . '/';
-
- if (@preg_match($regexp, $_SERVER['HTTP_USER_AGENT'])) {
- self::$_regexMatchCache[$rule['regexp']][$_SERVER['HTTP_USER_AGENT']] = true;
- self::$_customThemeTypeCache[$regexpsConfigPath] = $rule['value'];
- return $rule['value'];
- }
- }
-
- return false;
- }
-
/**
* {@inheritdoc}
*/
diff --git a/app/code/Magento/Core/etc/di.xml b/app/code/Magento/Core/etc/di.xml
index e7c79712c206b..992533f8b1c10 100644
--- a/app/code/Magento/Core/etc/di.xml
+++ b/app/code/Magento/Core/etc/di.xml
@@ -415,31 +415,31 @@
-
+
page_types.xml
-
+
-
+
frontend
-
+
-
+
page_types_config
-
+
-
+
diff --git a/app/design/frontend/magento_plushe/Magento_Core/template.phtml b/app/code/Magento/Core/view/frontend/template.phtml
similarity index 100%
rename from app/design/frontend/magento_plushe/Magento_Core/template.phtml
rename to app/code/Magento/Core/view/frontend/template.phtml
diff --git a/app/code/Magento/Cron/Model/Config/Reader/Xml.php b/app/code/Magento/Cron/Model/Config/Reader/Xml.php
index 31e062270e811..5901d9fc5d412 100644
--- a/app/code/Magento/Cron/Model/Config/Reader/Xml.php
+++ b/app/code/Magento/Cron/Model/Config/Reader/Xml.php
@@ -41,15 +41,14 @@ class Xml extends \Magento\Config\Reader\Filesystem
);
/**
- * Initialize parameters
- *
- * @param \Magento\Config\FileResolverInterface $fileResolver
+ * @param \Magento\Config\FileResolverInterface $fileResolver
* @param \Magento\Cron\Model\Config\Converter\Xml $converter
* @param \Magento\Cron\Model\Config\SchemaLocator $schemaLocator
* @param \Magento\Config\ValidationStateInterface $validationState
- * @param string $fileName
- * @param array $idAttributes
- * @param string $domDocumentClass
+ * @param string $fileName
+ * @param array $idAttributes
+ * @param string $domDocumentClass
+ * @param string $defaultScope
*/
public function __construct(
\Magento\Config\FileResolverInterface $fileResolver,
@@ -58,10 +57,18 @@ public function __construct(
\Magento\Config\ValidationStateInterface $validationState,
$fileName = 'crontab.xml',
$idAttributes = array(),
- $domDocumentClass = 'Magento\Config\Dom'
+ $domDocumentClass = 'Magento\Config\Dom',
+ $defaultScope = 'global'
) {
parent::__construct(
- $fileResolver, $converter, $schemaLocator, $validationState, $fileName, $idAttributes, $domDocumentClass
+ $fileResolver,
+ $converter,
+ $schemaLocator,
+ $validationState,
+ $fileName,
+ $idAttributes,
+ $domDocumentClass,
+ $defaultScope
);
}
}
diff --git a/app/code/Magento/Customer/Block/Adminhtml/Edit/Form.php b/app/code/Magento/Customer/Block/Adminhtml/Edit/Form.php
index 0b41cfa26b474..1b0b096ddd169 100644
--- a/app/code/Magento/Customer/Block/Adminhtml/Edit/Form.php
+++ b/app/code/Magento/Customer/Block/Adminhtml/Edit/Form.php
@@ -35,7 +35,7 @@ protected function _prepareForm()
{
/** @var \Magento\Data\Form $form */
$form = $this->_formFactory->create(array(
- 'attributes' => array(
+ 'data' => array(
'id' => 'edit_form',
'action' => $this->getUrl('customer/*/save'),
'method' => 'post',
diff --git a/app/code/Magento/Customer/Block/Adminhtml/Form/Element/File.php b/app/code/Magento/Customer/Block/Adminhtml/Form/Element/File.php
index 4ffb6c7c98945..1aee33aa2fc90 100644
--- a/app/code/Magento/Customer/Block/Adminhtml/Form/Element/File.php
+++ b/app/code/Magento/Customer/Block/Adminhtml/Form/Element/File.php
@@ -49,24 +49,24 @@ class File extends \Magento\Data\Form\Element\AbstractElement
protected $_adminhtmlData = null;
/**
- * @param \Magento\Escaper $escaper
* @param \Magento\Data\Form\Element\Factory $factoryElement
* @param \Magento\Data\Form\Element\CollectionFactory $factoryCollection
+ * @param \Magento\Escaper $escaper
* @param \Magento\Backend\Helper\Data $adminhtmlData
* @param \Magento\View\Url $viewUrl
- * @param array $attributes
+ * @param array $data
*/
- public function __construct(
- \Magento\Escaper $escaper,
+ public function __construct(
\Magento\Data\Form\Element\Factory $factoryElement,
\Magento\Data\Form\Element\CollectionFactory $factoryCollection,
+ \Magento\Escaper $escaper,
\Magento\Backend\Helper\Data $adminhtmlData,
\Magento\View\Url $viewUrl,
- $attributes = array()
+ $data = array()
) {
$this->_adminhtmlData = $adminhtmlData;
$this->_viewUrl = $viewUrl;
- parent::__construct($escaper, $factoryElement, $factoryCollection, $attributes);
+ parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
$this->setType('file');
}
diff --git a/app/code/Magento/Customer/Model/Session.php b/app/code/Magento/Customer/Model/Session.php
index d10c2400f54c8..467ef6584f8c2 100644
--- a/app/code/Magento/Customer/Model/Session.php
+++ b/app/code/Magento/Customer/Model/Session.php
@@ -88,15 +88,15 @@ class Session extends \Magento\Core\Model\Session\AbstractSession
* @param \Magento\Core\Model\Session\Context $context
* @param \Magento\Session\SidResolverInterface $sidResolver
* @param \Magento\Session\Config\ConfigInterface $sessionConfig
- * @param \Magento\Customer\Model\Config\Share $configShare
+ * @param Config\Share $configShare
* @param \Magento\Core\Helper\Url $coreUrl
* @param \Magento\Customer\Helper\Data $customerData
- * @param \Magento\Customer\Model\Resource\Customer $customerResource
- * @param \Magento\Customer\Model\CustomerFactory $customerFactory
+ * @param Resource\Customer $customerResource
+ * @param CustomerFactory $customerFactory
* @param \Magento\Core\Model\UrlFactory $urlFactory
* @param \Magento\Core\Model\Session $session
- * @param array $data
* @param null $sessionName
+ * @param array $data
*/
public function __construct(
\Magento\Core\Model\Session\Context $context,
@@ -109,8 +109,8 @@ public function __construct(
\Magento\Customer\Model\CustomerFactory $customerFactory,
\Magento\Core\Model\UrlFactory $urlFactory,
\Magento\Core\Model\Session $session,
- array $data = array(),
- $sessionName = null
+ $sessionName = null,
+ array $data = array()
) {
$this->_coreUrl = $coreUrl;
$this->_customerData = $customerData;
diff --git a/app/design/frontend/magento_plushe/Magento_Customer/account/customer.phtml b/app/code/Magento/Customer/view/frontend/account/customer.phtml
similarity index 95%
rename from app/design/frontend/magento_plushe/Magento_Customer/account/customer.phtml
rename to app/code/Magento/Customer/view/frontend/account/customer.phtml
index f158025e4468a..3c867adcf236b 100644
--- a/app/design/frontend/magento_plushe/Magento_Customer/account/customer.phtml
+++ b/app/code/Magento/Customer/view/frontend/account/customer.phtml
@@ -29,9 +29,9 @@
getCustomerName(); ?>
getChildHtml()):?>
-