Skip to content

add patch for https://github.com/magento/magento2/issues/18154 #5

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
Index: Model/Product/Attribute/Backend/TierPrice/UpdateHandler.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- Model/Product/Attribute/Backend/TierPrice/UpdateHandler.php (revision 1804146a601561685f54c920bf869b3f2398cb9e)
+++ Model/Product/Attribute/Backend/TierPrice/UpdateHandler.php (date 1537531110000)
@@ -83,7 +83,7 @@
);
}
$websiteId = $this->storeManager->getStore($entity->getStoreId())->getWebsiteId();
- $isGlobal = $attribute->isScopeGlobal() || $websiteId === 0;
+ $isGlobal = $attribute->isScopeGlobal() || $this->isWebsiteGlobal((int)$websiteId);
$identifierField = $this->metadataPoll->getMetadata(ProductInterface::class)->getLinkField();
$productId = $entity->getData($identifierField);

Index: Model/Product/Attribute/Backend/TierPrice/SaveHandler.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- Model/Product/Attribute/Backend/TierPrice/SaveHandler.php (revision 1804146a601561685f54c920bf869b3f2398cb9e)
+++ Model/Product/Attribute/Backend/TierPrice/SaveHandler.php (date 1537531110000)
@@ -86,7 +86,7 @@
);
}
$websiteId = $this->storeManager->getStore($entity->getStoreId())->getWebsiteId();
- $isGlobal = $attribute->isScopeGlobal() || $websiteId === 0;
+ $isGlobal = $attribute->isScopeGlobal() || $this->isWebsiteGlobal((int)$websiteId);
$identifierField = $this->metadataPoll->getMetadata(ProductInterface::class)->getLinkField();
$priceRows = array_filter($priceRows);
$productId = $entity->getData($identifierField);
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ magento/module-configurable-product|Patch-Magento_Configurable_M2.1.x-fix-get-pr
magento/module-catalog|Patch-Magento-Catalog-M2.1.x-toolbar-default-sorting.patch|fix toolbar default sorting|>=2.1.0 <2.2.0
klarna/module-kco|Patch-Klarna_Kco-5.0.5-reload-summary-action-error-log.patch|Fix wrong function parameters order|>=5.0.5
magento/module-catalog-inventory|Patch-Magento_CatalogInventory-M2.2.0-2.2.3-fix-update-stock-item-on-product-save.patch|Fix: Update stock item on product save|>=2.2.0 <2.2.4
magento/module-catalog|Patch-Magento-Catalog-M2.2.6-fix-18154-tierprices-cant-be-updated.patch|fix updating of tier prices when price scope is set to website|2.2.6

Full composer.json example:

Expand Down Expand Up @@ -114,7 +115,8 @@ Full composer.json example:
"Fix: catalog_product_flat does not update column with empty value. Fix options linking.": "https://raw.githubusercontent.com/ConvertGroupsAS/magento2-patches/master/Patch-Magento_Catalog-M2.1.4-product-flat-indexer-v2.patch",
"Fix: https://github.com/magento/magento2/issues/4387": "https://raw.githubusercontent.com/ConvertGroupsAS/magento2-patches/master/Patch-Magento_Catalog-M2.1-fix-product-auto-startdates.patch",
"Fix: https://github.com/magento/magento2/issues/7874": "https://raw.githubusercontent.com/ConvertGroupsAS/magento2-patches/master/Patch-Magento_Catalog-M2.1.4-regeneration-without-changes-fix.patch",
"Fix: Change toolbar default sorting": "https://raw.githubusercontent.com/ConvertGroupsAS/magento2-patches/master/Patch-Magento-Catalog-M2.1.x-toolbar-default-sorting.patch"
"Fix: Change toolbar default sorting": "https://raw.githubusercontent.com/ConvertGroupsAS/magento2-patches/master/Patch-Magento-Catalog-M2.1.x-toolbar-default-sorting.patch",
"Fix: https://github.com/magento/magento2/issues/18154": "https://raw.githubusercontent.com/ConvertGroupsAS/magento2-patches/master/Patch-Magento-Catalog-M2.2.6-fix-18154-tierprices-cant-be-updated.patch"
},
"magento/module-catalog-inventory": {
"Fix: https://github.com/magento/magento2/issues/8566": "https://raw.githubusercontent.com/ConvertGroupsAS/magento2-patches/master/Patch-Magento_CatalogInventory_M2.1.3-hide-out-of-stock.patch",
Expand Down