修改了get_weather方法,现在可以实现前端的需求了

This commit is contained in:
2025-09-27 17:29:46 +08:00
parent 6d680260a2
commit 02703de89c
3 changed files with 37 additions and 7 deletions

View File

@@ -82,8 +82,8 @@ pub struct WeatherDataBrief {
#[sqlx(rename = "min")]
pub min: i32,
pub longitude: f64,
pub latidute: f64,
pub longitude: String,
pub latitude: String,
}
// 在models.rs中添加可放在WeatherDataBrief下方
@@ -151,8 +151,8 @@ pub struct WeatherData {
#[sqlx(rename = "inspectiontype")]
pub inspection_type: Option<String>,
pub latitude: f64,
pub longitude: f64,
pub latitude: String,
pub longitude: String,
#[serde(rename = "lowCloudiness")]
#[sqlx(rename = "lowcloudiness")]