29 private $storeManager;
55 $website = $this->getWebsiteForWebsiteScope($scopes);
63 'attribute_id = ?' =>
$attribute->getAttributeId(),
69 $condition[$identifier .
' = ?'] =
$storeId;
70 $conditions[] = $condition;
91 $website = $this->getWebsiteForWebsiteScope($scopes);
99 'attribute_id' =>
$attribute->getAttributeId(),
104 $condition[Store::STORE_ID] =
$storeId;
105 $conditions[] = $condition;
115 private function getWebsiteForWebsiteScope(array $scopes)
117 $store = $this->getStoreFromScopes($scopes);
125 private function getStoreFromScopes(array $scopes)
127 foreach ($scopes as $scope) {
128 if (Store::STORE_ID === $scope->getIdentifier()) {
129 return $this->storeManager->getStore($scope->getValue());
buildNewAttributesWebsiteScope(AbstractAttribute $attribute, EntityMetadataInterface $metadata, array $scopes, $linkFieldValue)
buildExistingAttributeWebsiteScope(AbstractAttribute $attribute, EntityMetadataInterface $metadata, array $scopes, $linkFieldValue)
__construct(StoreManagerInterface $storeManager)