Skip to content

Commit

Permalink
🔃 [EngCom] Public Pull Requests - 2.3-develop
Browse files Browse the repository at this point in the history
Accepted Public Pull Requests:
 - magento/magento2#19066: Add additional check if password hash is empty in auth process (by @progreg)
 - magento/magento2#19026: magento/magento2#18256: Reset password throws error since 2.2.6. (by @p-bystritsky)
 - magento/magento2#19040: [Forwardport] save downloadable product links for order items (by @swnsma)
 - magento/magento2#19048: WYSIWYG unable to set default value in ui component (by @omiroshnichenko)
 - magento/magento2#19050: Add/update newsletter messages in translation file (by @arnoudhgz)
 - magento/magento2#19029: 18901-Forgot-password-form-should-not-available-while-customer-is-log� (by @agorbulin)
 - magento/magento2#19010: Fix for Internet Explorer 11: Edit customer in backend leads sometimes to a "loading circle" and error object does not support method "includes" (by @omiroshnichenko)
 - magento/magento2#18991: magento/magento2#10440: [Forwardport] Missing $debugHintsPath when sending email via command. (by @p-bystritsky)
 - magento/magento2#18988: [Forwardport] #17890: show correct text swatch values per store view (by @nmalevanec)
 - magento/magento2#18650: issue fixed -Wrong order total in customer information orders tab in admin panel (by @anujwebkul)
 - magento/magento2#18938: issue #18931 fixed. (by @ayazwebkul)
 - magento/magento2#18968: Fix numeric translation keys being dissolved by array_merge (by @tdgroot)
 - magento/magento2#18680: fix: cache count() results for loops (by @DanielRuf)
 - magento-engcom#142: Added $websiteString property to test class (by @maxalmonte14)
 - magento/magento2#18810: magento-engcom#51: fix for uploader filepath (by @sawebvisum)
 - magento/magento2#18083: Convert string to DateTime object for languages other than English (by @bnymn)
 - magento/magento2#18462: [forwardport 2.3] fix Fatal Error when save configurable product in Magento 2.2.5 #18082 #18461 (by @thiagolima-bm)


