|
@@ -16,10 +16,7 @@ import io.swagger.annotations.ApiImplicitParam;
|
|
|
import io.swagger.annotations.ApiImplicitParams;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
import org.springframework.stereotype.Controller;
|
|
|
-import org.springframework.web.bind.annotation.GetMapping;
|
|
|
-import org.springframework.web.bind.annotation.PostMapping;
|
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
-import org.springframework.web.bind.annotation.ResponseBody;
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
import java.util.*;
|
|
@@ -32,7 +29,7 @@ public class LeaderboardController {
|
|
|
private LeaderboardService leaderboardService;
|
|
|
|
|
|
/**查询拟合优度列表**/
|
|
|
- @GetMapping("/fittingtoplist")
|
|
|
+ @PostMapping("/fittingtoplist")
|
|
|
@ResponseBody
|
|
|
@ApiOperation(value = "查询拟合优度列表", notes = "查询拟合优度列表")
|
|
|
@ApiImplicitParams({
|
|
@@ -41,7 +38,7 @@ public class LeaderboardController {
|
|
|
@ApiImplicitParam(name = "beginDate", value = "开始日期", required = true, dataType = "string", paramType = "query"),
|
|
|
@ApiImplicitParam(name = "endDate", value = "结束日期", required = true, dataType = "string", paramType = "query")})
|
|
|
|
|
|
- public AjaxResult fittingtoplist(Tablepar tablepar, String wpIps, String beginDate, String endDate) {
|
|
|
+ public AjaxResult fittingtoplist(@RequestBody Tablepar tablepar, String wpIps, String beginDate, String endDate) {
|
|
|
|
|
|
Date beginDate_d=null;
|
|
|
Date endDate_d=null;
|
|
@@ -61,7 +58,7 @@ public class LeaderboardController {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- if (tablepar.getOrderByColumn().equals("power")) {
|
|
|
+ if (StringUtils.notEmp(tablepar.getOrderByColumn()) && tablepar.getOrderByColumn().equals("power")) {
|
|
|
if (tablepar.getIsAsc().equals("asc")) {
|
|
|
Collections.sort(vos, new Comparator<StatisticalAnalysisTopVo>() {
|
|
|
public int compare(StatisticalAnalysisTopVo arg0, StatisticalAnalysisTopVo arg1) {
|
|
@@ -78,7 +75,7 @@ public class LeaderboardController {
|
|
|
|
|
|
});
|
|
|
}
|
|
|
- } else if (tablepar.getOrderByColumn().equals("speed")) {
|
|
|
+ } else if (StringUtils.notEmp(tablepar.getOrderByColumn()) && tablepar.getOrderByColumn().equals("speed")) {
|
|
|
if (tablepar.getIsAsc().equals("asc")) {
|
|
|
Collections.sort(vos, new Comparator<StatisticalAnalysisTopVo>() {
|
|
|
public int compare(StatisticalAnalysisTopVo arg0, StatisticalAnalysisTopVo arg1) {
|
|
@@ -139,7 +136,7 @@ public class LeaderboardController {
|
|
|
}
|
|
|
|
|
|
/**查询总发电量排行列表**/
|
|
|
- @GetMapping("/totalPowerCapacityTopList")
|
|
|
+ @PostMapping("/totalPowerCapacityTopList")
|
|
|
@ResponseBody
|
|
|
@ApiOperation(value = "查询总发电量排行列表", notes = "查询总发电量排行列表")
|
|
|
@ApiImplicitParams({
|
|
@@ -148,7 +145,7 @@ public class LeaderboardController {
|
|
|
@ApiImplicitParam(name = "beginDate", value = "开始日期", required = true, dataType = "string", paramType = "query"),
|
|
|
@ApiImplicitParam(name = "endDate", value = "结束日期", required = true, dataType = "string", paramType = "query")})
|
|
|
|
|
|
- public AjaxResult totalPowerCapacityTopList(Tablepar tablepar, String wpIps, String beginDate, String endDate) {
|
|
|
+ public AjaxResult totalPowerCapacityTopList(@RequestBody Tablepar tablepar, String wpIps, String beginDate, String endDate) {
|
|
|
|
|
|
Date beginDate_d=null;
|
|
|
Date endDate_d=null;
|
|
@@ -163,7 +160,7 @@ public class LeaderboardController {
|
|
|
List<StatisticalAnalysisTopVo> vos= leaderboardService.totalPowerCapacityTopList(wpIps, beginDate_d, endDate_d);
|
|
|
|
|
|
|
|
|
- if (tablepar.getOrderByColumn().equals("power")) {
|
|
|
+ if (StringUtils.notEmp(tablepar.getOrderByColumn()) && tablepar.getOrderByColumn().equals("power")) {
|
|
|
if (tablepar.getIsAsc().equals("asc")) {
|
|
|
Collections.sort(vos, new Comparator<StatisticalAnalysisTopVo>() {
|
|
|
public int compare(StatisticalAnalysisTopVo arg0, StatisticalAnalysisTopVo arg1) {
|
|
@@ -180,7 +177,7 @@ public class LeaderboardController {
|
|
|
|
|
|
});
|
|
|
}
|
|
|
- } else if (tablepar.getOrderByColumn().equals("speed")) {
|
|
|
+ } else if (StringUtils.notEmp(tablepar.getOrderByColumn()) && tablepar.getOrderByColumn().equals("speed")) {
|
|
|
if (tablepar.getIsAsc().equals("asc")) {
|
|
|
Collections.sort(vos, new Comparator<StatisticalAnalysisTopVo>() {
|
|
|
public int compare(StatisticalAnalysisTopVo arg0, StatisticalAnalysisTopVo arg1) {
|
|
@@ -197,7 +194,7 @@ public class LeaderboardController {
|
|
|
|
|
|
});
|
|
|
}
|
|
|
- } else if (tablepar.getOrderByColumn().equals("generatingcapacity")) {
|
|
|
+ } else if (StringUtils.notEmp(tablepar.getOrderByColumn()) && tablepar.getOrderByColumn().equals("generatingcapacity")) {
|
|
|
if (tablepar.getIsAsc().equals("asc")) {
|
|
|
Collections.sort(vos, new Comparator<StatisticalAnalysisTopVo>() {
|
|
|
public int compare(StatisticalAnalysisTopVo arg0, StatisticalAnalysisTopVo arg1) {
|
|
@@ -226,7 +223,7 @@ public class LeaderboardController {
|
|
|
|
|
|
|
|
|
/**查询利用率排行榜列表**/
|
|
|
- @GetMapping("/utilizationList")
|
|
|
+ @PostMapping("/utilizationList")
|
|
|
@ResponseBody
|
|
|
@ApiOperation(value = "查询总发电量排行列表", notes = "查询总发电量排行列表")
|
|
|
@ApiImplicitParams({
|
|
@@ -236,7 +233,7 @@ public class LeaderboardController {
|
|
|
@ApiImplicitParam(name = "endDate", value = "结束日期", required = true, dataType = "string", paramType = "query"),
|
|
|
@ApiImplicitParam(name = "type", value = "类型 0:风场,1:项目,2:线路,3:风机,", required = true, dataType = "string", paramType = "query")})
|
|
|
|
|
|
- public AjaxResult utilizationList(Tablepar tablepar, String wpId, String beginDate, String endDate,String type) {
|
|
|
+ public AjaxResult utilizationList(@RequestBody Tablepar tablepar, String wpId, String beginDate, String endDate,String type) {
|
|
|
|
|
|
Date beginDate_d=null;
|
|
|
Date endDate_d=null;
|
|
@@ -261,7 +258,7 @@ public class LeaderboardController {
|
|
|
}
|
|
|
|
|
|
/**查询损失率排行榜列表**/
|
|
|
- @GetMapping("/lossList")
|
|
|
+ @PostMapping("/lossList")
|
|
|
@ResponseBody
|
|
|
@ApiOperation(value = "查询损失率排行榜列表", notes = "查询损失率排行榜列表")
|
|
|
@ApiImplicitParams({
|
|
@@ -271,7 +268,7 @@ public class LeaderboardController {
|
|
|
@ApiImplicitParam(name = "endDate", value = "结束日期", required = true, dataType = "string", paramType = "query"),
|
|
|
@ApiImplicitParam(name = "type", value = "类型 0:风场,1:项目,2:线路,3:风机,", required = true, dataType = "string", paramType = "query")})
|
|
|
|
|
|
- public AjaxResult lossList(Tablepar tablepar, String wpId, String beginDate, String endDate,String type) {
|
|
|
+ public AjaxResult lossList(@RequestBody Tablepar tablepar, String wpId, String beginDate, String endDate,String type) {
|
|
|
|
|
|
Date beginDate_d=null;
|
|
|
Date endDate_d=null;
|
|
@@ -295,7 +292,7 @@ public class LeaderboardController {
|
|
|
}
|
|
|
|
|
|
/**查询负荷率排行榜列表**/
|
|
|
- @GetMapping("/loadfactortoplist")
|
|
|
+ @PostMapping("/loadfactortoplist")
|
|
|
@ResponseBody
|
|
|
@ApiOperation(value = "查询负荷率排行榜列表", notes = "查询负荷率排行榜列表")
|
|
|
@ApiImplicitParams({
|
|
@@ -305,7 +302,7 @@ public class LeaderboardController {
|
|
|
@ApiImplicitParam(name = "beginDate", value = "开始日期", required = true, dataType = "string", paramType = "query"),
|
|
|
@ApiImplicitParam(name = "endDate", value = "结束日期", required = true, dataType = "string", paramType = "query")})
|
|
|
|
|
|
- public AjaxResult loadfactortoplist(Tablepar tablepar,String type, String wpId, String beginDate, String endDate) {
|
|
|
+ public AjaxResult loadfactortoplist(@RequestBody Tablepar tablepar,String type, String wpId, String beginDate, String endDate) {
|
|
|
|
|
|
|
|
|
Date beginDate_d=null;
|
|
@@ -383,7 +380,7 @@ public class LeaderboardController {
|
|
|
}
|
|
|
|
|
|
/**查询报警排行榜列表**/
|
|
|
- @GetMapping("/querywarningStatistical")
|
|
|
+ @PostMapping("/querywarningStatistical")
|
|
|
@ResponseBody
|
|
|
@ApiOperation(value = "查询报警排行榜列表", notes = "查询报警排行榜列表")
|
|
|
@ApiImplicitParams({
|
|
@@ -392,7 +389,7 @@ public class LeaderboardController {
|
|
|
@ApiImplicitParam(name = "beginDate", value = "开始日期", required = true, dataType = "string", paramType = "query"),
|
|
|
@ApiImplicitParam(name = "endDate", value = "结束日期", required = true, dataType = "string", paramType = "query")})
|
|
|
|
|
|
- public AjaxResult querywarningStatistical(Tablepar tablepar, String type, String beginDate, String endDate) {
|
|
|
+ public AjaxResult querywarningStatistical(@RequestBody Tablepar tablepar, String type, String beginDate, String endDate) {
|
|
|
|
|
|
Date beginDate_d=null;
|
|
|
Date endDate_d=null;
|
|
@@ -450,7 +447,7 @@ public class LeaderboardController {
|
|
|
}
|
|
|
/*******************************************************************************************************************************/
|
|
|
/**查询日曲线偏差率列表**/
|
|
|
- @GetMapping("/curvefittingmainList")
|
|
|
+ @PostMapping("/curvefittingmainList")
|
|
|
@ResponseBody
|
|
|
@ApiOperation(value = "查询日曲线偏差率列表", notes = "查询日曲线偏差率列表")
|
|
|
@ApiImplicitParams({
|
|
@@ -458,7 +455,7 @@ public class LeaderboardController {
|
|
|
@ApiImplicitParam(name = "wpId", value = "风场编号", required = true, dataType = "string", paramType = "query"),
|
|
|
@ApiImplicitParam(name = "recorddate", value = "日期", required = true, dataType = "string", paramType = "query")})
|
|
|
|
|
|
- public AjaxResult curvefittingmainList(Tablepar tablepar, String wpId, String recorddate) {
|
|
|
+ public AjaxResult curvefittingmainList(@RequestBody Tablepar tablepar, String wpId, String recorddate) {
|
|
|
List<Curvefittingmain> vos=new ArrayList<>();
|
|
|
if (StringUtils.isNotEmpty(recorddate))
|
|
|
{
|
|
@@ -575,7 +572,7 @@ public class LeaderboardController {
|
|
|
|
|
|
/*******************************************************************************************************************************/
|
|
|
/**查询月曲线偏差率列表**/
|
|
|
- @GetMapping("/curvefittingmonthmainList")
|
|
|
+ @PostMapping("/curvefittingmonthmainList")
|
|
|
@ResponseBody
|
|
|
@ApiOperation(value = "查询月曲线偏差率列表", notes = "查询月曲线偏差率列表")
|
|
|
@ApiImplicitParams({
|
|
@@ -584,7 +581,7 @@ public class LeaderboardController {
|
|
|
@ApiImplicitParam(name = "year", value = "年份", required = true, dataType = "string", paramType = "query"),
|
|
|
@ApiImplicitParam(name = "month", value = "月份", required = true, dataType = "string", paramType = "query")})
|
|
|
|
|
|
- public AjaxResult curvefittingmonthmainList(Tablepar tablepar, String wpId, String year,String month) {
|
|
|
+ public AjaxResult curvefittingmonthmainList(@RequestBody Tablepar tablepar, String wpId, String year,String month) {
|
|
|
|
|
|
List<Curvefittingmonthmain> vos= leaderboardService.curvefittingmonthmainList( tablepar, wpId, year, month);
|
|
|
|