lekss361
|
07cbcd235b
|
feat(tradein): cian price-change badges + split price-history chart
Backend:
- New GET /api/v1/trade-in/estimate/{id}/cian-price-changes — per-analog
price change stats (n_changes, last_diff_pct, total_change_pct) из
offer_price_history (cian playwright_history backfill, 268+ rows).
- house-analytics: PriceHistoryYearPoint gains source field; SQL теперь
GROUP BY year, source → 2 серии для chart (avito_imv / yandex_valuation).
Frontend:
- ListingsCard показывает colored badge ↓N ±X.X% рядом с ценой cian-аналога
если есть price changes (зелёный = снижение, красный = рост).
- PriceHistoryChart: pivot long→wide format client-side, 2 Line components
(синий Avito #2563eb, оранжевый Яндекс #ea580c) + Legend, connectNulls.
Использует данные:
- offer_price_history (live cian price changes)
- house_placement_history.source разделение avito_imv vs yandex_valuation
|
2026-05-24 21:16:03 +03:00 |
|