增加注释
This commit is contained in:
parent
ae89050d8d
commit
bd4bac2ced
@ -3,6 +3,7 @@ package cn.iocoder.yudao.module.datacenter.controller.admin.weather;
|
||||
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||
import cn.iocoder.yudao.module.datacenter.controller.admin.weather.vo.WeatherInfoVO;
|
||||
import cn.iocoder.yudao.module.datacenter.utlis.GoodWeatherUtil;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
@ -18,6 +19,7 @@ import org.springframework.web.bind.annotation.RestController;
|
||||
@Validated
|
||||
public class WeatherApi {
|
||||
@GetMapping(value = "/getWeather")
|
||||
@Operation(summary = "获得输入城市的天气")
|
||||
public CommonResult<WeatherInfoVO> getWeather(String cityCode) {
|
||||
String weatherData = GoodWeatherUtil.getWeatherData(cityCode);
|
||||
WeatherInfoVO weatherInfo = GoodWeatherUtil.GetWeather(weatherData);
|
||||
|
Loading…
Reference in New Issue
Block a user