gendesign/backend/app/services
lekss361 5878596bc5 feat(layouts): PDF ТЗ endpoint + BestLayoutsBlock UI (#113 PR D)
Backend (~330 LOC):
- POST /api/v1/parcels/{cad_num}/best-layouts/pdf via WeasyPrint
- services/exporters/layout_tz_pdf.py — HTML template с XSS-escape (html.escape)
  для cad_num/parcel_address/rationale_text/time_window
- 5 unit tests (skip on Windows если WeasyPrint deps missing)

Frontend (~800 LOC):
- BestLayoutsBlock.tsx — DataQualityCard + TopLayoutsTable + RecommendationCard
  + PDF download button (Blob → revokeObjectURL)
- useBestLayouts.ts — TanStack useMutation hook
- types/best-layouts.ts — manual TS types
- MarketTab.tsx +4 LOC integration после competitors

Pre-push fixes per review:
- XSS escape user-data в PDF HTML
- sold_pct_of_supply — убрать double ×100 (backend уже 0..100)
- alert() → pdfError state
- isNaN → Number.isNaN
- 7 inline-styles → Tailwind utilities

Phase 2.1 complete. Phase 2.2 (layout_type/balcony_count via B2B Объектив
#52) — follow-up issue.
2026-05-16 12:38:23 +03:00
..
cadastre perf(cadastre): freshness skip + grid-walk heartbeat + log noise reduction (#187) 2026-05-15 23:02:37 +03:00
exporters feat(layouts): PDF ТЗ endpoint + BestLayoutsBlock UI (#113 PR D) 2026-05-16 12:38:23 +03:00
generative deploy.yml: sync compose+Caddyfile from git, reload caddy after up 2026-04-26 13:31:26 +03:00
photos fix ui lag 2026-04-27 20:26:55 +03:00
scrapers feat(scrapers): search_by_quarter orchestrator + QuarterDump (#94 pt.2/4) (#109) 2026-05-12 18:11:30 +03:00
site_finder feat(parcels): best-layouts endpoint + service (#113 PR C) (#196) 2026-05-16 09:10:06 +00:00
__init__.py init 2026-04-25 13:45:19 +03:00
analytics_queries.py feat(velocity): migrate D2 sales source → objective_corpus_room_month (#158) 2026-05-15 09:34:00 +03:00
analytics_refresh.py fix(scrape): SQLAlchemy text() парсил ':00:' regex как named-param 2026-04-30 23:16:11 +03:00
job_settings.py fix(cadastre,nspd_sync): SQL syntax bugs surfaced by ekb_full v2 (#186) 2026-05-15 19:18:43 +03:00
objective_etl.py fix(worker): port objective_etl from psycopg2 → psycopg v3 2026-05-11 12:07:57 +03:00
objective_sync_config.py feat(objective): full sync pipeline + dynamic admin config 2026-05-10 19:54:15 +03:00