Fixed GitHub Issues:
 - magento/magento2#19060: User created by admin cannot login (reported by @tomekjordan) has been fixed in magento/magento2#19066 by @progreg in 2.3-develop branch
   Related commits:
     1. ed66491

 - magento/magento2#18256: Reset password throws error since 2.2.6 (reported by @edwinbos) has been fixed in magento/magento2#19026 by @p-bystritsky in 2.3-develop branch
   Related commits:
     1. bc8d3d5

 - magento/magento2#18323: Order confirmation email for guest checkout does not include download links (reported by @hsray) has been fixed in magento/magento2#19040 by @swnsma in 2.3-develop branch
   Related commits:
     1. 5dc7add
     2. e19d70e

 - magento/magento2#19003: salesInvoiceOrder REST API does not make downloadable products available (reported by @nthurston) has been fixed in magento/magento2#19040 by @swnsma in 2.3-develop branch
   Related commits:
     1. 5dc7add
     2. e19d70e

 - magento/magento2#19034: sales_order_item_save_commit_after and sales_order_save_commit_after events will never fire for guest checkout (reported by @swnsma) has been fixed in magento/magento2#19040 by @swnsma in 2.3-develop branch
   Related commits:
     1. 5dc7add
     2. e19d70e

 - magento/magento2#10048: WYSIWYG unable to set default value in ui component (reported by @milansimek) has been fixed in magento/magento2#19048 by @omiroshnichenko in 2.3-develop branch
   Related commits:
     1. 70743fa

 - magento/magento2#18901: Forgot password form should not available while customer is logged in. (reported by @webkul-ratnesh) has been fixed in magento/magento2#19029 by @agorbulin in 2.3-develop branch
   Related commits:
     1. 76d478f

 - magento/magento2#18562: Internet Explorer 11: Edit customer in backend leads sometimes to a "loading circle" and error object does not support method "includes" (reported by @amenk) has been fixed in magento/magento2#19010 by @omiroshnichenko in 2.3-develop branch
   Related commits:
     1. ed26e55

 - magento/magento2#10440: Missing $debugHintsPath when sending email via command (reported by @cykirsch) has been fixed in magento/magento2#18991 by @p-bystritsky in 2.3-develop branch
   Related commits:
     1. 7c86822

 - magento/magento2#17890: Magento 2.2.5 Product swatches does not shows correct value for related store view (reported by @magicaner) has been fixed in magento/magento2#18988 by @nmalevanec in 2.3-develop branch
   Related commits:
     1. f359bbc

 - magento/magento2#18618: Wrong order total in customer information orders tab in admin panel (reported by @LordHansolo) has been fixed in magento/magento2#18650 by @anujwebkul in 2.3-develop branch
   Related commits:
     1. 11290c5

 - magento/magento2#18931: Product added to shopping cart / comparison list message not translated by default (reported by @arnoudhgz) has been fixed in magento/magento2#18938 by @ayazwebkul in 2.3-develop branch
   Related commits:
     1. 4c25f0e
     2. d64351b

 - magento/magento2#5037: Datetime Error on Newsletter Template (reported by @davideperrotta) has been fixed in magento/magento2#18083 by @bnymn in 2.3-develop branch
   Related commits:
     1. ae42612
     2. c4fa85b
     3. 6bda779
     4. a4f80a9
     5. 14d9528
     6. da580fc
     7. 16a7f0b
     8. 9315dd6
     9. 42cd228
     10. ddeaf36
     11. 6cc9034
     12. 28617c0
     13. fd0ab03
     14. 1b03c19
     15. c6c2ffe
     16. 502e5ac
     17. 51e8fe7
     18. a8c7768
     19. 127b1b8
     20. 526bfc9
     21. edc962d
     22. 4fe8c7a
     23. e27de55
     24. 0d0c210

 - magento/magento2#18082: Fatal Error when save configurable product in Magento 2.2.5 (reported by @vpatidar009) has been fixed in magento/magento2#18462 by @thiagolima-bm in 2.3-develop branch
   Related commits:
     1. cc16df9
     2. 7711165
  • Loading branch information
