Sitemap

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
7 年 前
Hi,

Where is the number of products to be displayed in the site map?
Problem: The products in the directory are 500, and the map shows 250.

Thanks.
7 年 前
vladundhanna wrote:
Hi,

Where is the number of products to be displayed in the site map?
Problem: The products in the directory are 500, and the map shows 250.

Thanks.


It is hard coded in c# code ==>See the following code
\Nop.Web\Factories\CommonModelFactory.cs

 
//products
                if (_commonSettings.SitemapIncludeProducts)
                {
                    //limit product to 200 until paging is supported on this page
                    var products = _productService.SearchProducts(storeId: _storeContext.CurrentStore.Id,
                        visibleIndividuallyOnly: true,
                        pageSize: 200);
                    model.Products = products.Select(product => new ProductOverviewModel
                    {
                        Id = product.Id,
                        Name = product.GetLocalized(x => x.Name),
                        ShortDescription = product.GetLocalized(x => x.ShortDescription),
                        FullDescription = product.GetLocalized(x => x.FullDescription),
                        SeName = product.GetSeName(),
                    }).ToList();
                }


Note: Nop 3.90
7 年 前
sohel wrote:
Hi,

Where is the number of products to be displayed in the site map?
Problem: The products in the directory are 500, and the map shows 250.

Thanks.

It is hard coded in c# code ==>See the following code
\Nop.Web\Factories\CommonModelFactory.cs

 
//products
                if (_commonSettings.SitemapIncludeProducts)
                {
                    //limit product to 200 until paging is supported on this page
                    var products = _productService.SearchProducts(storeId: _storeContext.CurrentStore.Id,
                        visibleIndividuallyOnly: true,
                        pageSize: 200);
                    model.Products = products.Select(product => new ProductOverviewModel
                    {
                        Id = product.Id,
                        Name = product.GetLocalized(x => x.Name),
                        ShortDescription = product.GetLocalized(x => x.ShortDescription),
                        FullDescription = product.GetLocalized(x => x.FullDescription),
                        SeName = product.GetSeName(),
                    }).ToList();
                }


Note: Nop 3.90


Thanks, Sohel :)
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.