[後端] 修改api weather獲取值

This commit is contained in:
dev02 2023-11-29 15:40:35 +08:00
parent 38a0fc6996
commit 623732d9ec

View File

@ -60,13 +60,15 @@ namespace FrontendWebApi.ApiControllers
(
SELECT w.get_value
FROM api_weateher w
WHERE w.weather_type = 'T' AND @DateNow < w.start_time
WHERE w.weather_type = 'T' AND @DateNow >= w.start_time
order by created_at desc, id desc
limit 1
) AS Temp,
(
SELECT w.get_value
FROM api_weateher w
WHERE w.weather_type = 'RH' AND @DateNow < w.start_time
WHERE w.weather_type = 'RH' AND @DateNow >= w.start_time
order by created_at desc, id desc
limit 1
) AS RH
";