package cn.gyee.tamplate.controller;


import cn.gyee.tamplate.model.auto.Windturbine;
import cn.gyee.tamplate.service.IWindturbineService;
import oracle.jdbc.proxy.annotation.GetProxy;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author 谢生杰
 * @since 2021-01-18
 */
@RestController
@RequestMapping("//windturbine")
public class WindturbineController {
    @Autowired
    private IWindturbineService windturbineService;

    @GetMapping("/wts")
    @ResponseBody
    public List<Windturbine> getWtls(){
        return windturbineService.list();
    }
}
