From 6d1c7a7fd3ffb82254f2126ed102c132ec2ad67d Mon Sep 17 00:00:00 2001 From: Andrii Lugovyi Date: Tue, 3 Nov 2015 23:58:39 +0200 Subject: [PATCH 01/24] MAGETWO-45422: "Does this have a weight?" Yes / No Product field is available for bundle product --- .../product/edit/bundle/option.phtml | 7 ++++ .../view/adminhtml/web/catalog/type-events.js | 3 +- .../web/js/product/weight-handler.js | 39 ++++++++++--------- 3 files changed, 30 insertions(+), 19 deletions(-) diff --git a/app/code/Magento/Bundle/view/adminhtml/templates/product/edit/bundle/option.phtml b/app/code/Magento/Bundle/view/adminhtml/templates/product/edit/bundle/option.phtml index ebb9ac5206896..6c754d5661b65 100644 --- a/app/code/Magento/Bundle/view/adminhtml/templates/product/edit/bundle/option.phtml +++ b/app/code/Magento/Bundle/view/adminhtml/templates/product/edit/bundle/option.phtml @@ -306,3 +306,10 @@ jQuery(window).load(function() { }); + diff --git a/app/code/Magento/Catalog/view/adminhtml/web/catalog/type-events.js b/app/code/Magento/Catalog/view/adminhtml/web/catalog/type-events.js index 38e5ea31f051b..6412f1169c75a 100644 --- a/app/code/Magento/Catalog/view/adminhtml/web/catalog/type-events.js +++ b/app/code/Magento/Catalog/view/adminhtml/web/catalog/type-events.js @@ -16,7 +16,8 @@ define([ */ init: function () { - if (weight.productHasWeight()) { + //not weight switcher giftcard, bundle + if (weight.productHasWeightBySwitcher() && weight.hasWeightSwither()) { this.type = { virtual: 'virtual', real: this.$type.val() //simple, configurable diff --git a/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js b/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js index 69b916ee7309f..83a4b462f62ab 100644 --- a/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js +++ b/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js @@ -13,13 +13,6 @@ define([ $weightSwitcher: $('[data-role=weight-switcher]'), $weight: $('#weight'), - /** - * Hide weight switcher - */ - hideWeightSwitcher: function () { - this.$weightSwitcher.hide(); - }, - /** * Is locked * @returns {*} @@ -47,23 +40,30 @@ define([ * @returns {*} */ switchWeight: function () { - return this.productHasWeight() ? this.enabled() : this.disabled(); + return this.productHasWeightBySwitcher() ? this.enabled() : this.disabled(); }, /** - * Product has weight - * @returns {Bool} + * Hide weight switcher */ - productHasWeight: function () { - return $('input:checked', this.$weightSwitcher).val() === '1'; + hideWeightSwitcher: function () { + this.$weightSwitcher.hide(); }, /** - * Notify product weight is changed - * @returns {*|jQuery} + * Has weight swither + * @returns {*} */ - notifyProductWeightIsChanged: function () { - return $('input:checked', this.$weightSwitcher).trigger('change'); + hasWeightSwither: function () { + return this.$weightSwitcher.is(':visible'); + }, + + /** + * Product has weight + * @returns {Bool} + */ + productHasWeightBySwitcher: function () { + return $('input:checked', this.$weightSwitcher).val() === '1'; }, /** @@ -71,7 +71,7 @@ define([ * @param {String} data */ change: function (data) { - var value = data !== undefined ? +data : !this.productHasWeight(); + var value = data !== undefined ? +data : !this.productHasWeightBySwitcher(); $('input[value=' + value + ']', this.$weightSwitcher).prop('checked', true); }, @@ -81,7 +81,10 @@ define([ */ 'Magento_Catalog/js/product/weight-handler': function () { this.bindAll(); - this.switchWeight(); + + if (this.hasWeightSwither()) { + this.switchWeight(); + } }, /** From 8d904052dfec14894001a85fd1cff7401a86c226 Mon Sep 17 00:00:00 2001 From: Andrii Lugovyi Date: Fri, 13 Nov 2015 14:36:44 +0200 Subject: [PATCH 02/24] MAGETWO-45422: "Does this have a weight?" Yes / No Product field is available for bundle product --- .../view/adminhtml/web/js/product/weight-handler.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js b/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js index 83a4b462f62ab..fa1a78f96211d 100644 --- a/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js +++ b/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js @@ -10,9 +10,16 @@ define([ return { - $weightSwitcher: $('[data-role=weight-switcher]'), $weight: $('#weight'), + /** + * Weight Switcher + * @returns {*|jQuery|HTMLElement} + */ + $weightSwitcher: function () { + return $('[data-role=weight-switcher]'); + }, + /** * Is locked * @returns {*} From 48b406251208ee502722f8cbd255cafeaedf15d4 Mon Sep 17 00:00:00 2001 From: Oleksandr Dubovyk Date: Mon, 16 Nov 2015 17:36:46 +0200 Subject: [PATCH 03/24] MAGETWO-45443: Date range conditions in Admin are displayed not aligned --- app/design/adminhtml/Magento/backend/web/css/styles-old.less | 2 +- .../Magento/Framework/Data/Form/Element/AbstractElement.php | 4 ++-- lib/internal/Magento/Framework/Data/Form/Element/Date.php | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/design/adminhtml/Magento/backend/web/css/styles-old.less b/app/design/adminhtml/Magento/backend/web/css/styles-old.less index d1e80c2be6e3f..7d0abac4d4b9f 100644 --- a/app/design/adminhtml/Magento/backend/web/css/styles-old.less +++ b/app/design/adminhtml/Magento/backend/web/css/styles-old.less @@ -3779,7 +3779,7 @@ .rule-chooser { border: solid 1px #CCC; margin: 20px; - padding: 15px 10px 5px; + padding: 15px 10px; overflow: auto; } diff --git a/lib/internal/Magento/Framework/Data/Form/Element/AbstractElement.php b/lib/internal/Magento/Framework/Data/Form/Element/AbstractElement.php index 44f0fd5cde196..f3d029454c21d 100644 --- a/lib/internal/Magento/Framework/Data/Form/Element/AbstractElement.php +++ b/lib/internal/Magento/Framework/Data/Form/Element/AbstractElement.php @@ -443,10 +443,10 @@ public function getDefaultHtml() { $html = $this->getData('default_html'); if ($html === null) { - $html = $this->getNoSpan() === true ? '' : '' . "\n"; + $html = $this->getNoSpan() === true ? '' : '
' . "\n"; $html .= $this->getLabelHtml(); $html .= $this->getElementHtml(); - $html .= $this->getNoSpan() === true ? '' : '' . "\n"; + $html .= $this->getNoSpan() === true ? '' : '
' . "\n"; } return $html; } diff --git a/lib/internal/Magento/Framework/Data/Form/Element/Date.php b/lib/internal/Magento/Framework/Data/Form/Element/Date.php index ed2579789900e..2d2ad1ef80018 100644 --- a/lib/internal/Magento/Framework/Data/Form/Element/Date.php +++ b/lib/internal/Magento/Framework/Data/Form/Element/Date.php @@ -147,7 +147,7 @@ public function getValueInstance() */ public function getElementHtml() { - $this->addClass('input-text'); + $this->addClass('admin__control-text'); $dateFormat = $this->getDateFormat() ?: $this->getFormat(); $timeFormat = $this->getTimeFormat(); if (empty($dateFormat)) { From 5666558519f3bf5cd83da6b258edbef3c1a0ad65 Mon Sep 17 00:00:00 2001 From: Olga Matviienko Date: Thu, 26 Nov 2015 11:58:23 +0200 Subject: [PATCH 04/24] MAGETWO-45877: "Remove Product from Mini Shopping Cart" Storefront pop-up contains an overlap --- .../Magento/blank/web/css/source/components/_modals_extend.less | 2 +- .../Magento/luma/web/css/source/components/_modals_extend.less | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/design/frontend/Magento/blank/web/css/source/components/_modals_extend.less b/app/design/frontend/Magento/blank/web/css/source/components/_modals_extend.less index 907be81bf00e5..bf2785cbeff0c 100644 --- a/app/design/frontend/Magento/blank/web/css/source/components/_modals_extend.less +++ b/app/design/frontend/Magento/blank/web/css/source/components/_modals_extend.less @@ -75,7 +75,7 @@ } .action-close { - padding: @modal-popup__padding; + padding: @indent__s; } } diff --git a/app/design/frontend/Magento/luma/web/css/source/components/_modals_extend.less b/app/design/frontend/Magento/luma/web/css/source/components/_modals_extend.less index 4df2fcd6f2977..98c4c45cd072f 100644 --- a/app/design/frontend/Magento/luma/web/css/source/components/_modals_extend.less +++ b/app/design/frontend/Magento/luma/web/css/source/components/_modals_extend.less @@ -75,7 +75,7 @@ } .action-close { - padding: @modal-popup__padding; + padding: @indent__base; } } From d0bffa7c50c61aa6bcb2bbe647be6e069d70c6cb Mon Sep 17 00:00:00 2001 From: Oleksandr Dubovyk Date: Fri, 27 Nov 2015 16:05:03 +0200 Subject: [PATCH 05/24] MAGETWO-45443: Date range conditions in Admin are displayed not aligned --- lib/internal/Magento/Framework/Data/Form/Element/Date.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/internal/Magento/Framework/Data/Form/Element/Date.php b/lib/internal/Magento/Framework/Data/Form/Element/Date.php index 2d2ad1ef80018..aff7b41115263 100644 --- a/lib/internal/Magento/Framework/Data/Form/Element/Date.php +++ b/lib/internal/Magento/Framework/Data/Form/Element/Date.php @@ -147,7 +147,7 @@ public function getValueInstance() */ public function getElementHtml() { - $this->addClass('admin__control-text'); + $this->addClass('admin__control-text input-text'); $dateFormat = $this->getDateFormat() ?: $this->getFormat(); $timeFormat = $this->getTimeFormat(); if (empty($dateFormat)) { From 68b819724fde0bfe998160d76658532e9383c870 Mon Sep 17 00:00:00 2001 From: Oleksandr Dubovyk Date: Fri, 27 Nov 2015 18:30:21 +0200 Subject: [PATCH 06/24] MAGETWO-45443: Date range conditions in Admin are displayed not aligned - Changed unit-test --- .../Test/Unit/Form/Element/AbstractElementTest.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/internal/Magento/Framework/Data/Test/Unit/Form/Element/AbstractElementTest.php b/lib/internal/Magento/Framework/Data/Test/Unit/Form/Element/AbstractElementTest.php index b601ed21a9e20..4fb4662ef138e 100644 --- a/lib/internal/Magento/Framework/Data/Test/Unit/Form/Element/AbstractElementTest.php +++ b/lib/internal/Magento/Framework/Data/Test/Unit/Form/Element/AbstractElementTest.php @@ -328,8 +328,8 @@ public function testGetHtmlWithoutRenderer() $this->_model->setForm( $this->getMock('Magento\Framework\Data\Form\AbstractForm', [], [], '', false) ); - $expectedHtml = '' . "\n" - . '' . "\n"; + $expectedHtml = '
' . "\n" + . '
' . "\n"; $this->assertEquals($expectedHtml, $this->_model->getHtml()); $this->assertEquals(' required-entry _required', $this->_model->getClass()); @@ -529,8 +529,8 @@ public function testGetDefaultHtmlDataProvider() return [ [ [], - '' . "\n" - . '' . "\n", + '
' . "\n" + . '
' . "\n", ], [ ['default_html' => 'some default html'], @@ -543,11 +543,11 @@ public function testGetDefaultHtmlDataProvider() 'name' => 'some-name', 'value' => 'some-value', ], - '' . "\n" + '
' . "\n" . '' . "\n" . '' - . '' . "\n" + . '
' . "\n" ], [ [ From 6a89cda704daa4744eb0b3bfec131451d0637b67 Mon Sep 17 00:00:00 2001 From: Olga Matviienko Date: Mon, 30 Nov 2015 18:49:30 +0200 Subject: [PATCH 07/24] MAGETWO-46186: Wizard heading is displayed broken while creating Configurable Product --- .../Ui/view/base/templates/stepswizard.phtml | 12 +- .../module/components/_steps-wizard.less | 17 +- .../navigation-bar/_navigation-bar.less | 147 +++++++++--------- 3 files changed, 98 insertions(+), 78 deletions(-) diff --git a/app/code/Magento/Ui/view/base/templates/stepswizard.phtml b/app/code/Magento/Ui/view/base/templates/stepswizard.phtml index d7ab4160a2c9c..8f7d1b9bebec2 100644 --- a/app/code/Magento/Ui/view/base/templates/stepswizard.phtml +++ b/app/code/Magento/Ui/view/base/templates/stepswizard.phtml @@ -23,10 +23,10 @@ diff --git a/app/code/Magento/BraintreeTwo/view/adminhtml/web/css/styles.css b/app/code/Magento/BraintreeTwo/view/adminhtml/web/css/styles.css deleted file mode 100644 index d46b52fcf846a..0000000000000 --- a/app/code/Magento/BraintreeTwo/view/adminhtml/web/css/styles.css +++ /dev/null @@ -1,57 +0,0 @@ -/** - * Copyright © 2015 Magento. All rights reserved. - * See COPYING.txt for license details. - */ -.control-container { - height: 2.4em; - background-color: #ffffff; - border-radius: 1px; - border: 1px solid #adadad; - color: #303030; - font-size: 1.4rem; - font-weight: 400; - line-height: 1.36; - padding: 0.6rem 1rem 0.6rem; - transition: border-color 0.1s linear; - vertical-align: baseline; -} -.control-container.select-date { - width: 30%; - display: inline-block; -} -.inline-separator { - display: inline-block; - margin: 0 10px; -} -.braintree-hosted-fields-focused { - border-color: #007bdb; -} -.braintree-hosted-fields-invalid{ - border-bottom-color: #D0021B; - border-bottom-width: 2px; -} -.icon-type { - position: absolute; - right: 5px; - top: 26px; - width: 40px; - height: 28px; - background-image: url('../images/cards.png'); - background-position: -1000px 0; - background-repeat: no-repeat; -} -.icon-type-discover { - background-position: 0 0; -} -.icon-type-visa { - background-position: 0 -28px; -} -.icon-type-master-card { - background-position: 0 -56px; -} -.icon-type-maestro { - background-position: 0 -85px; -} -.icon-type-american-express { - background-position: 0 -114px; -} \ No newline at end of file diff --git a/app/code/Magento/BraintreeTwo/view/adminhtml/web/images/cards.png b/app/code/Magento/BraintreeTwo/view/adminhtml/web/images/cards.png deleted file mode 100644 index 866756fe8b9f92b04ab024fb3c91afd4ae9164e4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5879 zcmbVQcQl+`x1Z68-igE*q9odk(QEWJL`ifpW(K2;P9lgpdJQ3nmgv0&A$p50qC_`J zv?i7;o(2^KI|Tp$pwiM*HN0B+uijWP zlB+MZ=WgoN!sexB>Sctr^YTS_paFMLSX(qm%LQSNHbf&(kK6~*asU9KAI8|!%M`9F zgT%TBBmVFR`?kkTlyq5??HPv%O13)%|-@^f)^^_20G2md8k=4$_kECL4o#p2~85B`@? zrto_p6|4suBrYr=gcOyK1W8H@L&PN|VUmI%s3=5SL{v;fOjHOeCIb_dfk8okKj15E z9w<8*Lsj*^bzPn0!46(tZZaYwzP`S~zGA{y4|@@aw6wH{C{zRr6}sXO@_gj#h42${ z_2m9Xf-2e*>49?uAYAf>MCR+eh4=ah_I-L zi_0Is{^IuZGDQEk8UK;n)A*4aTEr0TiS_nCUgg7%`ycRC?EZH}e;BW<6Xmf%2g1jSTWvOE zT1(w4>7(m`%Ohl!P*2s*BGJrB- zbCVG#D%IE<$+|W#+JSi54Zr~dhcXvT3P5C{^W}S#!@tkktkXyAic2ZX4E#LDx3*4R z2r>sw5dewAkMwG#_ljXVSw3bF2``_+c>_lmOQPaS)r&}orb!5aRWvP?8YKMD;9r4? zf#*3vN){HR!rA7L^UNY$oDa_#Dw}L&6c(%L?u(0`7I7**4eKHLwc5N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Ti||PS`p`TbIo*t*p_t0$=D%lAMCVl!p`#0HBj$0f7KiGOongVboso zjarIpLLn7PkJkI2grM}9 z9)dKn|LR_IVL`#bq~VUYXRU&Qg0;0ZUN@0|%TINX$;Q)tlqR4k7Z@Z8e0i(6j3u)c z%t(jfT=_$337C}eDsAEL;V%kFXBXq#uLUk?Tg?}JsOLkmDP#_|x3|-T91CiZD}9t@ zQFEZg`)HxwyGS zo~nsm5w5JP42XS>sOW7e8IK*i9W^_eR?eV*Z!P+n ziT=>?;`!Bt87v9f(j*Ldpg&M#y9_R zYxfymd2}*Q)gms6bH`oSQdeQNiP4zwx)=CV7fj>hoYw5%g3m<(h Date: Wed, 9 Dec 2015 09:52:31 +0200 Subject: [PATCH 12/24] MAGETWO-46662: [UI] Assistance with Accept Credit Card Payments using Braintree for StoreFront and Backend - Sorted alphabetically --- .../Magento/blank/Magento_Braintree/web/css/source/_module.less | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less b/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less index b672474d547e5..a1c69c4a2f6a4 100644 --- a/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less +++ b/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less @@ -63,8 +63,8 @@ &:after { content: '/'; display: inline; - padding-top: inherit; padding-bottom: inherit; + padding-top: inherit; position: absolute; right: -@distance / 2; top: 5px; From 977373bc222629b03e34b1e71cf14c62a6425928 Mon Sep 17 00:00:00 2001 From: Oleksandr Dubovyk Date: Wed, 9 Dec 2015 15:17:55 +0200 Subject: [PATCH 13/24] MAGETWO-46662: [UI] Assistance with Accept Credit Card Payments using Braintree for StoreFront and Backend - Added styles for Validation --- .../view/adminhtml/layout/sales_order_create_index.xml | 3 --- .../BraintreeTwo/view/adminhtml/templates/form/cc.phtml | 6 +++--- .../view/frontend/layout/checkout_index_index.xml | 3 --- .../backend/Magento_Braintree/web/css/source/_module.less | 3 ++- .../blank/Magento_Braintree/web/css/source/_module.less | 3 +++ 5 files changed, 8 insertions(+), 10 deletions(-) diff --git a/app/code/Magento/BraintreeTwo/view/adminhtml/layout/sales_order_create_index.xml b/app/code/Magento/BraintreeTwo/view/adminhtml/layout/sales_order_create_index.xml index 2b1afd2ec71d2..c3191421f12b3 100644 --- a/app/code/Magento/BraintreeTwo/view/adminhtml/layout/sales_order_create_index.xml +++ b/app/code/Magento/BraintreeTwo/view/adminhtml/layout/sales_order_create_index.xml @@ -6,9 +6,6 @@ */ --> - - - diff --git a/app/code/Magento/BraintreeTwo/view/adminhtml/templates/form/cc.phtml b/app/code/Magento/BraintreeTwo/view/adminhtml/templates/form/cc.phtml index 8eb77bc890bbe..983e88e28c74a 100644 --- a/app/code/Magento/BraintreeTwo/view/adminhtml/templates/form/cc.phtml +++ b/app/code/Magento/BraintreeTwo/view/adminhtml/templates/form/cc.phtml @@ -39,7 +39,7 @@ $ccType = $block->getInfoData('cc_type');
-
+
escapeHtml(__('Please, enter valid Credit Card Number')); ?>
@@ -57,7 +57,7 @@ $ccType = $block->getInfoData('cc_type');
-
escapeHtml(__('Please, enter valid Expiration Date')); ?>
+
escapeHtml(__('Please, enter valid Expiration Date')); ?>
@@ -70,7 +70,7 @@ $ccType = $block->getInfoData('cc_type');
-
+
escapeHtml(__('Please, enter valid Card Verification Number')); ?>
diff --git a/app/code/Magento/BraintreeTwo/view/frontend/layout/checkout_index_index.xml b/app/code/Magento/BraintreeTwo/view/frontend/layout/checkout_index_index.xml index f7016a767d8be..e73e0553475bc 100644 --- a/app/code/Magento/BraintreeTwo/view/frontend/layout/checkout_index_index.xml +++ b/app/code/Magento/BraintreeTwo/view/frontend/layout/checkout_index_index.xml @@ -6,9 +6,6 @@ */ --> - - - diff --git a/app/design/adminhtml/Magento/backend/Magento_Braintree/web/css/source/_module.less b/app/design/adminhtml/Magento/backend/Magento_Braintree/web/css/source/_module.less index b2cae0a42992f..321ce28a9c311 100644 --- a/app/design/adminhtml/Magento/backend/Magento_Braintree/web/css/source/_module.less +++ b/app/design/adminhtml/Magento/backend/Magento_Braintree/web/css/source/_module.less @@ -40,6 +40,7 @@ @distance: 50px; float: left; + margin-bottom: .2rem; width: 5rem; &:first-of-type { @@ -51,7 +52,7 @@ padding-bottom: inherit; padding-top: inherit; position: absolute; - right: -@distance / 2; + right: -@distance * (2 / 3.5); top: 0; } } diff --git a/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less b/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less index a1c69c4a2f6a4..fa288e3e57b79 100644 --- a/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less +++ b/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less @@ -55,6 +55,7 @@ @distance: 50px; float: left; + margin-bottom: 7px; width: 6rem; &:first-of-type { @@ -80,6 +81,8 @@ .hosted-error { clear: both; color: @braintree-error__color; + font-size: 1.2rem; + margin-top: 7px; height: 0; opacity: 0; } From 2b111811e4d2fc7ebb5c8cac72b5e99f3410d514 Mon Sep 17 00:00:00 2001 From: Oleksandr Dubovyk Date: Wed, 9 Dec 2015 15:21:51 +0200 Subject: [PATCH 14/24] MAGETWO-46662: [UI] Assistance with Accept Credit Card Payments using Braintree for StoreFront and Backend - Sorted --- .../Magento/blank/Magento_Braintree/web/css/source/_module.less | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less b/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less index fa288e3e57b79..652c516f93925 100644 --- a/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less +++ b/app/design/frontend/Magento/blank/Magento_Braintree/web/css/source/_module.less @@ -82,8 +82,8 @@ clear: both; color: @braintree-error__color; font-size: 1.2rem; - margin-top: 7px; height: 0; + margin-top: 7px; opacity: 0; } } From fd7fc68a0f1acfede56b29cb95c4d472fef8e836 Mon Sep 17 00:00:00 2001 From: Michail Slabko Date: Thu, 10 Dec 2015 14:19:44 +0200 Subject: [PATCH 15/24] MAGETWO-46663: Most of category fields dont have Use Default Value option in Store/StoreView scope --- .../Magento/Catalog/Block/Adminhtml/Category/Tab/Attributes.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/code/Magento/Catalog/Block/Adminhtml/Category/Tab/Attributes.php b/app/code/Magento/Catalog/Block/Adminhtml/Category/Tab/Attributes.php index 06a77c8af6023..f73dda6152d1f 100644 --- a/app/code/Magento/Catalog/Block/Adminhtml/Category/Tab/Attributes.php +++ b/app/code/Magento/Catalog/Block/Adminhtml/Category/Tab/Attributes.php @@ -11,7 +11,7 @@ */ namespace Magento\Catalog\Block\Adminhtml\Category\Tab; -class Attributes extends \Magento\Backend\Block\Widget\Form\Generic +class Attributes extends \Magento\Catalog\Block\Adminhtml\Form { /** * Retrieve Category object From db6cd8ef1163b2eff14a877608b08681eedddf90 Mon Sep 17 00:00:00 2001 From: "Lugovyi, Andrii(alugovyi)" Date: Fri, 13 Nov 2015 17:29:44 +0200 Subject: [PATCH 16/24] MAGETWO-45422: "Does this have a weight?" Yes / No Product field is available for bundle product --- .../web/js/product/weight-handler.js | 24 ++++++++++++------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js b/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js index fa1a78f96211d..43abd2fe77933 100644 --- a/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js +++ b/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js @@ -10,7 +10,13 @@ define([ return { - $weight: $('#weight'), + /** + * Get weight + * @returns {*|jQuery|HTMLElement} + */ + $weight: function () { + return $('#weight'); + }, /** * Weight Switcher @@ -25,21 +31,21 @@ define([ * @returns {*} */ isLocked: function () { - return this.$weight.is('[data-locked]'); + return this.$weight().is('[data-locked]'); }, /** * Disabled */ disabled: function () { - this.$weight.addClass('ignore-validate').prop('disabled', true); + this.$weight().addClass('ignore-validate').prop('disabled', true); }, /** * Enabled */ enabled: function () { - this.$weight.removeClass('ignore-validate').prop('disabled', false); + this.$weight().removeClass('ignore-validate').prop('disabled', false); }, /** @@ -54,7 +60,7 @@ define([ * Hide weight switcher */ hideWeightSwitcher: function () { - this.$weightSwitcher.hide(); + this.$weightSwitcher().hide(); }, /** @@ -62,7 +68,7 @@ define([ * @returns {*} */ hasWeightSwither: function () { - return this.$weightSwitcher.is(':visible'); + return this.$weightSwitcher().is(':visible'); }, /** @@ -70,7 +76,7 @@ define([ * @returns {Bool} */ productHasWeightBySwitcher: function () { - return $('input:checked', this.$weightSwitcher).val() === '1'; + return $('input:checked', this.$weightSwitcher()).val() === '1'; }, /** @@ -80,7 +86,7 @@ define([ change: function (data) { var value = data !== undefined ? +data : !this.productHasWeightBySwitcher(); - $('input[value=' + value + ']', this.$weightSwitcher).prop('checked', true); + $('input[value=' + value + ']', this.$weightSwitcher()).prop('checked', true); }, /** @@ -98,7 +104,7 @@ define([ * Bind all */ bindAll: function () { - this.$weightSwitcher.find('input').on('change', this.switchWeight.bind(this)); + this.$weightSwitcher().find('input').on('change', this.switchWeight.bind(this)); } }; }); From 60a94e1700c20b7796ef88b46796d103e20531a3 Mon Sep 17 00:00:00 2001 From: Olga Matviienko Date: Thu, 10 Dec 2015 17:18:35 +0200 Subject: [PATCH 17/24] MAGETWO-46232: "Wish List actions" drop-down items are highlighted invalidly on Storefront in Blank Theme --- .../blank/Magento_MultipleWishlist/web/css/source/_module.less | 2 -- 1 file changed, 2 deletions(-) diff --git a/app/design/frontend/Magento/blank/Magento_MultipleWishlist/web/css/source/_module.less b/app/design/frontend/Magento/blank/Magento_MultipleWishlist/web/css/source/_module.less index 6280c42f5eadb..59aa694f13268 100644 --- a/app/design/frontend/Magento/blank/Magento_MultipleWishlist/web/css/source/_module.less +++ b/app/design/frontend/Magento/blank/Magento_MultipleWishlist/web/css/source/_module.less @@ -36,8 +36,6 @@ text-align: left; .item { &:last-child { - background: @color-gray-darken1; - &:hover { .lib-css(background, @dropdown-list-item__hover); } From 98f540a5eba4a18696d5bc57cf8c04a90d003324 Mon Sep 17 00:00:00 2001 From: Olga Matviienko Date: Fri, 11 Dec 2015 12:38:48 +0200 Subject: [PATCH 18/24] MAGETWO-46057: "Remove row" buttons aren't centered vertically --- .../Magento_AdvancedCheckout/web/css/source/_module.less | 5 +++-- .../Magento_AdvancedCheckout/web/css/source/_module.less | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/app/design/frontend/Magento/blank/Magento_AdvancedCheckout/web/css/source/_module.less b/app/design/frontend/Magento/blank/Magento_AdvancedCheckout/web/css/source/_module.less index 9d2890d2e2dcc..a737bc72a80ae 100644 --- a/app/design/frontend/Magento/blank/Magento_AdvancedCheckout/web/css/source/_module.less +++ b/app/design/frontend/Magento/blank/Magento_AdvancedCheckout/web/css/source/_module.less @@ -123,7 +123,8 @@ .lib-button-icon( @_icon-font-content: @icon-remove, @_icon-font-text-hide: true, - @_icon-font-size: 28px + @_icon-font-size: 28px, + @_icon-font-margin: 1px 0 0 ); .lib-button-reset(); } @@ -139,7 +140,7 @@ &.remove { .lib-button-reset(); .lib-button-as-link(); - margin-top: 4px; + margin-top: 2px; } } } diff --git a/app/design/frontend/Magento/luma/Magento_AdvancedCheckout/web/css/source/_module.less b/app/design/frontend/Magento/luma/Magento_AdvancedCheckout/web/css/source/_module.less index 905fe653e21c3..37e16b98936ee 100644 --- a/app/design/frontend/Magento/luma/Magento_AdvancedCheckout/web/css/source/_module.less +++ b/app/design/frontend/Magento/luma/Magento_AdvancedCheckout/web/css/source/_module.less @@ -134,7 +134,8 @@ @_icon-font-content: @icon-trash, @_icon-font-text-hide: true, @_icon-font-size: 18px, - @_icon-font-color: @minicart-icons-color + @_icon-font-color: @minicart-icons-color, + @_icon-font-margin: -4px 0 0 ); .lib-button-reset(); } @@ -158,7 +159,7 @@ &.remove { .lib-button-reset(); .lib-button-as-link(); - margin-top: 4px; + margin-top: -4px; } } } From 5663d26c8b7059715ab9a2ff542331266ee04d75 Mon Sep 17 00:00:00 2001 From: Oleksandr Dubovyk Date: Fri, 11 Dec 2015 18:54:11 +0200 Subject: [PATCH 19/24] MAGETWO-46662: [UI] Assistance with Accept Credit Card Payments using Braintree for StoreFront and Backend - Refactored - Corrected Spelling --- .../view/adminhtml/templates/form/cc.phtml | 6 +++--- .../view/frontend/web/template/payment/form.html | 6 +++--- .../Magento_Braintree/web/css/source/_module.less | 14 +++++++------- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/app/code/Magento/BraintreeTwo/view/adminhtml/templates/form/cc.phtml b/app/code/Magento/BraintreeTwo/view/adminhtml/templates/form/cc.phtml index 983e88e28c74a..d62624fd02b0d 100644 --- a/app/code/Magento/BraintreeTwo/view/adminhtml/templates/form/cc.phtml +++ b/app/code/Magento/BraintreeTwo/view/adminhtml/templates/form/cc.phtml @@ -40,7 +40,7 @@ $ccType = $block->getInfoData('cc_type');
- escapeHtml(__('Please, enter valid Credit Card Number')); ?> + escapeHtml(__('Please enter valid Credit Card Number')); ?>
@@ -57,7 +57,7 @@ $ccType = $block->getInfoData('cc_type');
-
escapeHtml(__('Please, enter valid Expiration Date')); ?>
+
escapeHtml(__('Please enter valid Expiration Date')); ?>
@@ -71,7 +71,7 @@ $ccType = $block->getInfoData('cc_type'); class="admin__control-text hosted-control hosted-cid">
- escapeHtml(__('Please, enter valid Card Verification Number')); ?> + escapeHtml(__('Please enter valid Card Verification Number')); ?>
diff --git a/app/code/Magento/BraintreeTwo/view/frontend/web/template/payment/form.html b/app/code/Magento/BraintreeTwo/view/frontend/web/template/payment/form.html index ee25e1fc97e5b..1531ceb73f23e 100644 --- a/app/code/Magento/BraintreeTwo/view/frontend/web/template/payment/form.html +++ b/app/code/Magento/BraintreeTwo/view/frontend/web/template/payment/form.html @@ -62,7 +62,7 @@
-
+
@@ -77,7 +77,7 @@
-
+
@@ -88,7 +88,7 @@
-
+
Date: Mon, 14 Dec 2015 12:59:54 +0200 Subject: [PATCH 20/24] MAGETWO-45422: "Does this have a weight?" Yes / No Product field is available for bundle product --- .../Catalog/view/adminhtml/web/js/product/weight-handler.js | 1 + .../view/adminhtml/web/downloadable-type-handler.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js b/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js index 43abd2fe77933..5767480c81622 100644 --- a/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js +++ b/app/code/Magento/Catalog/view/adminhtml/web/js/product/weight-handler.js @@ -87,6 +87,7 @@ define([ var value = data !== undefined ? +data : !this.productHasWeightBySwitcher(); $('input[value=' + value + ']', this.$weightSwitcher()).prop('checked', true); + this.switchWeight(); }, /** diff --git a/app/code/Magento/Downloadable/view/adminhtml/web/downloadable-type-handler.js b/app/code/Magento/Downloadable/view/adminhtml/web/downloadable-type-handler.js index d76b7ba45d758..24e5b4ea9a450 100644 --- a/app/code/Magento/Downloadable/view/adminhtml/web/downloadable-type-handler.js +++ b/app/code/Magento/Downloadable/view/adminhtml/web/downloadable-type-handler.js @@ -61,7 +61,7 @@ define([ _initType: function () { if (productType.type.current === 'downloadable') { weight.change(false); - weight.$weightSwitcher.one('change', function () { + weight.$weightSwitcher().one('change', function () { $(document).trigger('setTypeProduct', null); }); this.show(); From d54c058683c3e39ff77c83d736fe2da3dc783c54 Mon Sep 17 00:00:00 2001 From: Michail Slabko Date: Mon, 14 Dec 2015 15:02:37 +0200 Subject: [PATCH 21/24] MAGETWO-45610: [Create Virtual Product] Invalid Test variation --- ...ductTierPriceOnProductPageWithCustomer.php | 68 +++++++++++++++++++ .../Test/Repository/Product/TierPrice.xml | 9 +++ .../CreateVirtualProductEntityTest.xml | 15 +++- 3 files changed, 89 insertions(+), 3 deletions(-) create mode 100644 dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTierPriceOnProductPageWithCustomer.php diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTierPriceOnProductPageWithCustomer.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTierPriceOnProductPageWithCustomer.php new file mode 100644 index 0000000000000..8ce42fb0a28d5 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTierPriceOnProductPageWithCustomer.php @@ -0,0 +1,68 @@ +persist(); + $this->loginCustomer($customer); + + $productTierPriceAssert = $this->objectManager->get( + 'Magento\Catalog\Test\Constraint\AssertProductTierPriceOnProductPage' + ); + $productTierPriceAssert->processAssert($browser, $catalogProductView, $product); + } + + /** + * Login customer + * + * @param Customer $customer + * + * @return void + */ + protected function loginCustomer($customer) + { + $this->objectManager->create( + 'Magento\Customer\Test\TestStep\LoginCustomerOnFrontendStep', + ['customer' => $customer] + )->run(); + } + + /** + * Returns a string representation of the object + * + * @return string + */ + public function toString() + { + return 'Tier price is displayed on the product page for specific customer.'; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Product/TierPrice.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Product/TierPrice.xml index 805c784847fed..ed80a0648244e 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Product/TierPrice.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Product/TierPrice.xml @@ -30,5 +30,14 @@ ALL GROUPS + + + + 80 + All Websites [USD] + 2 + General + + diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.xml index 077a819c35984..dbe7f420d7339 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.xml @@ -35,6 +35,7 @@ + Create product with out of stock @@ -52,17 +53,24 @@ - Create product with group price + Create product with tier price for "General" group virtual-product-%isolation% VirtualProduct %isolation% virtual_sku_%isolation% - 10 + 100 + None + 999 No category_%isolation% - Catalog + general + Yes + In Stock + Catalog, Search + default + Create product with custom options suite and import options @@ -70,6 +78,7 @@ VirtualProduct %isolation% virtual_sku_%isolation% 9000 + 999 No options_suite catalogProductSimple::with_two_custom_option,catalogProductSimple::with_all_custom_option From d145602e650e4828bcfd5f78feb030debd8e05b9 Mon Sep 17 00:00:00 2001 From: Serhiy Shkolyarenko Date: Thu, 17 Dec 2015 17:54:26 +0200 Subject: [PATCH 22/24] MAGETWO-46968: Upgrade data issues fixed upgrade script --- .../Magento/Customer/Setup/UpgradeData.php | 91 ++++++++++--------- 1 file changed, 46 insertions(+), 45 deletions(-) diff --git a/app/code/Magento/Customer/Setup/UpgradeData.php b/app/code/Magento/Customer/Setup/UpgradeData.php index 3b2489cb62692..d19765b99a43b 100644 --- a/app/code/Magento/Customer/Setup/UpgradeData.php +++ b/app/code/Magento/Customer/Setup/UpgradeData.php @@ -60,6 +60,52 @@ public function upgrade(ModuleDataSetupInterface $setup, ModuleContextInterface /** @var CustomerSetup $customerSetup */ $customerSetup = $this->customerSetupFactory->create(['setup' => $setup]); + if (version_compare($context->getVersion(), '2.0.6', '<')) { + $customerSetup->updateEntityType( + \Magento\Customer\Model\Customer::ENTITY, + 'entity_model', + 'Magento\Customer\Model\ResourceModel\Customer' + ); + $customerSetup->updateEntityType( + \Magento\Customer\Model\Customer::ENTITY, + 'increment_model', + 'Magento\Eav\Model\Entity\Increment\NumericValue' + ); + $customerSetup->updateEntityType( + \Magento\Customer\Model\Customer::ENTITY, + 'entity_attribute_collection', + 'Magento\Customer\Model\ResourceModel\Attribute\Collection' + ); + $customerSetup->updateEntityType( + 'customer_address', + 'entity_model', + 'Magento\Customer\Model\ResourceModel\Address' + ); + $customerSetup->updateEntityType( + 'customer_address', + 'entity_attribute_collection', + 'Magento\Customer\Model\ResourceModel\Address\Attribute\Collection' + ); + $customerSetup->updateAttribute( + 'customer_address', + 'country_id', + 'source_model', + 'Magento\Customer\Model\ResourceModel\Address\Attribute\Source\Country' + ); + $customerSetup->updateAttribute( + 'customer_address', + 'region', + 'backend_model', + 'Magento\Customer\Model\ResourceModel\Address\Attribute\Backend\Region' + ); + $customerSetup->updateAttribute( + 'customer_address', + 'region_id', + 'source_model', + 'Magento\Customer\Model\ResourceModel\Address\Attribute\Source\Region' + ); + } + if (version_compare($context->getVersion(), '2.0.1', '<')) { $entityAttributes = [ 'customer' => [ @@ -240,51 +286,6 @@ public function upgrade(ModuleDataSetupInterface $setup, ModuleContextInterface ]; $this->upgradeAttributes($entityAttributes, $customerSetup); } - if (version_compare($context->getVersion(), '2.0.6', '<')) { - $customerSetup->updateEntityType( - \Magento\Customer\Model\Customer::ENTITY, - 'entity_model', - 'Magento\Customer\Model\ResourceModel\Customer' - ); - $customerSetup->updateEntityType( - \Magento\Customer\Model\Customer::ENTITY, - 'increment_model', - 'Magento\Eav\Model\Entity\Increment\NumericValue' - ); - $customerSetup->updateEntityType( - \Magento\Customer\Model\Customer::ENTITY, - 'entity_attribute_collection', - 'Magento\Customer\Model\ResourceModel\Attribute\Collection' - ); - $customerSetup->updateEntityType( - 'customer_address', - 'entity_model', - 'Magento\Customer\Model\ResourceModel\Address' - ); - $customerSetup->updateEntityType( - 'customer_address', - 'entity_attribute_collection', - 'Magento\Customer\Model\ResourceModel\Address\Attribute\Collection' - ); - $customerSetup->updateAttribute( - 'customer_address', - 'country_id', - 'source_model', - 'Magento\Customer\Model\ResourceModel\Address\Attribute\Source\Country' - ); - $customerSetup->updateAttribute( - 'customer_address', - 'region', - 'backend_model', - 'Magento\Customer\Model\ResourceModel\Address\Attribute\Backend\Region' - ); - $customerSetup->updateAttribute( - 'customer_address', - 'region_id', - 'source_model', - 'Magento\Customer\Model\ResourceModel\Address\Attribute\Source\Region' - ); - } if (version_compare($context->getVersion(), '2.0.6', '<')) { $setup->getConnection()->delete( From 16855f0ef37041cb418d77f84989da397aab140e Mon Sep 17 00:00:00 2001 From: Michail Slabko Date: Fri, 18 Dec 2015 17:23:19 +0200 Subject: [PATCH 23/24] MAGETWO-43771: There is no reliable way to refer Attribute Group from EAV Setup --- .../Magento/Catalog/Setup/InstallData.php | 14 ++++---- .../ResourceModel/Entity/Attribute/Group.php | 7 ---- app/code/Magento/Eav/Setup/EavSetup.php | 33 ++++++++++++------- .../ProductVideo/Setup/UpgradeData.php | 2 +- .../Test/Legacy/_files/obsolete_constants.php | 4 ++- 5 files changed, 32 insertions(+), 28 deletions(-) diff --git a/app/code/Magento/Catalog/Setup/InstallData.php b/app/code/Magento/Catalog/Setup/InstallData.php index 535d99c56fed7..0b86b819d0962 100644 --- a/app/code/Magento/Catalog/Setup/InstallData.php +++ b/app/code/Magento/Catalog/Setup/InstallData.php @@ -89,13 +89,13 @@ public function install(ModuleDataSetupInterface $setup, ModuleContextInterface $categorySetup->updateAttributeGroup($entityTypeId, $attributeSetId, $attributeGroupId, 'sort_order', '10'); $groups = [ - 'display' => ['name' => 'Display Settings', 'sort' => 20, 'id' => null], - 'design' => ['name' => 'Custom Design', 'sort' => 30, 'id' => null], + 'display' => ['name' => 'Display Settings', 'code' => 'display-settings', 'sort' => 20, 'id' => null], + 'design' => ['name' => 'Custom Design', 'code' => 'custom-design', 'sort' => 30, 'id' => null], ]; foreach ($groups as $k => $groupProp) { $categorySetup->addAttributeGroup($entityTypeId, $attributeSetId, $groupProp['name'], $groupProp['sort']); - $groups[$k]['id'] = $categorySetup->getAttributeGroupId($entityTypeId, $attributeSetId, $groupProp['name']); + $groups[$k]['id'] = $categorySetup->getAttributeGroupId($entityTypeId, $attributeSetId, $groupProp['code']); } // update attributes group and sort @@ -183,25 +183,25 @@ public function install(ModuleDataSetupInterface $setup, ModuleContextInterface $tabNames = [ 'General' => [ 'attribute_group_name' => $newGeneralTabName, - 'attribute_group_code' => preg_replace('/[^a-z0-9]+/', '-', strtolower($newGeneralTabName)), + 'attribute_group_code' => $categorySetup->convertToAttributeGroupCode($newGeneralTabName), 'tab_group_code' => 'basic', 'sort_order' => 10, ], 'Images' => [ 'attribute_group_name' => $newImagesTabName, - 'attribute_group_code' => preg_replace('/[^a-z0-9]+/', '-', strtolower($newImagesTabName)), + 'attribute_group_code' => $categorySetup->convertToAttributeGroupCode($newImagesTabName), 'tab_group_code' => 'basic', 'sort_order' => 20, ], 'Meta Information' => [ 'attribute_group_name' => $newMetaTabName, - 'attribute_group_code' => preg_replace('/[^a-z0-9]+/', '-', strtolower($newMetaTabName)), + 'attribute_group_code' => $categorySetup->convertToAttributeGroupCode($newMetaTabName), 'tab_group_code' => 'basic', 'sort_order' => 30, ], 'Prices' => [ 'attribute_group_name' => $newPriceTabName, - 'attribute_group_code' => preg_replace('/[^a-z0-9]+/', '-', strtolower($newPriceTabName)), + 'attribute_group_code' => $categorySetup->convertToAttributeGroupCode($newPriceTabName), 'tab_group_code' => 'advanced', 'sort_order' => 40, ], diff --git a/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute/Group.php b/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute/Group.php index 6a4a8f0e70ffa..5f146390e89d1 100644 --- a/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute/Group.php +++ b/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute/Group.php @@ -12,13 +12,6 @@ */ class Group extends \Magento\Framework\Model\ResourceModel\Db\AbstractDb { - /** - * Constants for attribute group codes - */ - const TAB_GENERAL_CODE = 'product-details'; - - const TAB_IMAGE_MANAGEMENT_CODE = 'image-management'; - /** * Resource initialization * diff --git a/app/code/Magento/Eav/Setup/EavSetup.php b/app/code/Magento/Eav/Setup/EavSetup.php index d1d0452fe7b77..93b0851d3a271 100644 --- a/app/code/Magento/Eav/Setup/EavSetup.php +++ b/app/code/Magento/Eav/Setup/EavSetup.php @@ -59,7 +59,7 @@ class EavSetup * * @var array */ - private $defaultGroupIdAssociations = ['General' => 1]; + private $defaultGroupIdAssociations = ['general' => 1]; /** * Default attribute group name @@ -134,12 +134,12 @@ public function cleanCache() public function installDefaultGroupIds() { $setIds = $this->getAllAttributeSetIds(); - foreach ($this->defaultGroupIdAssociations as $defaultGroupName => $defaultGroupId) { + foreach ($this->defaultGroupIdAssociations as $defaultGroupCode => $defaultGroupId) { foreach ($setIds as $set) { $groupId = $this->setup->getTableRow( 'eav_attribute_group', - 'attribute_group_name', - $defaultGroupName, + 'attribute_group_code', + $defaultGroupCode, 'attribute_group_id', 'attribute_set_id', $set @@ -511,16 +511,17 @@ public function addAttributeGroup($entityTypeId, $setId, $name, $sortOrder = nul { $setId = $this->getAttributeSetId($entityTypeId, $setId); $data = ['attribute_set_id' => $setId, 'attribute_group_name' => $name]; + $attributeGroupCode = $this->convertToAttributeGroupCode($name); - if (isset($this->defaultGroupIdAssociations[$name])) { - $data['default_id'] = $this->defaultGroupIdAssociations[$name]; + if (isset($this->defaultGroupIdAssociations[$attributeGroupCode])) { + $data['default_id'] = $this->defaultGroupIdAssociations[$attributeGroupCode]; } if ($sortOrder !== null) { $data['sort_order'] = $sortOrder; } - $groupId = $this->getAttributeGroup($entityTypeId, $setId, $name, 'attribute_group_id'); + $groupId = $this->getAttributeGroup($entityTypeId, $setId, $attributeGroupCode, 'attribute_group_id'); if ($groupId) { $this->updateAttributeGroup($entityTypeId, $setId, $groupId, $data); } else { @@ -528,7 +529,6 @@ public function addAttributeGroup($entityTypeId, $setId, $name, $sortOrder = nul $data['sort_order'] = $this->getAttributeGroupSortOrder($entityTypeId, $setId, $sortOrder); } if (empty($data['attribute_group_code'])) { - $attributeGroupCode = trim(preg_replace('/[^a-z0-9]+/', '-', strtolower($name)), '-'); if (empty($attributeGroupCode)) { // in the following code md5 is not used for security purposes $attributeGroupCode = md5($name); @@ -541,6 +541,15 @@ public function addAttributeGroup($entityTypeId, $setId, $name, $sortOrder = nul return $this; } + /** + * @param string $groupName + * @return string + */ + public function convertToAttributeGroupCode($groupName) + { + return trim(preg_replace('/[^a-z0-9]+/', '-', strtolower($groupName)), '-'); + } + /** * Update Attribute Group Data * @@ -577,22 +586,22 @@ public function updateAttributeGroup($entityTypeId, $setId, $id, $field, $value */ public function getAttributeGroup($entityTypeId, $setId, $id, $field = null) { - $searchId = $id; if (is_numeric($id)) { $searchField = 'attribute_group_id'; } else { + $id = $this->convertToAttributeGroupCode($id); if (isset($this->defaultGroupIdAssociations[$id])) { $searchField = 'default_id'; - $searchId = $this->defaultGroupIdAssociations[$id]; + $id = $this->defaultGroupIdAssociations[$id]; } else { - $searchField = 'attribute_group_name'; + $searchField = 'attribute_group_code'; } } return $this->setup->getTableRow( 'eav_attribute_group', $searchField, - $searchId, + $id, $field, 'attribute_set_id', $this->getAttributeSetId($entityTypeId, $setId) diff --git a/app/code/Magento/ProductVideo/Setup/UpgradeData.php b/app/code/Magento/ProductVideo/Setup/UpgradeData.php index b1e418c0f39df..056db24d4c76a 100644 --- a/app/code/Magento/ProductVideo/Setup/UpgradeData.php +++ b/app/code/Magento/ProductVideo/Setup/UpgradeData.php @@ -51,7 +51,7 @@ public function upgrade(ModuleDataSetupInterface $setup, ModuleContextInterface $attributeGroup = $categorySetup->getAttributeGroup( $entityTypeId, $attributeSetId, - 'Image Management' + 'image-management' ); if (isset($attributeGroup['attribute_group_name']) && $attributeGroup['attribute_group_name'] == 'Image Management' diff --git a/dev/tests/static/testsuite/Magento/Test/Legacy/_files/obsolete_constants.php b/dev/tests/static/testsuite/Magento/Test/Legacy/_files/obsolete_constants.php index a6c1b3688018e..0b1d33e45a6a7 100644 --- a/dev/tests/static/testsuite/Magento/Test/Legacy/_files/obsolete_constants.php +++ b/dev/tests/static/testsuite/Magento/Test/Legacy/_files/obsolete_constants.php @@ -949,5 +949,7 @@ 'DEFAULT_GLOBAL_MULTI_VALUE_SEPARATOR', 'Magento\CatalogImportExport\Model\Import\Product', 'Magento\ImportExport\Model\Import::DEFAULT_GLOBAL_MULTI_VALUE_SEPARATOR' - ] + ], + ['TAB_GENERAL_CODE', 'Magento\Eav\Model\ResourceModel\Entity\Attribute\Group'], + ['TAB_IMAGE_MANAGEMENT_CODE', 'Magento\Eav\Model\ResourceModel\Entity\Attribute\Group'], ]; From fe76bca034663ef523d187b05319a2fa36bff92a Mon Sep 17 00:00:00 2001 From: Michail Slabko Date: Fri, 18 Dec 2015 18:53:44 +0200 Subject: [PATCH 24/24] MAGETWO-45422: "Does this have a weight?" Yes / No Product field is available for bundle product - fix static --- .../Magento/Catalog/view/adminhtml/web/catalog/type-events.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/code/Magento/Catalog/view/adminhtml/web/catalog/type-events.js b/app/code/Magento/Catalog/view/adminhtml/web/catalog/type-events.js index 6412f1169c75a..abcdfd3065972 100644 --- a/app/code/Magento/Catalog/view/adminhtml/web/catalog/type-events.js +++ b/app/code/Magento/Catalog/view/adminhtml/web/catalog/type-events.js @@ -16,7 +16,7 @@ define([ */ init: function () { - //not weight switcher giftcard, bundle + //not weight switcher for specific product if (weight.productHasWeightBySwitcher() && weight.hasWeightSwither()) { this.type = { virtual: 'virtual',