forked from magento/magento2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🔃 [Magento Community Engineering] Community Contributions - 2.3-develop
Accepted Community Pull Requests: - magento#24447: magento/magento2#: Incorrect annotation in the Magento/Framework/MessageQueue/etc/queue.xsd schema (by @atwixfirster) - magento#24434: [Integration] Adding the integration callback url validation (by @eduard13) - magento#24437: [EncryptionKey] Fixing the encryption key switching field (by @eduard13) - magento#24397: Resolve "New Block" form still show "Store View" field in "Single Store Mode" issue24387 (by @edenduong) - magento#24336: magento#2228; Encode xml entities in tag attributes (by @sergey-solo) - magento#24093: Move WYSIWYG adapter to adminhtml theme Ui module (by @sankalpshekhar) - magento#24358: Add number validation for sitemap file limits (by @ravi-chandra3197) - magento#24282: Resolve undefined variable when call getPdf() in app/code/Magento/Sales/Model/Order/Pdf/Creditmemo.php (by @edenduong) Fixed GitHub Issues: - magento#24436: Autogenerating encryption key requires manually entering the key (reported by @eduard13) has been fixed in magento#24437 by @eduard13 in 2.3-develop branch Related commits: 1. c413b69 - magento#24387: "New Block" form still show "Store View" field in "Single Store Mode" (reported by @edenduong) has been fixed in magento#24397 by @edenduong in 2.3-develop branch Related commits: 1. 24c022e 2. aaa7379 - magento#2228: Problem with adding google fonts with ampersand into default_head_blocks.xml (reported by @luckyraul) has been fixed in magento#24336 by @sergey-solo in 2.3-develop branch Related commits: 1. de8028e 2. 781e7bb 3. ada83e4 4. 5eaef76
- Loading branch information
Showing
12 changed files
with
144 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
61 changes: 61 additions & 0 deletions
61
app/code/Magento/Store/Ui/Component/Form/Field/StoreView.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
<?php | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
declare(strict_types=1); | ||
|
||
namespace Magento\Store\Ui\Component\Form\Field; | ||
|
||
use Magento\Framework\View\Element\UiComponent\ContextInterface; | ||
use Magento\Framework\View\Element\UiComponentFactory; | ||
use Magento\Store\Model\StoreManagerInterface as StoreManager; | ||
use Magento\Ui\Component\Form\Field; | ||
|
||
/** | ||
* Check to disable store view field | ||
* | ||
* Class \Magento\Store\Ui\Component\Form\Field\StoreView | ||
*/ | ||
class StoreView extends Field | ||
{ | ||
/** | ||
* Store manager | ||
* | ||
* @var StoreManager | ||
*/ | ||
private $storeManager; | ||
|
||
/** | ||
* StoreView constructor. | ||
* | ||
* @param ContextInterface $context | ||
* @param UiComponentFactory $uiComponentFactory | ||
* @param StoreManager $storeManager | ||
* @param array $components | ||
* @param array $data | ||
*/ | ||
public function __construct( | ||
ContextInterface $context, | ||
UiComponentFactory $uiComponentFactory, | ||
StoreManager $storeManager, | ||
array $components = [], | ||
array $data = [] | ||
) { | ||
parent::__construct($context, $uiComponentFactory, $components, $data); | ||
$this->storeManager = $storeManager; | ||
} | ||
|
||
/** | ||
* Prepare component configuration | ||
* | ||
* @return void | ||
*/ | ||
public function prepare() | ||
{ | ||
parent::prepare(); | ||
if ($this->storeManager->isSingleStoreMode()) { | ||
$this->_data['config']['componentDisabled'] = true; | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
...ional/tests/app/Magento/Integration/Test/Constraint/AssertUrlValidationErrorGenerated.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
<?php | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
|
||
namespace Magento\Integration\Test\Constraint; | ||
|
||
use Magento\Integration\Test\Page\Adminhtml\IntegrationNew; | ||
use Magento\Integration\Test\Fixture\Integration; | ||
use Magento\Mtf\Constraint\AbstractConstraint; | ||
use PHPUnit\Framework\Assert; | ||
|
||
/** | ||
* Assert validation error generated when saving integration with invalid callback url. | ||
*/ | ||
class AssertUrlValidationErrorGenerated extends AbstractConstraint | ||
{ | ||
/** | ||
* Assert validation error generated when saving integration with invalid email. | ||
* | ||
* @param IntegrationNew $integrationNew | ||
* @param Integration $integration | ||
* @return void | ||
*/ | ||
public function processAssert( | ||
IntegrationNew $integrationNew, | ||
Integration $integration | ||
) { | ||
$errors = $integrationNew->getIntegrationForm()->getJsErrors("integration_info"); | ||
$urlJsError = false; | ||
foreach ($errors as $error) { | ||
if (strpos($error, 'Please enter a valid URL.') !== false) { | ||
$urlJsError = true; | ||
break; | ||
} | ||
} | ||
Assert::assertTrue( | ||
$urlJsError, | ||
'Failed to validate callback url (' . $integration->getEndpoint() . ') when saving integration.' | ||
); | ||
} | ||
|
||
/** | ||
* Returns a string representation of successful assertion. | ||
* | ||
* @return string | ||
*/ | ||
public function toString() | ||
{ | ||
return 'Callback url is properly validated when saving integration.'; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters