Skip to content

Commit

Permalink
Merge pull request #4 from magento/2.3-develop
Browse files Browse the repository at this point in the history
magento 2.3-develop:update branch
  • Loading branch information
speedy008 authored Nov 14, 2018
2 parents cd97592 + 877bffd commit ded5c49
Show file tree
Hide file tree
Showing 333 changed files with 5,001 additions and 1,358 deletions.
8 changes: 4 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ To get detailed information about changes in Magento 2.1.0, please visit [Magent
* Updated styles
* Sample Data:
* Improved sample data installation UX
* Updated sample data with Product Heros, color swatches, MAP and rule based product relations
* Updated sample data with Product Heroes, color swatches, MAP and rule based product relations
* Improved sample data upgrade flow
* Added the ability to log errors and set the error flag during sample data installation
* Various improvements:
Expand Down Expand Up @@ -2284,7 +2284,7 @@ Tests:
* Fixed an issue where no results were found for Coupons reports
* Fixed an issue with incremental Qty setting
* Fixed an issue with allowing importing of negative weight values
* Fixed an issue with Inventory - Only X left Treshold being not dependent on Qty for Item's Status to Become Out of Stock
* Fixed an issue with Inventory - Only X left Threshold being not dependent on Qty for Item's Status to Become Out of Stock
* Fixed an issue where the "Catalog Search Index index was rebuilt." message was displayed when reindexing the Catalog Search index
* Search module:
* Integrated the Search library to the advanced search functionality
Expand Down Expand Up @@ -2706,7 +2706,7 @@ Tests:
* Ability to support extensible service data objects
* No Code Duplication in Root Templates
* Fixed bugs:
* Persistance session application. Loggin out the customer
* Persistence session application. Logging out the customer
* Placing the order with two terms and conditions
* Saving of custom option by service catalogProductCustomOptionsWriteServiceV1
* Placing the order on frontend if enter in the street address line 1 and 2 255 symbols
Expand Down Expand Up @@ -2965,7 +2965,7 @@ Tests:
* Fixed an issue with incorrect items label for the cases when there are more than one item in the category
* Fixed an issue when configurable product was out of stock in Google Shopping while being in stock in the Magento backend
* Fixed an issue when swipe gesture in menu widget was not supported on mobile
* Fixed an issue when it was impossible to enter alpha-numeric zip code on the stage of estimating shipping and tax rates
* Fixed an issue when it was impossible to enter alphanumeric zip code on the stage of estimating shipping and tax rates
* Fixed an issue when custom price was not applied when editing an order
* Fixed an issue when items were not returned to stock after unsuccessful order was placed
* Fixed an issue when error message appeared "Cannot save the credit memo” while creating credit memo
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,13 +103,13 @@ public function testGetAllWebsitesValue()
$this->webSiteModel->expects($this->once())->method('getBaseCurrency')->willReturn($currency);

$expectedResult = AdvancedPricing::VALUE_ALL_WEBSITES . ' [' . $currencyCode . ']';
$this->websiteString = $this->getMockBuilder(
$websiteString = $this->getMockBuilder(
\Magento\AdvancedPricingImportExport\Model\Import\AdvancedPricing\Validator\Website::class
)
->setMethods(['_clearMessages', '_addMessages'])
->setConstructorArgs([$this->storeResolver, $this->webSiteModel])
->getMock();
$result = $this->websiteString->getAllWebsitesValue();
$result = $websiteString->getAllWebsitesValue();

$this->assertEquals($expectedResult, $result);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
<severity value="MAJOR"/>
<testCaseId value="MAGETWO-63898"/>
<group value="analytics"/>
<skip>
<issueId value="MAGETWO-96223"/>
</skip>
</annotations>

<actionGroup ref="LoginActionGroup" stepKey="loginAsAdmin"/>
Expand Down
3 changes: 3 additions & 0 deletions app/code/Magento/Analytics/etc/adminhtml/system.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@
<source_model>Magento\Analytics\Model\Config\Source\Vertical</source_model>
<backend_model>Magento\Analytics\Model\Config\Backend\Vertical</backend_model>
<frontend_model>Magento\Analytics\Block\Adminhtml\System\Config\Vertical</frontend_model>
<depends>
<field id="analytics/general/enabled">1</field>
</depends>
</field>
<field id="additional_comment" translate="label comment" type="label" sortOrder="40" showInDefault="1" showInWebsite="0" showInStore="0">
<label><![CDATA[<strong>Get more insights from Magento Business Intelligence</strong>]]></label>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
namespace Magento\AsynchronousOperations\Controller\Adminhtml\Bulk;

/**
* Class View Opertion Details Controller
* Class View Operation Details Controller
*/
class Details extends \Magento\Backend\App\Action
class Details extends \Magento\Backend\App\Action implements \Magento\Framework\App\Action\HttpGetActionInterface
{
/**
* @var \Magento\Framework\View\Result\PageFactory
Expand Down
6 changes: 5 additions & 1 deletion app/code/Magento/Backend/App/Request/BackendValidator.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,8 @@ public function __construct(
}

/**
* Validate request
*
* @param RequestInterface $request
* @param ActionInterface $action
*
Expand Down Expand Up @@ -115,6 +117,8 @@ private function validateRequest(
}

/**
* Create exception
*
* @param RequestInterface $request
* @param ActionInterface $action
*
Expand Down Expand Up @@ -166,7 +170,7 @@ public function validate(
ActionInterface $action
): void {
if ($action instanceof AbstractAction) {
//Abstract Action has build-in validation.
//Abstract Action has built-in validation.
if (!$action->_processUrlKeys()) {
throw new InvalidRequestException($action->getResponse());
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
*/
namespace Magento\Backend\Block\Widget\Grid\Column\Filter;

/**
* Theme grid filter
*/
class Theme extends \Magento\Backend\Block\Widget\Grid\Column\Filter\AbstractFilter
{
/**
Expand Down Expand Up @@ -54,7 +57,8 @@ public function getHtml()
}

/**
* Retrieve options setted in column.
* Retrieve options set in column.
*
* Or load if options was not set.
*
* @return array
Expand Down
34 changes: 31 additions & 3 deletions app/code/Magento/Backend/Block/Widget/Tabs.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
use Magento\Backend\Block\Widget\Tab\TabInterface;

/**
* Tabs widget
*
* @api
* @SuppressWarnings(PHPMD.NumberOfChildren)
* @since 100.0.2
Expand Down Expand Up @@ -178,6 +180,8 @@ protected function _addTabByName($tab, $tabId)
}

/**
* Get active tab id
*
* @return string
*/
public function getActiveTabId()
Expand All @@ -187,6 +191,7 @@ public function getActiveTabId()

/**
* Set Active Tab
*
* Tab has to be not hidden and can show
*
* @param string $tabId
Expand Down Expand Up @@ -231,7 +236,7 @@ protected function _setActiveTab($tabId)
}

/**
* {@inheritdoc}
* @inheritdoc
*/
protected function _beforeToHtml()
{
Expand Down Expand Up @@ -282,6 +287,8 @@ private function reorderTabs()
}

/**
* Apply tabs order
*
* @param array $orderByPosition
* @param array $orderByIdentity
*
Expand All @@ -294,7 +301,7 @@ private function applyTabsCorrectOrder(array $orderByPosition, array $orderByIde
/**
* Rearrange the positions by using the after tag for each tab.
*
* @var integer $position
* @var int $position
* @var TabInterface $tab
*/
foreach ($orderByPosition as $position => $tab) {
Expand Down Expand Up @@ -338,6 +345,8 @@ private function finalTabsSortOrder(array $orderByPosition)
}

/**
* Get js object name
*
* @return string
*/
public function getJsObjectName()
Expand All @@ -346,6 +355,8 @@ public function getJsObjectName()
}

/**
* Get tabs ids
*
* @return string[]
*/
public function getTabsIds()
Expand All @@ -358,6 +369,8 @@ public function getTabsIds()
}

/**
* Get tab id
*
* @param \Magento\Framework\DataObject|TabInterface $tab
* @param bool $withPrefix
* @return string
Expand All @@ -371,6 +384,8 @@ public function getTabId($tab, $withPrefix = true)
}

/**
* CVan show tab
*
* @param \Magento\Framework\DataObject|TabInterface $tab
* @return bool
*/
Expand All @@ -383,6 +398,8 @@ public function canShowTab($tab)
}

/**
* Get tab is hidden
*
* @param \Magento\Framework\DataObject|TabInterface $tab
* @return bool
* @SuppressWarnings(PHPMD.BooleanGetMethodName)
Expand All @@ -396,6 +413,8 @@ public function getTabIsHidden($tab)
}

/**
* Get tab url
*
* @param \Magento\Framework\DataObject|TabInterface $tab
* @return string
*/
Expand All @@ -414,6 +433,8 @@ public function getTabUrl($tab)
}

