Skip to content

Commit

Permalink
Merge branch '2.3-develop' into feature/271-Customer-Attributes-Valid…
Browse files Browse the repository at this point in the history
…ation
  • Loading branch information
furseyev committed Jul 9, 2019
2 parents 1c30336 + adb5dff commit 4382c3a
Show file tree
Hide file tree
Showing 327 changed files with 48,386 additions and 12,022 deletions.
3 changes: 2 additions & 1 deletion app/code/Magento/AdminNotification/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"magento/module-backend": "*",
"magento/module-media-storage": "*",
"magento/module-store": "*",
"magento/module-ui": "*"
"magento/module-ui": "*",
"magento/module-config": "*"
},
"type": "magento2-module",
"license": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@
"successText": "<?= $block->escapeHtmlAttr(__('Successful! Test again?')) ?>",
"failedText": "<?= $block->escapeHtmlAttr(__('Connection failed! Test again?')) ?>",
"fieldMapping": "<?= /* @noEscape */ $block->getFieldMapping() ?>"}, "validation": {}}'>
<span><span><span id="<?= $block->getHtmlId() ?>_result"><?= $block->escapeHtml($block->getButtonLabel()) ?></span></span></span>
<span id="<?= $block->getHtmlId() ?>_result"><?= $block->escapeHtml($block->getButtonLabel()) ?></span>
</button>
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
<element name="advancedReportingIndustry" type="select" selector="#analytics_general_vertical"/>
<element name="advancedReportingIndustryLabel" type="text" selector=".config-vertical-label>label>span"/>
<element name="advancedReportingHour" type="select" selector="#row_analytics_general_collection_time>td:nth-child(2)>select:nth-child(2)"/>
<element name="advancedReportingMinute" type="select" selector="#row_analytics_general_collection_time>td:nth-child(2)>select:nth-child(3)"/>
<element name="advancedReportingSeconds" type="select" selector="#row_analytics_general_collection_time>td:nth-child(2)>select:nth-child(4)"/>
<element name="advancedReportingMinute" type="select" selector="#row_analytics_general_collection_time>td:nth-child(2)>select:nth-child(4)"/>
<element name="advancedReportingSeconds" type="select" selector="#row_analytics_general_collection_time>td:nth-child(2)>select:nth-child(6)"/>
<element name="advancedReportingBlankIndustryError" type="text" selector=".message-error>div"/>
</section>
</sections>
10 changes: 9 additions & 1 deletion app/code/Magento/Backend/Block/Dashboard/Bar.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
*/
namespace Magento\Backend\Block\Dashboard;

use Magento\Store\Model\Store;

/**
* Adminhtml dashboard bar block
*
Expand All @@ -23,6 +25,8 @@ class Bar extends \Magento\Backend\Block\Dashboard\AbstractDashboard
protected $_currentCurrencyCode = null;

/**
* Get totals
*
* @return array
*/
public function getTotals()
Expand All @@ -31,6 +35,8 @@ public function getTotals()
}

/**
* Add total
*
* @param string $label
* @param float $value
* @param bool $isQuantity
Expand Down Expand Up @@ -73,6 +79,7 @@ public function setCurrency($currency)
* Retrieve currency model if not set then return currency model for current store
*
* @return \Magento\Directory\Model\Currency
* @SuppressWarnings(PHPMD.RequestAwareBlockMethod)
*/
public function getCurrency()
{
Expand All @@ -90,7 +97,8 @@ public function getCurrency()
$this->getRequest()->getParam('group')
)->getWebsite()->getBaseCurrency();
} else {
$this->_currentCurrencyCode = $this->_storeManager->getStore()->getBaseCurrency();
$this->_currentCurrencyCode = $this->_storeManager->getStore(Store::DEFAULT_STORE_ID)
->getBaseCurrency();
}
}

Expand Down
11 changes: 2 additions & 9 deletions app/code/Magento/Backend/Block/Widget/Grid/Column/Multistore.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
declare(strict_types=1);

namespace Magento\Backend\Block\Widget\Grid\Column;

