package com.lightinit.hsdatashow.controller.topic.water;

import com.lightinit.hsdatashow.model.ResultState;
import com.lightinit.hsdatashow.service.topic.water.IFloodAndDryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.servlet.ModelAndView;

/**
 * @Author: sunxiang
 * @Date: 2018/12/22 10:29
 * @Description:
 **/
@Controller
@RequestMapping(value="/topic/water/floodAndDry/")
public class FloodAndDryController {

    @Autowired
    private IFloodAndDryService floodAndDryService;
    @RequestMapping(value = "index.htm")
    public ModelAndView index(){
        ModelAndView modelAndView = new ModelAndView("topic/water/floodAndDry/index");
        return modelAndView;
    }

    /*
    *@Description 汛期预警
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getxunqiyujing.action")
    @ResponseBody
    public ResultState getxunqiyujing(){
        return floodAndDryService.getxunqiyujing();
    }

    /*
    *@Description 今日暴雨
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getjinribaoyu.action")
    @ResponseBody
    public ResultState getjinribaoyu(){
        return floodAndDryService.getjinribaoyu();
    }

    /*
    *@Description 今日降雨变化
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getjinrijiangyubianhua.action")
    @ResponseBody
    public ResultState getjinrijiangyubianhua(){
        return floodAndDryService.getjinrijiangyubianhua();
    }

    /*
    *@Description 全市可用水总量
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getquanshikeyongzongshuiliang.action")
    @ResponseBody
    public ResultState getquanshikeyongzongshuiliang(){
        return floodAndDryService.getquanshikeyongzongshuiliang();
    }

 /*
    *@Description 全市蓄水总量
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getquanshixushuizongliang.action")
    @ResponseBody
    public ResultState getquanshixushuizongliang(){
        return floodAndDryService.getquanshixushuizongliang();
    }

     /*
    *@Description 全市监测站总数
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getquanshijianchezhanzongshu.action")
    @ResponseBody
    public ResultState getquanshijianchezhanzongshu(){
        return floodAndDryService.getquanshijianchezhanzongshu();
    }

 /*
    *@Description 各水库可用水量
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getgeshuikukeyongshuiliang.action")
    @ResponseBody
    public ResultState getgeshuikukeyongshuiliang(){
        return floodAndDryService.getgeshuikukeyongshuiliang();
    }

    /*
    *@Description 各水库个月可用水量变化
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getshuikugeyueshuiliang.action")
    @ResponseBody
    public ResultState getshuikugeyueshuiliang(){
        return floodAndDryService.getshuikugeyueshuiliang();
    }

 /*
    *@Description 各水库蓄水量
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getgeshuikuxushuiliang.action")
    @ResponseBody
    public ResultState getgeshuikuxushuiliang(){
        return floodAndDryService.getgeshuikuxushuiliang();
    }

    /*
    *@Description 各水库蓄水量变化
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getgeshuikuxushuiliangbianhua.action")
    @ResponseBody
    public ResultState getgeshuikuxushuiliangbianhua(){
        return floodAndDryService.getgeshuikuxushuiliangbianhua();
    }


    /*
    *@Description 监测站构成图
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getjiancezhangouchengtu.action")
    @ResponseBody
    public ResultState getjiancezhangouchengtu(){
        return floodAndDryService.getjiancezhangouchengtu();
    }

  /*
    *@Description 监测站构成图
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getgeqvxianguochengtu.action")
    @ResponseBody
    public ResultState getgeqvxianguochengtu(String stationType){
       /* return floodAndDryService.getgeqvxianguochengtu();*/
        return floodAndDryService.getgeqvxianguochengtu(stationType);
    }

     /*
    *@Description 全市工程总数
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getquanshigongchengzongshu.action")
    @ResponseBody
    public ResultState getquanshigongchengzongshu(){
        return floodAndDryService.getquanshigongchengzongshu();
    }

 /*
    *@Description 工程构成图
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getgongchengguozaotu.action")
    @ResponseBody
    public ResultState getgongchengguozaotu(){
        return floodAndDryService.getgongchengguozaotu();
    }


 /*
    *@Description 各区县构成.工程构成图
    *@Param
    *@Date 2018/12/22
    *@return
    **/
    @RequestMapping(value = "getqvxiangongchenggouzaotu.action")
    @ResponseBody
    public ResultState getqvxiangongchenggouzaotu(String projectType){

        /*return floodAndDryService.getqvxiangongchenggouzaotu();*/
        return floodAndDryService.getqvxiangongchenggouzaotu(projectType);
    }



}
