Features: 1) Add new sitemap path for detailed section with pagination.
Fixes: 1) Replace `DALFRelatedFieldAjax` with `DALFRelatedOnlyField` for vendor stock field. Extra: 1) Minor formatting adjustments in `api_urls.py` for readability.
This commit is contained in:
parent
cd71d78b93
commit
c7d8fcbe03
2 changed files with 15 additions and 8 deletions
|
|
@ -245,7 +245,7 @@ class ProductAdmin(FieldsetsMixin, BasicModelAdmin):
|
|||
("brand", DALFRelatedFieldAjax),
|
||||
("category", DALFRelatedFieldAjax),
|
||||
("tags", DALFRelatedFieldAjax),
|
||||
("stocks__vendor", DALFRelatedFieldAjax),
|
||||
("stocks__vendor", DALFRelatedOnlyField),
|
||||
"created",
|
||||
"modified",
|
||||
)
|
||||
|
|
|
|||
|
|
@ -59,14 +59,21 @@ urlpatterns = [
|
|||
path(
|
||||
"sitemap.xml",
|
||||
sitemap_index,
|
||||
{
|
||||
"sitemaps": sitemaps,
|
||||
"sitemap_url_name": "sitemap-index"
|
||||
},
|
||||
name="sitemap-index"
|
||||
{"sitemaps": sitemaps, "sitemap_url_name": "sitemap-detail"},
|
||||
name="sitemap-index",
|
||||
),
|
||||
path(
|
||||
"sitemap-<section>.xml",
|
||||
sitemap_detail,
|
||||
{"sitemaps": sitemaps},
|
||||
name="sitemap-detail",
|
||||
),
|
||||
path(
|
||||
"sitemap-<section>-<int:page>.xml",
|
||||
sitemap_detail,
|
||||
{"sitemaps": sitemaps},
|
||||
name="sitemap-detail",
|
||||
),
|
||||
path("sitemap-<section>.xml", sitemap_detail, {"sitemaps": sitemaps}, name="sitemap-detail"),
|
||||
path("sitemap-<section>-<int:page>.xml", sitemap_detail, {"sitemaps": sitemaps}, name="sitemap-detail"),
|
||||
path("download/<str:order_product_uuid>/", download_digital_asset_view, name="download_digital_asset"),
|
||||
path("search/", GlobalSearchView.as_view(), name="global_search"),
|
||||
path("app/cache/", CacheOperatorView.as_view(), name="cache_operator"),
|
||||
|
|
|
|||
Loading…
Reference in a new issue