Stanislav Idolov authored Nov 6, 2018
2 parents 53a8966 + 67bc162 commit 9186f4a
Show file tree
Hide file tree
Showing 37 changed files with 245 additions and 94 deletions.
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
4 changes: 2 additions & 2 deletions app/code/Magento/Catalog/i18n/en_US.csv
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,6 @@ Products,Products
"This attribute set no longer exists.","This attribute set no longer exists."
"You saved the attribute set.","You saved the attribute set."
"Something went wrong while saving the attribute set.","Something went wrong while saving the attribute set."
"You added product %1 to the comparison list.","You added product %1 to the comparison list."
"You cleared the comparison list.","You cleared the comparison list."
"Something went wrong clearing the comparison list.","Something went wrong clearing the comparison list."
"You removed product %1 from the comparison list.","You removed product %1 from the comparison list."
Expand Down Expand Up @@ -808,4 +807,5 @@ Details,Details
"Product Name or SKU", "Product Name or SKU"
"Start typing to find products", "Start typing to find products"
"Product with ID: (%1) doesn't exist", "Product with ID: (%1) doesn't exist"
"Category with ID: (%1) doesn't exist", "Category with ID: (%1) doesn't exist"
"Category with ID: (%1) doesn't exist", "Category with ID: (%1) doesn't exist"
"You added product %1 to the <a href=""%2"">comparison list</a>.","You added product %1 to the <a href=""%2"">comparison list</a>."
10 changes: 5 additions & 5 deletions app/code/Magento/CatalogImportExport/Model/Import/Uploader.php
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ class Uploader extends \Magento\MediaStorage\Model\File\Uploader
* @param \Magento\MediaStorage\Model\File\Validator\NotProtectedExtension $validator
* @param \Magento\Framework\Filesystem $filesystem
* @param \Magento\Framework\Filesystem\File\ReadFactory $readFactory
* @param null $filePath
* @param null|string $filePath
* @throws \Magento\Framework\Exception\LocalizedException
*/
public function __construct(
Expand All @@ -113,15 +113,15 @@ public function __construct(
\Magento\Framework\Filesystem\File\ReadFactory $readFactory,
$filePath = null
) {
if ($filePath !== null) {
$this->_setUploadFile($filePath);
}
$this->_imageFactory = $imageFactory;
$this->_coreFileStorageDb = $coreFileStorageDb;
$this->_coreFileStorage = $coreFileStorage;
$this->_validator = $validator;
$this->_directory = $filesystem->getDirectoryWrite(DirectoryList::ROOT);
$this->_readFactory = $readFactory;
if ($filePath !== null) {
$this->_setUploadFile($filePath);
}
}

/**
Expand Down Expand Up @@ -353,7 +353,7 @@ protected function _moveFile($tmpPath, $destPath)
}

/**
* {@inheritdoc}
* @inheritdoc
*/
protected function chmod($file)
{
Expand Down
1 change: 1 addition & 0 deletions app/code/Magento/Checkout/i18n/en_US.csv
Original file line number Diff line number Diff line change
Expand Up @@ -182,3 +182,4 @@ Payment,Payment
"Items in Cart","Items in Cart"
"Close","Close"
"Show Cross-sell Items in the Shopping Cart","Show Cross-sell Items in the Shopping Cart"
"You added %1 to your <a href=""%2"">shopping cart</a>.","You added %1 to your <a href=""%2"">shopping cart</a>."
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ protected function getVariationMatrix()
$configurableMatrix = json_decode($configurableMatrix, true);

foreach ($configurableMatrix as $item) {
if ($item['newProduct']) {
if (isset($item['newProduct']) && $item['newProduct']) {
$result[$item['variationKey']] = $this->mapData($item);

if (isset($item['qty'])) {
Expand Down
9 changes: 5 additions & 4 deletions app/code/Magento/Customer/Block/Adminhtml/Edit/Tab/Orders.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public function __construct(
}

/**
* {@inheritdoc}
* @inheritdoc
*/
protected function _construct()
{
Expand Down Expand Up @@ -102,7 +102,7 @@ protected function _prepareCollection()
}

/**
* {@inheritdoc}
* @inheritdoc
*/
protected function _prepareColumns()
{
Expand All @@ -123,7 +123,8 @@ protected function _prepareColumns()
'header' => __('Order Total'),
'index' => 'grand_total',
'type' => 'currency',
'currency' => 'order_currency_code'
'currency' => 'order_currency_code',
'rate' => 1
]
);

Expand Down Expand Up @@ -162,7 +163,7 @@ public function getRowUrl($row)
}

/**
* {@inheritdoc}
* @inheritdoc
*/
public function getGridUrl()
{
Expand Down
13 changes: 11 additions & 2 deletions app/code/Magento/Customer/Controller/Account/ForgotPassword.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<?php
/**
*
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
Expand All @@ -11,6 +10,9 @@
use Magento\Framework\App\Action\Context;
use Magento\Framework\View\Result\PageFactory;

/**
* Forgot Password controller
*/
class ForgotPassword extends \Magento\Customer\Controller\AbstractAccount implements HttpGetActionInterface
{
/**
Expand Down Expand Up @@ -41,10 +43,17 @@ public function __construct(
/**
* Forgot customer password page
*
* @return \Magento\Framework\View\Result\Page
* @return \Magento\Framework\Controller\Result\Redirect|\Magento\Framework\View\Result\Page
*/
public function execute()
{
if ($this->session->isLoggedIn()) {
/** @var \Magento\Framework\Controller\Result\Redirect $resultRedirect */
$resultRedirect = $this->resultRedirectFactory->create();
$resultRedirect->setPath('*/*/');
return $resultRedirect;
}

/** @var \Magento\Framework\View\Result\Page $resultPage */
$resultPage = $this->resultPageFactory->create();
$resultPage->getLayout()->getBlock('forgotPassword')->setEmailValue($this->session->getForgottenEmail());
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Customer/Model/AccountManagement.php
Original file line number Diff line number Diff line change
Expand Up @@ -681,8 +681,8 @@ public function resetPassword($email, $resetToken, $newPassword)
$customerSecure->setRpToken(null);
$customerSecure->setRpTokenCreatedAt(null);
$customerSecure->setPasswordHash($this->createPasswordHash($newPassword));
$this->sessionManager->destroy();
$this->destroyCustomerSessions($customer->getId());
$this->sessionManager->destroy();
$this->customerRepository->save($customer);

return true;
Expand Down
10 changes: 5 additions & 5 deletions app/code/Magento/Customer/Model/Authentication.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public function __construct(
}

/**
* {@inheritdoc}
* @inheritdoc
*/
public function processAuthenticationFailure($customerId)
{
Expand Down Expand Up @@ -120,7 +120,7 @@ public function processAuthenticationFailure($customerId)
}

/**
* {@inheritdoc}
* @inheritdoc
*/
public function unlock($customerId)
{
Expand Down Expand Up @@ -152,7 +152,7 @@ protected function getMaxFailures()
}

/**
* {@inheritdoc}
* @inheritdoc
*/
public function isLocked($customerId)
{
Expand All @@ -161,13 +161,13 @@ public function isLocked($customerId)
}

/**
* {@inheritdoc}
* @inheritdoc
*/
public function authenticate($customerId, $password)
{
$customerSecure = $this->customerRegistry->retrieveSecureData($customerId);
$hash = $customerSecure->getPasswordHash();
if (!$this->encryptor->validateHash($password, $hash)) {
if (!$hash || !$this->encryptor->validateHash($password, $hash)) {
$this->processAuthenticationFailure($customerId);
if ($this->isLocked($customerId)) {
throw new UserLockedException(__('The account is locked.'));
Expand Down
8 changes: 8 additions & 0 deletions app/code/Magento/Developer/etc/di.xml
Original file line number Diff line number Diff line change
Expand Up @@ -240,4 +240,12 @@
</argument>
</arguments>
</type>

<type name="Magento\Developer\Model\TemplateEngine\Plugin\DebugHints">
<arguments>
<argument name="debugHintsPath" xsi:type="string">dev/debug/template_hints_storefront</argument>
<argument name="debugHintsWithParam" xsi:type="string">dev/debug/template_hints_storefront_show_with_parameter</argument>
<argument name="debugHintsParameter" xsi:type="string">dev/debug/template_hints_parameter_value</argument>
</arguments>
</type>
</config>
7 changes: 0 additions & 7 deletions app/code/Magento/Developer/etc/frontend/di.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,4 @@
<type name="Magento\Framework\View\TemplateEngineFactory">
<plugin name="debug_hints" type="Magento\Developer\Model\TemplateEngine\Plugin\DebugHints" sortOrder="10"/>
</type>
<type name="Magento\Developer\Model\TemplateEngine\Plugin\DebugHints">
<arguments>
<argument name="debugHintsPath" xsi:type="string">dev/debug/template_hints_storefront</argument>
<argument name="debugHintsWithParam" xsi:type="string">dev/debug/template_hints_storefront_show_with_parameter</argument>
<argument name="debugHintsParameter" xsi:type="string">dev/debug/template_hints_parameter_value</argument>
</arguments>
</type>
</config>
4 changes: 2 additions & 2 deletions app/code/Magento/Downloadable/etc/events.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
*/
-->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Event/etc/events.xsd">
<event name="sales_order_item_save_commit_after">
<event name="sales_order_item_save_after">
<observer name="downloadable_observer" instance="Magento\Downloadable\Observer\SaveDownloadableOrderItemObserver" />
</event>
<event name="sales_order_save_commit_after">
<event name="sales_order_save_after">
<observer name="downloadable_observer" instance="Magento\Downloadable\Observer\SetLinkStatusObserver" />
</event>
<event name="sales_model_service_quote_submit_success">
Expand Down
19 changes: 14 additions & 5 deletions app/code/Magento/Newsletter/Model/Queue.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

use Magento\Framework\App\TemplateTypesInterface;
use Magento\Framework\Stdlib\DateTime\TimezoneInterface;
use Magento\Framework\Stdlib\DateTime\Timezone\LocalizedDateToUtcConverterInterface;

/**
* Newsletter queue model.
Expand Down Expand Up @@ -117,6 +118,11 @@ class Queue extends \Magento\Framework\Model\AbstractModel implements TemplateTy
*/
private $timezone;

/**
* @var LocalizedDateToUtcConverterInterface
*/
private $utcConverter;

/**
* @param \Magento\Framework\Model\Context $context
* @param \Magento\Framework\Registry $registry
Expand All @@ -130,6 +136,7 @@ class Queue extends \Magento\Framework\Model\AbstractModel implements TemplateTy
* @param \Magento\Framework\Data\Collection\AbstractDb $resourceCollection
* @param array $data
* @param TimezoneInterface $timezone
* @param LocalizedDateToUtcConverterInterface $utcConverter
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
public function __construct(
Expand All @@ -144,7 +151,8 @@ public function __construct(
\Magento\Framework\Model\ResourceModel\AbstractResource $resource = null,
\Magento\Framework\Data\Collection\AbstractDb $resourceCollection = null,
array $data = [],
TimezoneInterface $timezone = null
TimezoneInterface $timezone = null,
LocalizedDateToUtcConverterInterface $utcConverter = null
) {
parent::__construct(
$context,
Expand All @@ -159,9 +167,10 @@ public function __construct(
$this->_problemFactory = $problemFactory;
$this->_subscribersCollection = $subscriberCollectionFactory->create();
$this->_transportBuilder = $transportBuilder;
$this->timezone = $timezone ?: \Magento\Framework\App\ObjectManager::getInstance()->get(
TimezoneInterface::class
);

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->timezone = $timezone ?: $objectManager->get(TimezoneInterface::class);
$this->utcConverter = $utcConverter ?? $objectManager->get(LocalizedDateToUtcConverterInterface::class);
}

/**
Expand Down Expand Up @@ -196,7 +205,7 @@ public function setQueueStartAtByString($startAt)
if ($startAt === null || $startAt == '') {
$this->setQueueStartAt(null);
} else {
$this->setQueueStartAt($this->timezone->convertConfigTimeToUtc($startAt));
$this->setQueueStartAt($this->utcConverter->convertLocalizedDateToUtc($startAt));
}
return $this;
}
Expand Down
7 changes: 4 additions & 3 deletions app/code/Magento/Newsletter/i18n/en_US.csv
Original file line number Diff line number Diff line change
Expand Up @@ -67,16 +67,16 @@ Subscribers,Subscribers
"Something went wrong while saving this template.","Something went wrong while saving this template."
"Newsletter Subscription","Newsletter Subscription"
"Something went wrong while saving your subscription.","Something went wrong while saving your subscription."
"We saved the subscription.","We saved the subscription."
"We removed the subscription.","We removed the subscription."
"We have saved your subscription.","We have saved your subscription."
"We have removed your newsletter subscription.","We have removed your newsletter subscription."
"Your subscription has been confirmed.","Your subscription has been confirmed."
"This is an invalid subscription confirmation code.","This is an invalid subscription confirmation code."
"This is an invalid subscription ID.","This is an invalid subscription ID."
"This email address is already assigned to another user.","This email address is already assigned to another user."
"Sorry, but the administrator denied subscription for guests. Please <a href=""%1"">register</a>.","Sorry, but the administrator denied subscription for guests. Please <a href=""%1"">register</a>."
"Please enter a valid email address.","Please enter a valid email address."
"This email address is already subscribed.","This email address is already subscribed."
"The confirmation request has been sent.","The confirmation request has been sent."
"A confirmation request has been sent.","A confirmation request has been sent."
"Thank you for your subscription.","Thank you for your subscription."
"There was a problem with the subscription: %1","There was a problem with the subscription: %1"
"Something went wrong with the subscription.","Something went wrong with the subscription."
Expand Down Expand Up @@ -151,3 +151,4 @@ Unconfirmed,Unconfirmed
Store,Store
"Store View","Store View"
"Newsletter Subscriptions","Newsletter Subscriptions"
"We have updated your subscription.","We have updated your subscription."
Loading

0 comments on commit 9186f4a

Please sign in to comment.