可以正常使用get_weather_details获取前端指定的数据了

This commit is contained in:
2025-09-29 11:20:21 +08:00
parent 8cc75be7cd
commit 56844a537f
6 changed files with 212 additions and 146 deletions

View File

@@ -19,6 +19,15 @@ pub struct Claims {
pub user_type: i32,
}
// 临时访问用 token
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct TempTokenClaims {
pub exp: i64, // 过期时间(时间戳)
pub iat: i64, // 签发时间
pub openid: String, // 用户身份标识
pub resource_id: i32, // 允许访问的资源ID如天气数据id
}
#[derive(Debug, Deserialize)]
pub struct WeChatLoginRequest {
pub code: String,