WindTowerCalculationDataController.java 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159
  1. package com.jiayue.biz.controller;
  2. import com.jiayue.biz.service.WindTowerCalculationDataService;
  3. import com.jiayue.common.core.controller.BaseController;
  4. import com.jiayue.common.core.domain.AjaxResult;
  5. import com.jiayue.common.core.page.TableDataInfo;
  6. import lombok.RequiredArgsConstructor;
  7. import org.springframework.beans.factory.annotation.Autowired;
  8. import org.springframework.web.bind.annotation.*;
  9. import java.util.Date;
  10. /**
  11. * 测风塔计算数据Controller
  12. *
  13. * @author tl
  14. * @date 2022-05-24
  15. */
  16. @RequiredArgsConstructor(onConstructor_ = @Autowired)
  17. @RestController
  18. @RequestMapping("/dataQuery/windTowerCalculationData")
  19. public class WindTowerCalculationDataController extends BaseController {
  20. private final WindTowerCalculationDataService windTowerCalculationDataService;
  21. /**
  22. * 月平均风切变
  23. *
  24. * @param time 时间
  25. * @param height 层高
  26. * @param eqId 设备id
  27. * @return
  28. * @throws Exception
  29. */
  30. @GetMapping(value = "/getWindShearByEqidAndAverageAndTime")
  31. public AjaxResult getWindShearByEqidAndAverageAndTime(Long startTime,Long endTime, String height, String eqId) {
  32. return AjaxResult.success(windTowerCalculationDataService.getWindShearByEqidAndAverageAndTime(startTime,endTime, height, eqId));
  33. }
  34. /**
  35. * 平均风速(统计曲线图)
  36. *
  37. * @param startTime 开始时间
  38. * @param endTime 结束时间
  39. * @param height 层高
  40. * @param eqId 场站编号
  41. * @return
  42. */
  43. @GetMapping(value = "/getWindSpeedByEqidAndTime")
  44. public TableDataInfo getWs(Long startTime, Long endTime, String height, String eqId,String uid) {
  45. return getDataTable(windTowerCalculationDataService.getWindSpeed(startTime, endTime, height, eqId,uid));
  46. }
  47. /**
  48. * 平均湍流(统计曲线图)
  49. *
  50. * @param height 层高
  51. * @param eqId 场站编号
  52. * @return
  53. */
  54. @GetMapping(value = "/getTurbulenceByEqidAndTime")
  55. public TableDataInfo getTurbulence(Long startTime, Long endTime, String height, String eqId) {
  56. return getDataTable(windTowerCalculationDataService.getTurbulence(startTime,endTime, height, eqId));
  57. }
  58. /**
  59. * 平均空气密度(统计曲线图)
  60. *
  61. * @param startTime 开始时间
  62. * @param endTime 结束时
  63. * @param equipmentId 场站编号
  64. * @param uid 年月区分id
  65. * @return
  66. */
  67. @GetMapping(value = "/getAirDensityByEqidAndTime")
  68. public TableDataInfo getAirDensity(Long startTime, Long endTime,String equipmentId,String uid) {
  69. return getDataTable(windTowerCalculationDataService.getAirDensity(startTime, endTime,equipmentId,uid));
  70. }
  71. /**
  72. * 平均空气密度(统计曲线图)
  73. *
  74. * @param startTime 开始时间
  75. * @param endTime 结束时
  76. * @param eqId 场站编号
  77. * @param uid 年月区分id
  78. * @param height 层高
  79. * @return
  80. */
  81. @GetMapping(value = "/getWpdByEqidAndTime")
  82. public TableDataInfo getWpd(Long startTime, Long endTime, String height, String eqId,String uid) {
  83. return getDataTable(windTowerCalculationDataService.getWpd(startTime, endTime, height, eqId,uid));
  84. }
  85. /**
  86. * 平均风切变(统计曲线图)
  87. *
  88. * @param eqId 场站编号
  89. * @param height 层高
  90. * @return
  91. */
  92. @GetMapping(value = "/getShearByEqidAndTime")
  93. public TableDataInfo getShear(Long startTime, Long endTime,String height, String eqId) {
  94. return getDataTable(windTowerCalculationDataService.getShear(startTime,endTime, height, eqId));
  95. }
  96. /**
  97. * 风资源年统计(风速 + 风功率密度)
  98. * @param startTime
  99. * @param endTime
  100. * @param height
  101. * @param eqId
  102. * @return
  103. */
  104. @GetMapping(value = "/getWindResourcesByEqidAndTime")
  105. public TableDataInfo getWindResources(Long startTime, Long endTime,String height,String eqId) {
  106. return getDataTable(windTowerCalculationDataService.getWindResources(startTime,endTime, height, eqId));
  107. }
  108. /**
  109. * 风资源年统计(空气密度)
  110. * @param startTime
  111. * @param endTime
  112. * @param eqId
  113. * @return
  114. */
  115. @GetMapping(value = "/getDensityByEqIdAndTime")
  116. public TableDataInfo getDensity(Long startTime, Long endTime,String eqId) {
  117. return getDataTable(windTowerCalculationDataService.getDensityYear(startTime,endTime, eqId));
  118. }
  119. /**
  120. * Gumbel分布概率
  121. * @param startTime
  122. * @param endTime
  123. * @param eqId
  124. * @return
  125. */
  126. @GetMapping(value = "/getGumbelByEqIdAndTime")
  127. public TableDataInfo getGumbel(Long startTime, Long endTime,String eqId,String height) {
  128. return getDataTable(windTowerCalculationDataService.getGumbel(startTime,endTime, eqId,height));
  129. }
  130. }