◆ __construct()
- Parameters
-
\Magento\CatalogUrlRewrite\Model\Product\CanonicalUrlRewriteGenerator | $canonicalUrlRewriteGenerator | |
\Magento\CatalogUrlRewrite\Model\Product\CurrentUrlRewritesRegenerator | $currentUrlRewritesRegenerator | |
\Magento\CatalogUrlRewrite\Model\Product\CategoriesUrlRewriteGenerator | $categoriesUrlRewriteGenerator | |
\Magento\CatalogUrlRewrite\Model\ObjectRegistryFactory | $objectRegistryFactory | |
\Magento\CatalogUrlRewrite\Service\V1\StoreViewService | $storeViewService | |
\Magento\Store\Model\StoreManagerInterface | $storeManager | |
Definition at line 89 of file ProductUrlRewriteGenerator.php.
$canonicalUrlRewriteGenerator
$categoriesUrlRewriteGenerator
$currentUrlRewritesRegenerator
◆ generate()
generate |
( |
Product |
$product, |
|
|
|
$rootCategoryId = null |
|
) |
| |
Generate product url rewrites
- Parameters
-
\Magento\Catalog\Model\Product | $product | |
int | null | $rootCategoryId | |
- Returns
- \Magento\UrlRewrite\Service\V1\Data\UrlRewrite[]
Definition at line 128 of file ProductUrlRewriteGenerator.php.
137 ->addAttributeToSelect(
'url_key')
138 ->addAttributeToSelect(
'url_path');
generateForGlobalScope($productCategories, $product=null, $rootCategoryId=null)
generateForSpecificStoreView( $storeId, $productCategories, $product=null, $rootCategoryId=null)
const VISIBILITY_NOT_VISIBLE
◆ generateForGlobalScope()
generateForGlobalScope |
( |
|
$productCategories, |
|
|
|
$product = null , |
|
|
|
$rootCategoryId = null |
|
) |
| |
|
protected |
Generate list of urls for global scope
- Deprecated:
- 100.1.4
- Parameters
-
\Magento\Framework\Data\Collection | $productCategories | |
\Magento\Catalog\Model\Product | null | $product | |
int | null | $rootCategoryId | |
- Returns
- \Magento\UrlRewrite\Service\V1\Data\UrlRewrite[]
Definition at line 168 of file ProductUrlRewriteGenerator.php.
170 return $this->getProductScopeRewriteGenerator()->generateForGlobalScope(
◆ generateForSpecificStoreView()
generateForSpecificStoreView |
( |
|
$storeId, |
|
|
|
$productCategories, |
|
|
|
$product = null , |
|
|
|
$rootCategoryId = null |
|
) |
| |
|
protected |
Generate list of urls for specific store view
- Deprecated:
- 100.1.4
- Parameters
-
int | $storeId | |
\Magento\Framework\Data\Collection | $productCategories | |
Product | null | $product | |
int | null | $rootCategoryId | |
- Returns
- \Magento\UrlRewrite\Service\V1\Data\UrlRewrite[]
Definition at line 187 of file ProductUrlRewriteGenerator.php.
193 return $this->getProductScopeRewriteGenerator()
◆ isCategoryProperForGenerating()
isCategoryProperForGenerating |
( |
|
$category, |
|
|
|
$storeId |
|
) |
| |
|
protected |
◆ isGlobalScope()
isGlobalScope |
( |
|
$storeId | ) |
|
|
protected |
◆ $canonicalUrlRewriteGenerator
$canonicalUrlRewriteGenerator |
|
protected |
◆ $categoriesUrlRewriteGenerator
$categoriesUrlRewriteGenerator |
|
protected |
◆ $currentUrlRewritesRegenerator
$currentUrlRewritesRegenerator |
|
protected |
◆ $objectRegistryFactory
◆ $product
◆ $productCategories
◆ $storeManager
◆ $storeViewService
◆ ENTITY_TYPE
const ENTITY_TYPE = 'product' |
The documentation for this class was generated from the following file: