feat(catalog): implement sprint 10 advanced search experience
Some checks failed
Architecture Governance / architecture (push) Has been cancelled

This commit is contained in:
sdarbinyan
2026-07-09 00:55:50 +04:00
parent 3ef0bd711d
commit 1a8f916942
40 changed files with 1917 additions and 70 deletions

View File

@@ -9,37 +9,47 @@
- API возвращает содержимое: товары, категории, метаданные фильтров.
## Обязательные JSON-свойства каталога
- catalog.settings.defaultSort
- catalog.settings.pageSize
- catalog.routes.list
- catalog.routes.details
- catalog.defaultSort
- catalog.availableSorts
- catalog.enabledFilters
- catalog.layout
## Опциональные свойства
- catalog.filters.available
- catalog.facets
- catalog.badges
- catalog.promotions
- catalog.navigationMode
- catalog.showBreadcrumbs
- catalog.showCategoryBanner
- catalog.showSubcategoryChips
- catalog.showRatings
- catalog.showDiscounts
- catalog.showAvailability
- catalog.suggestionsEnabled
- catalog.searchHistoryEnabled
- catalog.facets (future backend-driven)
## Строгие правила
- Каталог не содержит tenant-specific условий в frontend-коде.
- Сортировка и фильтры должны быть согласованы между frontend и backend.
- Видимость товаров контролируется данными backend, а не frontend-хардкодом.
## Reusable Domain Models
- SearchCriteria
- FilterDefinition
- FilterOption
- SortDefinition
- CatalogView
- SearchResult
## Пример catalog JSON (bootstrap fragment)
```json
{
"catalog": {
"settings": {
"defaultSort": "priority_desc",
"pageSize": 20
},
"routes": {
"list": "/catalog",
"details": "/product/:id"
},
"filters": {
"available": ["price", "brand", "availability"]
}
"layout": "grid",
"defaultSort": "relevance",
"availableSorts": ["relevance", "latest", "price_asc", "price_desc", "rating", "popular", "discount"],
"enabledFilters": ["price", "availability", "rating", "brand", "category", "subcategory", "discount", "new", "color", "size", "attributes"],
"showBreadcrumbs": true,
"showCategoryBanner": true,
"showSubcategoryChips": true
}
}
```