Skip to content

Commit

Permalink
Merge pull request #21 from sanganinamrata/2.1-develop-PR-port-16646
Browse files Browse the repository at this point in the history
[Backport] Corrected Magento_Framework's test xml file.
  • Loading branch information
sanganinamrata authored Oct 1, 2019
2 parents 321389f + 1591f54 commit 601949f
Show file tree
Hide file tree
Showing 89 changed files with 402 additions and 150 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ Magento is thankful for any contribution that can improve our code base, documen

<h2>Reporting security issues</h2>

To report security vulnerabilities in Magento software or web sites, please e-mail <a href="mailto:security@magento.com">security@magento.com</a>. Please do not report security issues using GitHub. Be sure to encrypt your e-mail with our <a href="https://info2.magento.com/rs/magentoenterprise/images/security_at_magento.asc">encryption key</a> if it includes sensitive information. Learn more about reporting security issues <a href="https://magento.com/security/reporting-magento-security-issue">here</a>.
To report security vulnerabilities in Magento software or web sites, please create a Bugcrowd researcher account <a href="https://bugcrowd.com/magento">there</a> to submit and follow-up your issue. Learn more about reporting security issues <a href="https://magento.com/security/reporting-magento-security-issue">here</a>.

Stay up-to-date on the latest vulnerabilities and patches for Magento by signing up for <a href="https://magento.com/security/sign-up">Security Alert Notifications</a>.

Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ protected function saveAndReplaceAdvancedPrices()
),
'qty' => $rowData[self::COL_TIER_PRICE_QTY],
'value' => $rowData[self::COL_TIER_PRICE],
'website_id' => $this->getWebsiteId($rowData[self::COL_TIER_PRICE_WEBSITE])
'website_id' => $this->getWebSiteId($rowData[self::COL_TIER_PRICE_WEBSITE])
];
}
}
Expand Down
11 changes: 7 additions & 4 deletions app/code/Magento/Authorizenet/Model/Directpost.php
Original file line number Diff line number Diff line change
Expand Up @@ -820,11 +820,14 @@ protected function declineOrder(\Magento\Sales\Model\Order $order, $message = ''
{
try {
$response = $this->getResponse();
if (
$voidPayment && $response->getXTransId() && strtoupper($response->getXType())
== self::REQUEST_TYPE_AUTH_ONLY
if ($voidPayment
&& $response->getXTransId()
&& strtoupper($response->getXType()) == self::REQUEST_TYPE_AUTH_ONLY
) {
$order->getPayment()->setTransactionId(null)->setParentTransactionId($response->getXTransId())->void();
$order->getPayment()
->setTransactionId(null)
->setParentTransactionId($response->getXTransId())
->void($response);
}
$order->registerCancellation($message)->save();
} catch (\Exception $e) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ protected function _prepareForm()
['data' => ['id' => 'edit_form', 'action' => $this->getData('action'), 'method' => 'post']]
);

$this->_prepareStoreFieldSet($form);
$this->_prepareStoreFieldset($form);

$form->addField(
'store_type',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ public function execute()
$user = $this->_objectManager->create('Magento\User\Model\User')->load($userId);

$user->setId($userId)
->setUsername($this->getRequest()->getParam('username', false))
->setFirstname($this->getRequest()->getParam('firstname', false))
->setLastname($this->getRequest()->getParam('lastname', false))
->setUserName($this->getRequest()->getParam('username', false))
->setFirstName($this->getRequest()->getParam('firstname', false))
->setLastName($this->getRequest()->getParam('lastname', false))
->setEmail(strtolower($this->getRequest()->getParam('email', false)));

if ($this->_objectManager->get('Magento\Framework\Validator\Locale')->isValid($interfaceLocale)) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
data-mage-init='{"dropdown":{}}'
data-toggle="dropdown">
<span class="admin__action-dropdown-text">
<span class="admin-user-account-text"><?php echo $block->escapeHtml($block->getUser()->getUsername()); ?></span>
<span class="admin-user-account-text"><?php echo $block->escapeHtml($block->getUser()->getUserName()); ?></span>
</span>
</a>
<ul class="admin__action-dropdown-menu">
Expand All @@ -39,7 +39,7 @@
href="<?php /* @escapeNotVerified */ echo $block->getUrl('adminhtml/system_account/index') ?>"
<?php /* @escapeNotVerified */ echo $block->getUiId('user', 'account', 'settings')?>
title="<?php echo $block->escapeHtml(__('Account Setting')) ?>">
<?php /* @escapeNotVerified */ echo __('Account Setting') ?> (<span class="admin-user-name"><?php echo $block->escapeHtml($block->getUser()->getUsername()); ?></span>)
<?php /* @escapeNotVerified */ echo __('Account Setting') ?> (<span class="admin-user-name"><?php echo $block->escapeHtml($block->getUser()->getUserName()); ?></span>)
</a>
</li>
<?php endif; ?>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,16 @@
<script data-template="search-suggest" type="text/x-magento-template">
<ul class="search-global-menu">
<li class="item">
<a id="searchPreviewProducts" href="<?php /* @escapeNotVerified */ echo $block->getURL('catalog/product/index/'); ?>?search=<%- data.term%>" class="title">"<%- data.term%>" in Products</a>
<a id="searchPreviewProducts" href="<?php /* @escapeNotVerified */ echo $block->getUrl('catalog/product/index/'); ?>?search=<%- data.term%>" class="title">"<%- data.term%>" in Products</a>
</li>
<li class="item">
<a id="searchPreviewOrders" href="<?php /* @escapeNotVerified */ echo $block->getURL('sales/order/index/'); ?>?search=<%- data.term%>" class="title">"<%- data.term%>" in Orders</a>
<a id="searchPreviewOrders" href="<?php /* @escapeNotVerified */ echo $block->getUrl('sales/order/index/'); ?>?search=<%- data.term%>" class="title">"<%- data.term%>" in Orders</a>
</li>
<li class="item">
<a id="searchPreviewCustomers" href="<?php /* @escapeNotVerified */ echo $block->getURL('customer/index/index/'); ?>?search=<%- data.term%>" class="title">"<%- data.term%>" in Customers</a>
<a id="searchPreviewCustomers" href="<?php /* @escapeNotVerified */ echo $block->getUrl('customer/index/index/'); ?>?search=<%- data.term%>" class="title">"<%- data.term%>" in Customers</a>
</li>
<li class="item">
<a id="searchPreviewPages" href="<?php /* @escapeNotVerified */ echo $block->getURL('cms/page/index/'); ?>?search=<%- data.term%>" class="title">"<%- data.term%>" in Pages</a>
<a id="searchPreviewPages" href="<?php /* @escapeNotVerified */ echo $block->getUrl('cms/page/index/'); ?>?search=<%- data.term%>" class="title">"<%- data.term%>" in Pages</a>
</li>
<% if (data.items.length) { %>
<% _.each(data.items, function(value){ %>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ $numColumns = sizeof($block->getColumns());
<?php if ($block->getPagerVisibility()): ?>
<div class="admin__data-grid-pager-wrap">
<select name="<?php /* @escapeNotVerified */ echo $block->getVarNameLimit() ?>"
id="<?php echo $block->escapeHTML($block->getHtmlId())?>_page-limit"
id="<?php echo $block->escapeHtml($block->getHtmlId())?>_page-limit"
onchange="<?php /* @escapeNotVerified */ echo $block->getJsObjectName() ?>.loadByElement(this)"
class="admin__control-select">
<option value="20"<?php if ($block->getCollection()->getPageSize() == 20): ?>
Expand All @@ -91,7 +91,7 @@ $numColumns = sizeof($block->getColumns());
selected="selected"<?php endif; ?>>200
</option>
</select>
<label for="<?php echo $block->escapeHTML($block->getHtmlId())?><?php echo $block->escapeHTML($block->getHtmlId())?>_page-limit"
<label for="<?php echo $block->escapeHtml($block->getHtmlId())?><?php echo $block->escapeHtml($block->getHtmlId())?>_page-limit"
class="admin__control-support-text"><?php /* @escapeNotVerified */ echo __('per page') ?></label>

<div class="admin__data-grid-pager">
Expand All @@ -107,12 +107,12 @@ $numColumns = sizeof($block->getColumns());
<button type="button" class="action-previous disabled"><span><?php /* @escapeNotVerified */ echo __('Previous page') ?></span></button>
<?php endif; ?>
<input type="text"
id="<?php echo $block->escapeHTML($block->getHtmlId())?>_page-current"
id="<?php echo $block->escapeHtml($block->getHtmlId())?>_page-current"
name="<?php /* @escapeNotVerified */ echo $block->getVarNamePage() ?>"
value="<?php /* @escapeNotVerified */ echo $_curPage ?>"
class="admin__control-text"
onkeypress="<?php /* @escapeNotVerified */ echo $block->getJsObjectName() ?>.inputPage(event, '<?php /* @escapeNotVerified */ echo $_lastPage ?>')" <?php /* @escapeNotVerified */ echo $block->getUiId('current-page') ?> />
<label class="admin__control-support-text" for="<?php echo $block->escapeHTML($block->getHtmlId())?>_page-current">
<label class="admin__control-support-text" for="<?php echo $block->escapeHtml($block->getHtmlId())?>_page-current">
<?php /* @escapeNotVerified */ echo __('of %1', '<span>' . $block->getCollection()->getLastPageNumber() . '</span>') ?>
</label>
<?php if ($_curPage < $_lastPage): ?>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public function handle(array $handlingSubject, array $response)
private function getCreditCardType($type)
{
$replaced = str_replace(' ', '-', strtolower($type));
$mapper = $this->config->getCctypesMapper();
$mapper = $this->config->getCcTypesMapper();

return $mapper[$replaced];
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ private function convertDetailsToJSON($details)
private function getCreditCardType($type)
{
$replaced = str_replace(' ', '-', strtolower($type));
$mapper = $this->config->getCctypesMapper();
$mapper = $this->config->getCcTypesMapper();

return $mapper[$replaced];
}
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Braintree/Model/Ui/ConfigProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public function getConfig()
self::CODE => [
'isActive' => $this->config->isActive($storeId),
'clientToken' => $this->getClientToken(),
'ccTypesMapper' => $this->config->getCctypesMapper(),
'ccTypesMapper' => $this->config->getCcTypesMapper(),
'sdkUrl' => $this->config->getSdkUrl(),
'countrySpecificCardTypes' => $this->config->getCountrySpecificCardTypeConfig($storeId),
'availableCardTypes' => $this->config->getAvailableCardTypes($storeId),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ public function testGetCcTypesMapper($value, $expected)

static::assertEquals(
$expected,
$this->model->getCctypesMapper()
$this->model->getCcTypesMapper()
);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ $config = [
class="action-braintree-paypal-logo" disabled>
<img class="braintree-paypal-button-hidden"
src="https://checkout.paypal.com/pwpp/2.17.6/images/pay-with-paypal.png"
alt="<?= $block->escapeHtml(__('Pay with PayPal')) ?>"
title="<?= $block->escapeHtml(__('Pay with PayPal')) ?>"/>
alt="<?php echo $block->escapeHtml(__('Pay with PayPal')); ?>"
title="<?php echo $block->escapeHtml(__('Pay with PayPal')); ?>"/>
</button>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class Checkbox extends \Magento\Bundle\Block\Catalog\Product\View\Type\Bundle\Op
/**
* @var string
*/
protected $_template = 'product/composite/fieldset/options/type/checkbox.phtml';
protected $_template = 'Magento_Bundle::product/composite/fieldset/options/type/checkbox.phtml';

/**
* @param string $elementId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class Multi extends \Magento\Bundle\Block\Catalog\Product\View\Type\Bundle\Optio
/**
* @var string
*/
protected $_template = 'product/composite/fieldset/options/type/multi.phtml';
protected $_template = 'Magento_Bundle::product/composite/fieldset/options/type/multi.phtml';

/**
* @param string $elementId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class Radio extends \Magento\Bundle\Block\Catalog\Product\View\Type\Bundle\Optio
/**
* @var string
*/
protected $_template = 'product/composite/fieldset/options/type/radio.phtml';
protected $_template = 'Magento_Bundle::product/composite/fieldset/options/type/radio.phtml';

/**
* @param string $elementId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class Select extends \Magento\Bundle\Block\Catalog\Product\View\Type\Bundle\Opti
/**
* @var string
*/
protected $_template = 'product/composite/fieldset/options/type/select.phtml';
protected $_template = 'Magento_Bundle::product/composite/fieldset/options/type/select.phtml';

/**
* @param string $elementId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class Bundle extends \Magento\Backend\Block\Widget implements \Magento\Backend\B
/**
* @var string
*/
protected $_template = 'product/edit/bundle.phtml';
protected $_template = 'Magento_Bundle::product/edit/bundle.phtml';

/**
* Core registry
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class Option extends \Magento\Backend\Block\Widget
/**
* @var string
*/
protected $_template = 'product/edit/bundle/option.phtml';
protected $_template = 'Magento_Bundle::product/edit/bundle/option.phtml';

/**
* Core registry
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class Search extends \Magento\Backend\Block\Widget
/**
* @var string
*/
protected $_template = 'product/edit/bundle/option/search.phtml';
protected $_template = 'Magento_Bundle::product/edit/bundle/option/search.phtml';

/**
* @return void
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class Selection extends \Magento\Backend\Block\Widget
/**
* @var string
*/
protected $_template = 'product/edit/bundle/option/selection.phtml';
protected $_template = 'Magento_Bundle::product/edit/bundle/option/selection.phtml';

/**
* Catalog data
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ class Checkbox extends \Magento\Bundle\Block\Catalog\Product\View\Type\Bundle\Op
/**
* @var string
*/
protected $_template = 'catalog/product/view/type/bundle/option/checkbox.phtml';
protected $_template = 'Magento_Bundle::catalog/product/view/type/bundle/option/checkbox.phtml';
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ class Multi extends \Magento\Bundle\Block\Catalog\Product\View\Type\Bundle\Optio
/**
* @var string
*/
protected $_template = 'catalog/product/view/type/bundle/option/multi.phtml';
protected $_template = 'Magento_Bundle::catalog/product/view/type/bundle/option/multi.phtml';
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ class Radio extends \Magento\Bundle\Block\Catalog\Product\View\Type\Bundle\Optio
/**
* @var string
*/
protected $_template = 'catalog/product/view/type/bundle/option/radio.phtml';
protected $_template = 'Magento_Bundle::catalog/product/view/type/bundle/option/radio.phtml';
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ class Select extends \Magento\Bundle\Block\Catalog\Product\View\Type\Bundle\Opti
/**
* @var string
*/
protected $_template = 'catalog/product/view/type/bundle/option/select.phtml';
protected $_template = 'Magento_Bundle::catalog/product/view/type/bundle/option/select.phtml';
}
Loading

0 comments on commit 601949f

Please sign in to comment.