/**
* Get tab title
*
* @param \Magento\Framework\DataObject|TabInterface $tab
* @return string
*/
Expand All @@ -426,6 +447,8 @@ public function getTabTitle($tab)
}

/**
* Get tab class
*
* @param \Magento\Framework\DataObject|TabInterface $tab
* @return string
*/
Expand All @@ -441,6 +464,8 @@ public function getTabClass($tab)
}

/**
* Get tab label
*
* @param \Magento\Framework\DataObject|TabInterface $tab
* @return string
*/
Expand All @@ -453,6 +478,8 @@ public function getTabLabel($tab)
}

/**
* Get tab content
*
* @param \Magento\Framework\DataObject|TabInterface $tab
* @return string
*/
Expand All @@ -468,7 +495,8 @@ public function getTabContent($tab)
}

/**
* Mark tabs as dependant of each other
* Mark tabs as dependent of each other
*
* Arbitrary number of tabs can be specified, but at least two
*
* @param string $tabOneId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,15 @@
use Symfony\Component\Console\Input\InputOption;

/**
* Abstract cache command
*
* @api
* @since 100.0.2
*/
abstract class AbstractCacheCommand extends Command
{
/**
* Input option bootsrap
* Input option bootstrap
*/
const INPUT_KEY_BOOTSTRAP = 'bootstrap';

Expand All @@ -40,7 +42,7 @@ public function __construct(Manager $cacheManager)
}

/**
* {@inheritdoc}
* @inheritdoc
*/
protected function configure()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,6 @@ public function testGetMenuGenericExceptionIsNotLogged()
} catch (\Exception $e) {
return;
}
$this->fail("Generic \Exception was not throwed");
$this->fail("Generic \Exception was not thrown");
}
}
2 changes: 1 addition & 1 deletion app/code/Magento/Backend/etc/adminhtml/system.xml
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@
<field id="*/*/template_hints_storefront">1</field>
<field id="*/*/template_hints_storefront_show_with_parameter">1</field>
</depends>
<comment>Add the following paramater to the URL to show template hints ?templatehints=[parameter_value]</comment>
<comment>Add the following parameter to the URL to show template hints ?templatehints=[parameter_value]</comment>
</field>
<field id="template_hints_admin" translate="label" type="select" sortOrder="20" showInDefault="1" showInWebsite="0" showInStore="0">
<label>Enabled Template Path Hints for Admin</label>
Expand Down
7 changes: 5 additions & 2 deletions app/code/Magento/Backup/Controller/Adminhtml/Index.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,24 @@
*/
namespace Magento\Backup\Controller\Adminhtml;

use Magento\Backend\App\Action;
use Magento\Framework\App\Action\HttpGetActionInterface;

/**
* Backup admin controller
*
* @author Magento Core Team <core@magentocommerce.com>
* @api
* @since 100.0.2
*/
abstract class Index extends \Magento\Backend\App\Action
abstract class Index extends Action implements HttpGetActionInterface
{
/**
* Authorization level of a basic admin session
*
* @see _isAllowed()
*/
const ADMIN_RESOURCE = 'Magento_Backend::backup';
const ADMIN_RESOURCE = 'Magento_Backup::backup';

/**
* Core registry
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ public function build(array $buildSubject)

$payment = $paymentDO->getPayment();
$data = $payment->getAdditionalInformation();
// the payment token could be stored only if a customer checks the Vault flow on storefront
// see https://developers.braintreepayments.com/guides/paypal/vault/javascript/v2#invoking-the-vault-flow
if (!empty($data[VaultConfigProvider::IS_ACTIVE_CODE])) {
$result[self::$optionsKey] = [
self::$storeInVaultOnSuccess => true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
namespace Magento\Braintree\Gateway\Request;

use Magento\Braintree\Gateway\SubjectReader;
use Magento\Framework\Exception\LocalizedException;
use Magento\Payment\Gateway\Command\CommandException;
use Magento\Payment\Gateway\Request\BuilderInterface;
use Magento\Payment\Helper\Formatter;

Expand Down Expand Up @@ -41,6 +43,9 @@ public function build(array $buildSubject)
$payment = $paymentDO->getPayment();
$extensionAttributes = $payment->getExtensionAttributes();
$paymentToken = $extensionAttributes->getVaultPaymentToken();
if ($paymentToken === null) {
throw new CommandException(__('The Payment Token is not available to perform the request.'));
}
return [
'amount' => $this->formatPrice($this->subjectReader->readAmount($buildSubject)),
'paymentMethodToken' => $paymentToken->getGatewayToken()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ private function updateBillingAddress(Quote $quote, array $details)
{
$billingAddress = $quote->getBillingAddress();

if ($this->config->isRequiredBillingAddress()) {
if ($this->config->isRequiredBillingAddress() && !empty($details['billingAddress'])) {
$this->updateAddressData($billingAddress, $details['billingAddress']);
} else {
$this->updateAddressData($billingAddress, $details['shippingAddress']);
Expand Down
Loading

0 comments on commit ded5c49

Please sign in to comment.