/**
Expand All @@ -14,15 +16,6 @@
*/
class Multistore extends \Magento\Backend\Block\Widget\Grid\Column
{
/**
* @param \Magento\Backend\Block\Template\Context $context
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Template\Context $context, array $data = [])
{
parent::__construct($context, $data);
}

/**
* Get header css class name
*
Expand Down
23 changes: 23 additions & 0 deletions app/code/Magento/Backend/Test/Mftf/Data/CookieConfigData.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd">
<entity name="ChangedCookieDomainForMainWebsiteConfigData">
<data key="path">web/cookie/cookie_domain</data>
<data key="scope">website</data>
<data key="scope_code">base</data>
<data key="value">testDomain.com</data>
</entity>
<entity name="EmptyCookieDomainForMainWebsiteConfigData">
<data key="path">web/cookie/cookie_domain</data>
<data key="scope">website</data>
<data key="scope_code">base</data>
<data key="value">''</data>
</entity>
</entities>
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,9 @@
<!-- Create invoice -->
<comment userInput="Create invoice" stepKey="createInvoice"/>
<click selector="{{AdminOrdersGridSection.firstRow}}" stepKey="clickOrderRow"/>
<waitForPageLoad stepKey="waitForOrderPageToLoad"/>
<click selector="{{AdminOrderDetailsMainActionsSection.invoice}}" stepKey="clickInvoiceButton"/>
<waitForPageLoad stepKey="waitForInvoicePageToLoad"/>
<see selector="{{AdminHeaderSection.pageTitle}}" userInput="New Invoice" stepKey="seeNewInvoiceInPageTitle" after="clickInvoiceButton"/>
<see selector="{{AdminInvoiceTotalSection.total('Subtotal')}}" userInput="$150.00" stepKey="seeCorrectGrandTotal"/>
<click selector="{{AdminInvoiceMainActionsSection.submitInvoice}}" stepKey="clickSubmitInvoice"/>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
<test name="AdminLoginAfterChangeCookieDomainTest">
<annotations>
<features value="Backend"/>
<stories value="Login on the Admin Backend"/>
<title value="Admin user can login after changing cookie domain on main website scope without changing cookie domain on default scope"/>
<description value="Admin user can login after changing cookie domain on main website scope without changing cookie domain on default scope"/>
<severity value="CRITICAL"/>
<testCaseId value="MC-17847"/>
<useCaseId value="MC-17275"/>
<group value="backend"/>
</annotations>
<before>
<magentoCLI command="config:set {{ChangedCookieDomainForMainWebsiteConfigData.path}} --scope={{ChangedCookieDomainForMainWebsiteConfigData.scope}} --scope-code={{ChangedCookieDomainForMainWebsiteConfigData.scope_code}} {{ChangedCookieDomainForMainWebsiteConfigData.value}}" stepKey="changeDomainForMainWebsiteBeforeTestRun"/>
<magentoCLI command="cache:flush config" stepKey="flushCacheBeforeTestRun"/>
</before>
<after>
<magentoCLI command="config:set {{EmptyCookieDomainForMainWebsiteConfigData.path}} --scope={{EmptyCookieDomainForMainWebsiteConfigData.scope}} --scope-code={{EmptyCookieDomainForMainWebsiteConfigData.scope_code}} {{EmptyCookieDomainForMainWebsiteConfigData.value}}" stepKey="changeDomainForMainWebsiteAfterTestComplete"/>
<magentoCLI command="cache:flush config" stepKey="flushCacheAfterTestComplete"/>
</after>
<actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/>
<actionGroup ref="AssertAdminDashboardPageIsVisibleActionGroup" stepKey="seeDashboardPage"/>
<actionGroup ref="logout" stepKey="logoutFromAdmin"/>
</test>
</tests>
4 changes: 2 additions & 2 deletions app/code/Magento/Backend/Test/Mftf/Test/AdminLoginTest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-->

<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
<test name="AdminLoginTest">
<annotations>
<features value="Backend"/>
Expand All @@ -24,4 +24,4 @@
<seeInCurrentUrl url="{{AdminLoginPage.url}}" stepKey="seeAdminLoginUrl"/>
<actionGroup ref="logout" stepKey="logoutFromAdmin"/>
</test>
</tests>
</tests>
93 changes: 93 additions & 0 deletions app/code/Magento/Backend/Test/Mftf/Test/AdminPrivacyPolicyTest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
<test name="AdminPrivacyPolicyTest">
<annotations>
<features value="Backend"/>
<stories value="Checks to see if privacy policy url is in the admin page and every sub page"/>
<title value="There should be a privacy policy url in the admin page and every sub page"/>
<description value="There should be a privacy policy url in the admin page and every sub page"/>
<severity value="CRITICAL"/>
<testCaseId value="MC-17787"/>
<group value="backend"/>
<group value="login"/>
</annotations>

<!-- Logging in Magento admin and checking for Privacy policy footer in dashboard -->
<actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/>
<closeAdminNotification stepKey="closeAdminNotification"/>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkDashboard"/>

<!-- Checking for Privacy policy footer in salesOrderPage -->
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToSalesOrder">
<argument name="menuUiId" value="magento-sales-sales"/>
<argument name="submenuUiId" value="magento-sales-sales-order"/>
</actionGroup>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkSalesOrder"/>

<!-- Checking for Privacy policy footer in catalogProductsPage -->
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToCatalogProducts">
<argument name="menuUiId" value="magento-catalog-catalog"/>
<argument name="submenuUiId" value="magento-catalog-catalog-products"/>
</actionGroup>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkCatalogProducts"/>

<!-- Checking for Privacy policy footer in customersAllCustomersPage -->
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToCustomersAllCustomers">
<argument name="menuUiId" value="magento-customer-customer"/>
<argument name="submenuUiId" value="magento-customer-customer-manage"/>
</actionGroup>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkCustomersAllCustomers"/>

<!-- Checking for Privacy policy footer in marketingCatalogPriceRulePage -->
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToMarketingCatalogPriceRule">
<argument name="menuUiId" value="magento-backend-marketing"/>
<argument name="submenuUiId" value="magento-catalogrule-promo-catalog"/>
</actionGroup>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkMarketingCatalogPriceRule"/>

<!-- Checking for Privacy policy footer in contentBlocksPage -->
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToContentBlocks">
<argument name="menuUiId" value="magento-backend-content"/>
<argument name="submenuUiId" value="magento-cms-cms-block"/>
</actionGroup>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkContentBlocks"/>

<!-- Checking for Privacy policy footer in reportSearcbTermsPage -->
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToReportsSearchTerms">
<argument name="menuUiId" value="magento-reports-report"/>
<argument name="submenuUiId" value="magento-search-report-search-term"/>
</actionGroup>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkReportsSearchTerms"/>

<!-- Checking for Privacy policy footer in storesAllStoresPage -->
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToStoresAllStores">
<argument name="menuUiId" value="magento-backend-stores"/>
<argument name="submenuUiId" value="magento-backend-system-store"/>
</actionGroup>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkStoresAllStores"/>

<!-- Checking for Privacy policy footer in systemImportPage -->
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToSystemImport">
<argument name="menuUiId" value="magento-backend-system"/>
<argument name="submenuUiId" value="magento-importexport-system-convert-import"/>
</actionGroup>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkSystemImport"/>

<!-- Checking for Privacy policy footer in findPartnersAndExtensionsPage -->
<actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToFindPartnersAndExtensions">
<argument name="menuUiId" value="magento-marketplace-partners"/>
<argument name="submenuUiId" value="magento-marketplace-partners"/>
</actionGroup>
<seeLink userInput="Privacy Policy" url="https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf" stepKey="seePrivacyPolicyLinkFindPartnersAndExtensions"/>
</test>
</tests>


1 change: 1 addition & 0 deletions app/code/Magento/Backend/etc/adminhtml/di.xml
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@
<arguments>
<argument name="lifetimePath" xsi:type="const">Magento\Backend\Model\Auth\Session::XML_PATH_SESSION_LIFETIME</argument>
<argument name="sessionName" xsi:type="const">Magento\Backend\Model\Session\AdminConfig::SESSION_NAME_ADMIN</argument>
<argument name="scopeType" xsi:type="const">Magento\Framework\App\Config\ScopeConfigInterface::SCOPE_TYPE_DEFAULT</argument>
</arguments>
</type>
<type name="Magento\Framework\View\Result\PageFactory">
Expand Down
6 changes: 6 additions & 0 deletions app/code/Magento/Backend/view/adminhtml/layout/default.xml
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,17 @@
</container>
<container name="legal.system" htmlTag="div" htmlClass="footer-legal-system col-m-6">
<block class="Magento\Backend\Block\Page\Footer" name="version" as="version" />
<block class="Magento\Framework\View\Element\Template" name="privacyPolicy" as="privacyPolicy" template="Magento_Backend::page/privacyPolicy.phtml">
<arguments>
<argument name="privacypolicy_url" xsi:type="string">https://magento.com/sites/default/files/REVISED-MAGENTO-PRIVACY-POLICY.pdf</argument>
</arguments>
</block>
<block class="Magento\Framework\View\Element\Template" name="report" as="report" template="Magento_Backend::page/report.phtml">
<arguments>
<argument name="bugreport_url" xsi:type="string">https://github.com/magento/magento2/issues</argument>
</arguments>
</block>

</container>
</container>
</referenceContainer>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/

?>

<a class="link-report" href="<?= $block->escapeUrl($block->getPrivacypolicyUrl()) ?>" id="footer_privacy" target="_blank">
<?= $block->escapeHtml(__('Privacy Policy')) ?>
</a> |
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@
<?php if ($block->hasDefaultOption()) : ?>
<li class="store-switcher-all <?php if (!($block->getDefaultSelectionName() != $block->getCurrentSelectionName())) : ?>disabled<?php endif; ?> <?php if (!$block->hasScopeSelected()) : ?>current<?php endif; ?>">
<?php if ($block->getDefaultSelectionName() != $block->getCurrentSelectionName()) : ?>
?>
<a data-role="store-view-id" data-value="" href="#">
<?= $block->escapeHtml($block->getDefaultSelectionName()) ?>
</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ if ($isField) {

<?php if (!$element->getNoContainer()) : ?>
<fieldset class="<?= $block->escapeHtmlAttr($cssClass) ?>" id="<?= $block->escapeHtmlAttr($id) ?>">
<?php if (strlen($element->getBeforeElementHtml())) : ?>
<?= $element->getBeforeElementHtml() ?>
<?php endif ?>
<?php if ($element->getLegend() && !$isWrapped) : ?>
<legend class="<?= /* @noEscape */ $isField ? 'label admin__field-label' : 'admin__legend legend' ?>">
<span><?= $block->escapeHtml($element->getLegend()) ?></span>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
namespace Magento\Bundle\Block\Adminhtml\Catalog\Product\Edit\Tab\Attributes;

/**
* Bundle Extended Attribures Block.
* Bundle Extended Attributes Block.
*
* @author Magento Core Team <[email protected]>
*/
Expand Down
Loading

0 comments on commit 4382c3a

Please sign in to comment.