From 36335422453af4abf58859acba7224cabe0f5e43 Mon Sep 17 00:00:00 2001 From: Shankar Konar Date: Fri, 7 Aug 2020 11:09:39 +0530 Subject: [PATCH 1/7] Media Gallery configuration are reversed --- .../SaveBaseCategoryImageInformation.php | 2 +- .../Model/OpenDialogUrlProvider.php | 2 +- .../Plugin/SaveImageInformation.php | 2 +- .../Model/ImageComponentOpenDialogUrlTest.php | 4 ++-- .../Model/OpenDialogUrlProviderTest.php | 4 ++-- .../Model/TinyMceOpenDialogUrlTest.php | 4 ++-- .../WysiwygDefaultConfigOpenDialogUrlTest.php | 4 ++-- .../Plugin/MediaGallerySyncTrigger.php | 2 +- .../Test/Mftf/Data/AdobeStockConfigData.xml | 4 ++-- .../MediaGalleryUi/etc/adminhtml/menu.xml | 18 ++++++++++++++++-- .../MediaGalleryUi/etc/adminhtml/system.xml | 4 ++-- 11 files changed, 32 insertions(+), 18 deletions(-) diff --git a/app/code/Magento/MediaGalleryCatalogIntegration/Plugin/SaveBaseCategoryImageInformation.php b/app/code/Magento/MediaGalleryCatalogIntegration/Plugin/SaveBaseCategoryImageInformation.php index d439b53c120cb..67a99bfaa84c2 100644 --- a/app/code/Magento/MediaGalleryCatalogIntegration/Plugin/SaveBaseCategoryImageInformation.php +++ b/app/code/Magento/MediaGalleryCatalogIntegration/Plugin/SaveBaseCategoryImageInformation.php @@ -86,7 +86,7 @@ public function __construct( */ public function afterMoveFileFromTmp(ImageUploader $subject, string $imagePath): string { - if (!$this->config->isEnabled()) { + if ($this->config->isEnabled()) { return $imagePath; } diff --git a/app/code/Magento/MediaGalleryIntegration/Model/OpenDialogUrlProvider.php b/app/code/Magento/MediaGalleryIntegration/Model/OpenDialogUrlProvider.php index 317b811df5692..3834550f2703e 100644 --- a/app/code/Magento/MediaGalleryIntegration/Model/OpenDialogUrlProvider.php +++ b/app/code/Magento/MediaGalleryIntegration/Model/OpenDialogUrlProvider.php @@ -35,6 +35,6 @@ public function __construct(ConfigInterface $config) */ public function getUrl(): string { - return $this->config->isEnabled() ? 'media_gallery/index/index' : 'cms/wysiwyg_images/index'; + return $this->config->isEnabled() ? 'cms/wysiwyg_images/index' : 'media_gallery/index/index'; } } diff --git a/app/code/Magento/MediaGalleryIntegration/Plugin/SaveImageInformation.php b/app/code/Magento/MediaGalleryIntegration/Plugin/SaveImageInformation.php index fbe35db298b04..4d0e6200ddaad 100644 --- a/app/code/Magento/MediaGalleryIntegration/Plugin/SaveImageInformation.php +++ b/app/code/Magento/MediaGalleryIntegration/Plugin/SaveImageInformation.php @@ -78,7 +78,7 @@ public function __construct( */ public function afterSave(Uploader $subject, array $result): array { - if (!$this->config->isEnabled()) { + if ($this->config->isEnabled()) { return $result; } diff --git a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/ImageComponentOpenDialogUrlTest.php b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/ImageComponentOpenDialogUrlTest.php index dfeaa3eff56bd..0e5cd070a7eec 100644 --- a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/ImageComponentOpenDialogUrlTest.php +++ b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/ImageComponentOpenDialogUrlTest.php @@ -50,7 +50,7 @@ protected function setUp(): void /** * Test image open dialog url when enhanced media gallery not enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 0 + * @magentoConfigFixture default/system/media_gallery/enabled 1 */ public function testWithEnhancedMediaGalleryDisabled(): void { @@ -61,7 +61,7 @@ public function testWithEnhancedMediaGalleryDisabled(): void /** * Test image open dialog url when enhanced media gallery enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 1 + * @magentoConfigFixture default/system/media_gallery/enabled 0 */ public function testWithEnhancedMediaGalleryEnabled(): void { diff --git a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/OpenDialogUrlProviderTest.php b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/OpenDialogUrlProviderTest.php index 7a3316f293879..3973ed132b490 100644 --- a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/OpenDialogUrlProviderTest.php +++ b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/OpenDialogUrlProviderTest.php @@ -45,7 +45,7 @@ protected function setUp(): void /** * Test getting open dialog url with enhanced media gallery disabled. - * @magentoConfigFixture default/system/media_gallery/enabled 0 + * @magentoConfigFixture default/system/media_gallery/enabled 1 */ public function testWithEnhancedMediaGalleryDisabled(): void { @@ -54,7 +54,7 @@ public function testWithEnhancedMediaGalleryDisabled(): void /** * Test getting open dialog url when enhanced media gallery enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 1 + * @magentoConfigFixture default/system/media_gallery/enabled 0 */ public function testWithEnhancedMediaGalleryEnabled(): void { diff --git a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/TinyMceOpenDialogUrlTest.php b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/TinyMceOpenDialogUrlTest.php index 81a4dc642cfa0..c15536f6af445 100644 --- a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/TinyMceOpenDialogUrlTest.php +++ b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/TinyMceOpenDialogUrlTest.php @@ -58,7 +58,7 @@ protected function setUp(): void /** * Test image open dialog url when enhanced media gallery not enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 0 + * @magentoConfigFixture default/system/media_gallery/enabled 1 */ public function testWithEnhancedMediaGalleryDisabled(): void { @@ -68,7 +68,7 @@ public function testWithEnhancedMediaGalleryDisabled(): void /** * Test image open dialog url when enhanced media gallery enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 1 + * @magentoConfigFixture default/system/media_gallery/enabled 0 */ public function testWithEnhancedMediaGalleryEnabled(): void { diff --git a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/WysiwygDefaultConfigOpenDialogUrlTest.php b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/WysiwygDefaultConfigOpenDialogUrlTest.php index aebf5927869d5..df6cbe4fc2c09 100644 --- a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/WysiwygDefaultConfigOpenDialogUrlTest.php +++ b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/WysiwygDefaultConfigOpenDialogUrlTest.php @@ -58,7 +58,7 @@ protected function setUp(): void /** * Test update wysiwyg editor open dialog url when enhanced media gallery not enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 0 + * @magentoConfigFixture default/system/media_gallery/enabled 1 */ public function testWithEnhancedMediaGalleryDisabled(): void { @@ -70,7 +70,7 @@ public function testWithEnhancedMediaGalleryDisabled(): void /** * Test update wysiwyg editor open dialog url when enhanced media gallery enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 1 + * @magentoConfigFixture default/system/media_gallery/enabled 0 */ public function testWithEnhancedMediaGalleryEnabled(): void { diff --git a/app/code/Magento/MediaGallerySynchronization/Plugin/MediaGallerySyncTrigger.php b/app/code/Magento/MediaGallerySynchronization/Plugin/MediaGallerySyncTrigger.php index 9583c91184d1a..dfe007fa59add 100644 --- a/app/code/Magento/MediaGallerySynchronization/Plugin/MediaGallerySyncTrigger.php +++ b/app/code/Magento/MediaGallerySynchronization/Plugin/MediaGallerySyncTrigger.php @@ -43,7 +43,7 @@ public function afterSave(Value $config, Value $result): Value { if ($result->getPath() === self::MEDIA_GALLERY_CONFIG_VALUE && $result->isValueChanged() - && (int) $result->getValue() === self::MEDIA_GALLERY_ENABLED_VALUE + && (int) $result->getValue() !== self::MEDIA_GALLERY_ENABLED_VALUE ) { $this->publish->execute(); } diff --git a/app/code/Magento/MediaGalleryUi/Test/Mftf/Data/AdobeStockConfigData.xml b/app/code/Magento/MediaGalleryUi/Test/Mftf/Data/AdobeStockConfigData.xml index e8f394a006104..5e02d81fb82ae 100644 --- a/app/code/Magento/MediaGalleryUi/Test/Mftf/Data/AdobeStockConfigData.xml +++ b/app/code/Magento/MediaGalleryUi/Test/Mftf/Data/AdobeStockConfigData.xml @@ -9,10 +9,10 @@ xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd"> system/media_gallery/enabled - 1 + 0 system/media_gallery/enabled - 0 + 1 diff --git a/app/code/Magento/MediaGalleryUi/etc/adminhtml/menu.xml b/app/code/Magento/MediaGalleryUi/etc/adminhtml/menu.xml index 92839aa75ac8b..e7486ccbf5a2f 100644 --- a/app/code/Magento/MediaGalleryUi/etc/adminhtml/menu.xml +++ b/app/code/Magento/MediaGalleryUi/etc/adminhtml/menu.xml @@ -7,7 +7,21 @@ --> - - + + diff --git a/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml b/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml index 77544b42e899a..1c303ab155dae 100644 --- a/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml +++ b/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml @@ -9,9 +9,9 @@
- + - + Magento\Config\Model\Config\Source\Yesno system/media_gallery/enabled From 651bd690cb0687565cc2a1e99a57d99be5e8f14c Mon Sep 17 00:00:00 2001 From: Shankar Konar Date: Fri, 7 Aug 2020 13:49:35 +0530 Subject: [PATCH 2/7] fixed MFTF test --- .../MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/code/Magento/MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml b/app/code/Magento/MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml index 4749fc4a885b0..14464cf36234c 100644 --- a/app/code/Magento/MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml +++ b/app/code/Magento/MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml @@ -13,7 +13,7 @@ - + From 8b592ee2005c4c324672b0b3f1f69307384c43c5 Mon Sep 17 00:00:00 2001 From: Shankar Konar Date: Fri, 7 Aug 2020 17:02:14 +0530 Subject: [PATCH 3/7] Enabled old media gallery by default --- app/code/Magento/MediaGalleryUi/etc/config.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/code/Magento/MediaGalleryUi/etc/config.xml b/app/code/Magento/MediaGalleryUi/etc/config.xml index fe8e73c406e59..593b1b8e58fd2 100644 --- a/app/code/Magento/MediaGalleryUi/etc/config.xml +++ b/app/code/Magento/MediaGalleryUi/etc/config.xml @@ -9,7 +9,7 @@ - 0 + 1 From 3fc230358a246780d2595b6b2606b7b355af0665 Mon Sep 17 00:00:00 2001 From: Shankar Konar Date: Fri, 14 Aug 2020 13:42:22 +0530 Subject: [PATCH 4/7] Revert "Media Gallery configuration are reversed" This reverts commit 36335422453af4abf58859acba7224cabe0f5e43. --- .../SaveBaseCategoryImageInformation.php | 2 +- .../Model/OpenDialogUrlProvider.php | 2 +- .../Plugin/SaveImageInformation.php | 2 +- .../Model/ImageComponentOpenDialogUrlTest.php | 4 ++-- .../Model/OpenDialogUrlProviderTest.php | 4 ++-- .../Model/TinyMceOpenDialogUrlTest.php | 4 ++-- .../WysiwygDefaultConfigOpenDialogUrlTest.php | 4 ++-- .../Plugin/MediaGallerySyncTrigger.php | 2 +- .../Test/Mftf/Data/AdobeStockConfigData.xml | 4 ++-- .../MediaGalleryUi/etc/adminhtml/menu.xml | 18 ++---------------- .../MediaGalleryUi/etc/adminhtml/system.xml | 4 ++-- 11 files changed, 18 insertions(+), 32 deletions(-) diff --git a/app/code/Magento/MediaGalleryCatalogIntegration/Plugin/SaveBaseCategoryImageInformation.php b/app/code/Magento/MediaGalleryCatalogIntegration/Plugin/SaveBaseCategoryImageInformation.php index 67a99bfaa84c2..d439b53c120cb 100644 --- a/app/code/Magento/MediaGalleryCatalogIntegration/Plugin/SaveBaseCategoryImageInformation.php +++ b/app/code/Magento/MediaGalleryCatalogIntegration/Plugin/SaveBaseCategoryImageInformation.php @@ -86,7 +86,7 @@ public function __construct( */ public function afterMoveFileFromTmp(ImageUploader $subject, string $imagePath): string { - if ($this->config->isEnabled()) { + if (!$this->config->isEnabled()) { return $imagePath; } diff --git a/app/code/Magento/MediaGalleryIntegration/Model/OpenDialogUrlProvider.php b/app/code/Magento/MediaGalleryIntegration/Model/OpenDialogUrlProvider.php index 3834550f2703e..317b811df5692 100644 --- a/app/code/Magento/MediaGalleryIntegration/Model/OpenDialogUrlProvider.php +++ b/app/code/Magento/MediaGalleryIntegration/Model/OpenDialogUrlProvider.php @@ -35,6 +35,6 @@ public function __construct(ConfigInterface $config) */ public function getUrl(): string { - return $this->config->isEnabled() ? 'cms/wysiwyg_images/index' : 'media_gallery/index/index'; + return $this->config->isEnabled() ? 'media_gallery/index/index' : 'cms/wysiwyg_images/index'; } } diff --git a/app/code/Magento/MediaGalleryIntegration/Plugin/SaveImageInformation.php b/app/code/Magento/MediaGalleryIntegration/Plugin/SaveImageInformation.php index 4d0e6200ddaad..fbe35db298b04 100644 --- a/app/code/Magento/MediaGalleryIntegration/Plugin/SaveImageInformation.php +++ b/app/code/Magento/MediaGalleryIntegration/Plugin/SaveImageInformation.php @@ -78,7 +78,7 @@ public function __construct( */ public function afterSave(Uploader $subject, array $result): array { - if ($this->config->isEnabled()) { + if (!$this->config->isEnabled()) { return $result; } diff --git a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/ImageComponentOpenDialogUrlTest.php b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/ImageComponentOpenDialogUrlTest.php index 0e5cd070a7eec..dfeaa3eff56bd 100644 --- a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/ImageComponentOpenDialogUrlTest.php +++ b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/ImageComponentOpenDialogUrlTest.php @@ -50,7 +50,7 @@ protected function setUp(): void /** * Test image open dialog url when enhanced media gallery not enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 1 + * @magentoConfigFixture default/system/media_gallery/enabled 0 */ public function testWithEnhancedMediaGalleryDisabled(): void { @@ -61,7 +61,7 @@ public function testWithEnhancedMediaGalleryDisabled(): void /** * Test image open dialog url when enhanced media gallery enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 0 + * @magentoConfigFixture default/system/media_gallery/enabled 1 */ public function testWithEnhancedMediaGalleryEnabled(): void { diff --git a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/OpenDialogUrlProviderTest.php b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/OpenDialogUrlProviderTest.php index 3973ed132b490..7a3316f293879 100644 --- a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/OpenDialogUrlProviderTest.php +++ b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/OpenDialogUrlProviderTest.php @@ -45,7 +45,7 @@ protected function setUp(): void /** * Test getting open dialog url with enhanced media gallery disabled. - * @magentoConfigFixture default/system/media_gallery/enabled 1 + * @magentoConfigFixture default/system/media_gallery/enabled 0 */ public function testWithEnhancedMediaGalleryDisabled(): void { @@ -54,7 +54,7 @@ public function testWithEnhancedMediaGalleryDisabled(): void /** * Test getting open dialog url when enhanced media gallery enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 0 + * @magentoConfigFixture default/system/media_gallery/enabled 1 */ public function testWithEnhancedMediaGalleryEnabled(): void { diff --git a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/TinyMceOpenDialogUrlTest.php b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/TinyMceOpenDialogUrlTest.php index c15536f6af445..81a4dc642cfa0 100644 --- a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/TinyMceOpenDialogUrlTest.php +++ b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/TinyMceOpenDialogUrlTest.php @@ -58,7 +58,7 @@ protected function setUp(): void /** * Test image open dialog url when enhanced media gallery not enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 1 + * @magentoConfigFixture default/system/media_gallery/enabled 0 */ public function testWithEnhancedMediaGalleryDisabled(): void { @@ -68,7 +68,7 @@ public function testWithEnhancedMediaGalleryDisabled(): void /** * Test image open dialog url when enhanced media gallery enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 0 + * @magentoConfigFixture default/system/media_gallery/enabled 1 */ public function testWithEnhancedMediaGalleryEnabled(): void { diff --git a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/WysiwygDefaultConfigOpenDialogUrlTest.php b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/WysiwygDefaultConfigOpenDialogUrlTest.php index df6cbe4fc2c09..aebf5927869d5 100644 --- a/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/WysiwygDefaultConfigOpenDialogUrlTest.php +++ b/app/code/Magento/MediaGalleryIntegration/Test/Integration/Model/WysiwygDefaultConfigOpenDialogUrlTest.php @@ -58,7 +58,7 @@ protected function setUp(): void /** * Test update wysiwyg editor open dialog url when enhanced media gallery not enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 1 + * @magentoConfigFixture default/system/media_gallery/enabled 0 */ public function testWithEnhancedMediaGalleryDisabled(): void { @@ -70,7 +70,7 @@ public function testWithEnhancedMediaGalleryDisabled(): void /** * Test update wysiwyg editor open dialog url when enhanced media gallery enabled. - * @magentoConfigFixture default/system/media_gallery/enabled 0 + * @magentoConfigFixture default/system/media_gallery/enabled 1 */ public function testWithEnhancedMediaGalleryEnabled(): void { diff --git a/app/code/Magento/MediaGallerySynchronization/Plugin/MediaGallerySyncTrigger.php b/app/code/Magento/MediaGallerySynchronization/Plugin/MediaGallerySyncTrigger.php index dfe007fa59add..9583c91184d1a 100644 --- a/app/code/Magento/MediaGallerySynchronization/Plugin/MediaGallerySyncTrigger.php +++ b/app/code/Magento/MediaGallerySynchronization/Plugin/MediaGallerySyncTrigger.php @@ -43,7 +43,7 @@ public function afterSave(Value $config, Value $result): Value { if ($result->getPath() === self::MEDIA_GALLERY_CONFIG_VALUE && $result->isValueChanged() - && (int) $result->getValue() !== self::MEDIA_GALLERY_ENABLED_VALUE + && (int) $result->getValue() === self::MEDIA_GALLERY_ENABLED_VALUE ) { $this->publish->execute(); } diff --git a/app/code/Magento/MediaGalleryUi/Test/Mftf/Data/AdobeStockConfigData.xml b/app/code/Magento/MediaGalleryUi/Test/Mftf/Data/AdobeStockConfigData.xml index 5e02d81fb82ae..e8f394a006104 100644 --- a/app/code/Magento/MediaGalleryUi/Test/Mftf/Data/AdobeStockConfigData.xml +++ b/app/code/Magento/MediaGalleryUi/Test/Mftf/Data/AdobeStockConfigData.xml @@ -9,10 +9,10 @@ xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd"> system/media_gallery/enabled - 0 + 1 system/media_gallery/enabled - 1 + 0 diff --git a/app/code/Magento/MediaGalleryUi/etc/adminhtml/menu.xml b/app/code/Magento/MediaGalleryUi/etc/adminhtml/menu.xml index e7486ccbf5a2f..92839aa75ac8b 100644 --- a/app/code/Magento/MediaGalleryUi/etc/adminhtml/menu.xml +++ b/app/code/Magento/MediaGalleryUi/etc/adminhtml/menu.xml @@ -7,21 +7,7 @@ --> - - + + diff --git a/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml b/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml index 1c303ab155dae..77544b42e899a 100644 --- a/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml +++ b/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml @@ -9,9 +9,9 @@
- + - + Magento\Config\Model\Config\Source\Yesno system/media_gallery/enabled From e76cb954bd71db1d9d8f9ca5d229b139d9958424 Mon Sep 17 00:00:00 2001 From: Shankar Konar Date: Fri, 14 Aug 2020 13:45:37 +0530 Subject: [PATCH 5/7] Revert "Enabled old media gallery by default" This reverts commit 8b592ee2005c4c324672b0b3f1f69307384c43c5. --- app/code/Magento/MediaGalleryUi/etc/config.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/code/Magento/MediaGalleryUi/etc/config.xml b/app/code/Magento/MediaGalleryUi/etc/config.xml index 593b1b8e58fd2..fe8e73c406e59 100644 --- a/app/code/Magento/MediaGalleryUi/etc/config.xml +++ b/app/code/Magento/MediaGalleryUi/etc/config.xml @@ -9,7 +9,7 @@ - 1 + 0 From 1fe9c2268eafa22d1318d459297de3041a9425ca Mon Sep 17 00:00:00 2001 From: Shankar Konar Date: Fri, 14 Aug 2020 13:46:08 +0530 Subject: [PATCH 6/7] Revert "fixed MFTF test" This reverts commit 651bd690cb0687565cc2a1e99a57d99be5e8f14c. --- .../MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/code/Magento/MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml b/app/code/Magento/MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml index 14464cf36234c..4749fc4a885b0 100644 --- a/app/code/Magento/MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml +++ b/app/code/Magento/MediaGalleryUi/Test/Mftf/Suite/MediaGalleryUiSuite.xml @@ -13,7 +13,7 @@ - + From de6d2a7ad9ecc1d58fbfd72aafbe8843934c123f Mon Sep 17 00:00:00 2001 From: Shankar Konar Date: Fri, 14 Aug 2020 13:58:35 +0530 Subject: [PATCH 7/7] Reversed Store configuration --- .../Model/Config/MediaGallery/Yesno.php | 21 +++++++++++++++++++ .../MediaGalleryUi/etc/adminhtml/system.xml | 6 +++--- 2 files changed, 24 insertions(+), 3 deletions(-) create mode 100644 app/code/Magento/MediaGalleryUi/Model/Config/MediaGallery/Yesno.php diff --git a/app/code/Magento/MediaGalleryUi/Model/Config/MediaGallery/Yesno.php b/app/code/Magento/MediaGalleryUi/Model/Config/MediaGallery/Yesno.php new file mode 100644 index 0000000000000..40cf7630d9911 --- /dev/null +++ b/app/code/Magento/MediaGalleryUi/Model/Config/MediaGallery/Yesno.php @@ -0,0 +1,21 @@ + 0, 'label' => __('Yes')], ['value' => 1, 'label' => __('No')]]; + } +} diff --git a/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml b/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml index 77544b42e899a..17aa08b5363ca 100644 --- a/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml +++ b/app/code/Magento/MediaGalleryUi/etc/adminhtml/system.xml @@ -9,10 +9,10 @@
- + - - Magento\Config\Model\Config\Source\Yesno + + Magento\MediaGalleryUi\Model\Config\MediaGallery\Yesno system/media_gallery/enabled