Skip to content

Commit

Permalink
[added app/code/Magento/Captcha/view/frontend/web/js/onepage.js js]
Browse files Browse the repository at this point in the history
  • Loading branch information
hitesh-wagento committed Sep 7, 2018
2 parents d41ef75 + b55989d commit 1fddf26
Show file tree
Hide file tree
Showing 2,867 changed files with 60,944 additions and 27,659 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -1977,7 +1977,7 @@ Tests:
* [#686](https://github.com/magento/magento2/issues/686) -- Product save validation errors in the admin don't hide the overlay
* [#702](https://github.com/magento/magento2/issues/702) -- Base table or view not found
* [#652](https://github.com/magento/magento2/issues/652) -- Multishipping checkout not to change the Billing address js issue
* [#648](https://github.com/magento/magento2/issues/648) -- An equal (=) sign in the hash of the product page to to break the tabs functionality
* [#648](https://github.com/magento/magento2/issues/648) -- An equal (=) sign in the hash of the product page to break the tabs functionality
* Service Contracts:
* Refactored usage of new API of the Customer module
* Implemented Service Contracts for the Sales module
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ To learn more about issue gate labels click [here](https://github.com/magento/ma

<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 security news and patches for Magento by signing up for <a href="https://magento.com/security/sign-up">Security Alert Notifications</a>.

Expand Down
12 changes: 10 additions & 2 deletions app/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,16 @@
&& isset($_SERVER['HTTP_ACCEPT'])
&& strpos($_SERVER['HTTP_ACCEPT'], 'text/html') !== false
) {
\Magento\Framework\Profiler::applyConfig(
(isset($_SERVER['MAGE_PROFILER']) && strlen($_SERVER['MAGE_PROFILER'])) ? $_SERVER['MAGE_PROFILER'] : trim(file_get_contents(BP . '/var/profiler.flag')),
$profilerConfig = isset($_SERVER['MAGE_PROFILER']) && strlen($_SERVER['MAGE_PROFILER'])
? $_SERVER['MAGE_PROFILER']
: trim(file_get_contents(BP . '/var/profiler.flag'));

if ($profilerConfig) {
$profilerConfig = json_decode($profilerConfig, true) ?: $profilerConfig;
}

Magento\Framework\Profiler::applyConfig(
$profilerConfig,
BP,
!empty($_SERVER['HTTP_X_REQUESTED_WITH']) && $_SERVER['HTTP_X_REQUESTED_WITH'] == 'XMLHttpRequest'
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public function __construct(
}

/**
* Predispath admin action controller
* Predispatch admin action controller
*
* @param \Magento\Framework\Event\Observer $observer
* @return void
Expand Down
20 changes: 0 additions & 20 deletions app/code/Magento/AdminNotification/Test/Mftf/composer.json

This file was deleted.

2 changes: 1 addition & 1 deletion app/code/Magento/AdminNotification/etc/adminhtml/menu.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
-->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Backend:etc/menu.xsd">
<menu>
<add id="Magento_AdminNotification::system_adminnotification" title="Notifications" translate="title" module="Magento_AdminNotification" sortOrder="10" parent="Magento_Backend::system_other_settings" action="adminhtml/notification" resource="Magento_AdminNotification::adminnotification"/>
<add id="Magento_AdminNotification::system_adminnotification" title="Notifications" translate="title" module="Magento_AdminNotification" sortOrder="10" parent="Magento_Backend::system_other_settings" action="adminhtml/notification" resource="Magento_AdminNotification::adminnotification"/>
</menu>
</config>
56 changes: 28 additions & 28 deletions app/code/Magento/AdminNotification/etc/db_schema_whitelist.json
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
{
"adminnotification_inbox": {
"column": {
"notification_id": true,
"severity": true,
"date_added": true,
"title": true,
"description": true,
"url": true,
"is_read": true,
"is_remove": true
"adminnotification_inbox": {
"column": {
"notification_id": true,
"severity": true,
"date_added": true,
"title": true,
"description": true,
"url": true,
"is_read": true,
"is_remove": true
},
"index": {
"ADMINNOTIFICATION_INBOX_SEVERITY": true,
"ADMINNOTIFICATION_INBOX_IS_READ": true,
"ADMINNOTIFICATION_INBOX_IS_REMOVE": true
},
"constraint": {
"PRIMARY": true
}
},
"index": {
"ADMINNOTIFICATION_INBOX_SEVERITY": true,
"ADMINNOTIFICATION_INBOX_IS_READ": true,
"ADMINNOTIFICATION_INBOX_IS_REMOVE": true
},
"constraint": {
"PRIMARY": true
}
},
"admin_system_messages": {
"column": {
"identity": true,
"severity": true,
"created_at": true
},
"constraint": {
"PRIMARY": true
"admin_system_messages": {
"column": {
"identity": true,
"severity": true,
"created_at": true
},
"constraint": {
"PRIMARY": true
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
{
"[data-role=system_messages_list]": {
"Magento_AdminNotification/js/system/messages/popup": {
class: 'modal-system-messages ui-popup-message'
"class":"modal-system-messages ui-popup-message"
}
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,24 +1,26 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
*/

define([
'jquery',
'Magento_Ui/js/modal/modal'
], function ($) {
], function ($, modal) {
'use strict';

return function (data, element) {
if (this.modal) {
this.modal.html($(element).html());

if (modal.modal) {
modal.modal.html($(element).html());
} else {
this.modal = $(element).modal({
modal.modal = $(element).modal({
modalClass: data.class,
type: 'popup',
buttons: []
});
}
this.modal.modal('openModal');

modal.modal.modal('openModal');
};
});
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@ public function execute()
);
return $resultLayout;
} catch (\Exception $e) {
$this->messageManager->addError($e->getMessage());
$this->messageManager->addErrorMessage($e->getMessage());
}
} else {
$this->messageManager->addError(__('Please correct the data sent.'));
$this->messageManager->addErrorMessage(__('Please correct the data sent.'));
}
/** @var \Magento\Backend\Model\View\Result\Redirect $resultRedirect */
$resultRedirect = $this->resultFactory->create(ResultFactory::TYPE_REDIRECT);
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ protected function setUp()
'_getCustomerGroupById',
'correctExportData'
]);
$this->advancedPricing = $this->getMockbuilder(
$this->advancedPricing = $this->getMockBuilder(
\Magento\AdvancedPricingImportExport\Model\Export\AdvancedPricing::class
)
->setMethods($mockMethods)
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/AdvancedSearch/Block/SearchData.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ abstract class SearchData extends Template implements SearchDataInterface
/**
* @var string
*/
protected $_template = 'search_data.phtml';
protected $_template = 'Magento_AdvancedSearch::search_data.phtml';

/**
* @param Template\Context $context
Expand Down
59 changes: 45 additions & 14 deletions app/code/Magento/AdvancedSearch/Model/ResourceModel/Index.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,23 @@
namespace Magento\AdvancedSearch\Model\ResourceModel;

use Magento\Framework\Model\ResourceModel\Db\AbstractDb;
use Magento\Framework\Search\Request\IndexScopeResolverInterface;
use Magento\Store\Model\StoreManagerInterface;
use Magento\Framework\Model\ResourceModel\Db\Context;
use Magento\Framework\EntityManager\MetadataPool;
use Magento\Catalog\Api\Data\CategoryInterface;
use Magento\Framework\App\ObjectManager;
use Magento\Framework\Indexer\ScopeResolver\IndexScopeResolver as TableResolver;
use Magento\Framework\Search\Request\Dimension;
use Magento\Catalog\Model\Indexer\Category\Product\AbstractAction;
use Magento\Framework\Search\Request\IndexScopeResolverInterface as TableResolver;
use Magento\Catalog\Model\Indexer\Product\Price\DimensionCollectionFactory;
use Magento\Store\Model\Indexer\WebsiteDimensionProvider;

/**
* @api
* @since 100.1.0
*
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
*/
class Index extends AbstractDb
{
Expand All @@ -38,25 +43,39 @@ class Index extends AbstractDb
*/
private $tableResolver;

/**
* @var DimensionCollectionFactory|null
*/
private $dimensionCollectionFactory;

/**
* @var int|null
*/
private $websiteId;

/**
* Index constructor.
* @param Context $context
* @param StoreManagerInterface $storeManager
* @param MetadataPool $metadataPool
* @param null $connectionName
* @param string|null $connectionName
* @param TableResolver|null $tableResolver
* @param DimensionCollectionFactory|null $dimensionCollectionFactory
*/
public function __construct(
Context $context,
StoreManagerInterface $storeManager,
MetadataPool $metadataPool,
$connectionName = null,
TableResolver $tableResolver = null
TableResolver $tableResolver = null,
DimensionCollectionFactory $dimensionCollectionFactory = null
) {
parent::__construct($context, $connectionName);
$this->storeManager = $storeManager;
$this->metadataPool = $metadataPool;
$this->tableResolver = $tableResolver ?: ObjectManager::getInstance()->get(TableResolver::class);
$this->tableResolver = $tableResolver ?: ObjectManager::getInstance()->get(IndexScopeResolverInterface::class);
$this->dimensionCollectionFactory = $dimensionCollectionFactory
?: ObjectManager::getInstance()->get(DimensionCollectionFactory::class);
}

/**
Expand All @@ -78,18 +97,27 @@ protected function _construct()
protected function _getCatalogProductPriceData($productIds = null)
{
$connection = $this->getConnection();

$select = $connection->select()->from(
$this->getTable('catalog_product_index_price'),
['entity_id', 'customer_group_id', 'website_id', 'min_price']
);

if ($productIds) {
$select->where('entity_id IN (?)', $productIds);
$catalogProductIndexPriceSelect = [];

foreach ($this->dimensionCollectionFactory->create() as $dimensions) {
if (!isset($dimensions[WebsiteDimensionProvider::DIMENSION_NAME]) ||
$this->websiteId === null ||
$dimensions[WebsiteDimensionProvider::DIMENSION_NAME]->getValue() === $this->websiteId) {
$select = $connection->select()->from(
$this->tableResolver->resolve('catalog_product_index_price', $dimensions),
['entity_id', 'customer_group_id', 'website_id', 'min_price']
);
if ($productIds) {
$select->where('entity_id IN (?)', $productIds);
}
$catalogProductIndexPriceSelect[] = $select;
}
}

$catalogProductIndexPriceUnionSelect = $connection->select()->union($catalogProductIndexPriceSelect);

$result = [];
foreach ($connection->fetchAll($select) as $row) {
foreach ($connection->fetchAll($catalogProductIndexPriceUnionSelect) as $row) {
$result[$row['website_id']][$row['entity_id']][$row['customer_group_id']] = round($row['min_price'], 2);
}

Expand All @@ -106,9 +134,12 @@ protected function _getCatalogProductPriceData($productIds = null)
*/
public function getPriceIndexData($productIds, $storeId)
{
$websiteId = $this->storeManager->getStore($storeId)->getWebsiteId();

$this->websiteId = $websiteId;
$priceProductsIndexData = $this->_getCatalogProductPriceData($productIds);
$this->websiteId = null;

$websiteId = $this->storeManager->getStore($storeId)->getWebsiteId();
if (!isset($priceProductsIndexData[$websiteId])) {
return [];
}
Expand Down
22 changes: 0 additions & 22 deletions app/code/Magento/AdvancedSearch/Test/Mftf/composer.json

This file was deleted.

Loading

0 comments on commit 1fddf26

Please sign in to comment.