修改了convertedwindspeed为float

This commit is contained in:
2025-10-17 19:39:12 +08:00
parent e294c00c0b
commit bd60a72e68
3 changed files with 20 additions and 37 deletions

View File

@@ -169,10 +169,9 @@ pub struct WeatherData {
// --- 以下是修改的重点 ---
// 这些字段在前端是条件性发送的,因此在 Rust 中也必须是可选的
#[serde(rename = "convertedWindSpeed")]
#[sqlx(rename = "convertedwindspeed")]
pub converted_wind_speed: Option<i32>, // <-- 修改: i32 -> Option<i32>
pub converted_wind_speed: Option<f64>,
pub date: NaiveDate,