Load nearby stations before opening intraday analysis

This commit is contained in:
2569718930@qq.com
2026-04-12 20:49:51 +08:00
parent a0adf05d1e
commit a27ae564fb
6 changed files with 64 additions and 24 deletions
+6 -1
View File
@@ -435,7 +435,12 @@ async def city_detail(
_assert_entitlement(request)
city = _normalize_city_or_404(name)
normalized_depth = str(depth or "panel").strip().lower()
detail_mode = "full" if normalized_depth == "full" else "panel"
if normalized_depth == "full":
detail_mode = "full"
elif normalized_depth == "nearby":
detail_mode = "nearby"
else:
detail_mode = "panel"
return await run_in_threadpool(_analyze, city, force_refresh, False, detail_mode)