Commit 27bd00be authored by tangwei's avatar tangwei

修改电站报表

parent 310e12e9
......@@ -49,6 +49,6 @@ public class DayGenerate {
@TableField("income")
// 日收益
private Double dayIncome;
private Double income;
}
......@@ -52,5 +52,5 @@ public class MonthGenerate {
// 月收益
@TableField("income")
private Double monthIncome;
private Double income;
}
......@@ -50,5 +50,5 @@ public class YearGenerate {
// 年收益
@TableField("income")
private Double yearIncome;
private Double income;
}
......@@ -181,7 +181,7 @@
<if test="dto.thirdStationIds!=null">
and hygf_jp_station.third_station_id in
<foreach collection="dto.thirdStationIds" item="item" index="index" open="(" separator="," close=")">
#{item.stationId}
#{item}
</foreach>
</if>
<if test="dto.thirdStationId!=null">
......
......@@ -674,10 +674,10 @@ public class JpStationController extends BaseController {
return ResponseHelper.buildResponse(page);
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/queryReport")
@ApiOperation(httpMethod = "GET",value = "场站报表", notes = "场站报表")
@PostMapping (value = "/queryReport")
@ApiOperation(httpMethod = "POST",value = "场站报表", notes = "场站报表")
public ResponseModel<Page<JpStationDto>> queryReport(@RequestParam(value = "current") int current, @RequestParam
(value = "size") int size, JpStationDto reviewDto,String type) {
(value = "size") int size,@RequestBody JpStationDto reviewDto,@RequestParam(value = "type") String type) {
Page<JpStationDto> page=jpStationServiceImpl.queryReport(current,size,reviewDto,type);
......@@ -705,11 +705,11 @@ public class JpStationController extends BaseController {
@TycloudOperation(ApiLevel = UserType.AGENCY)
@RequestMapping(value = "/jpstationReportExport", method = RequestMethod.GET)
@ApiOperation(httpMethod = "GET", value = "电站报表导出", notes = "电站报表导出")
public void jpstationReportExport( HttpServletResponse response,JpStationDto reviewDto,String type) {
List<JpStation> jpStation=jpStationServiceImpl.getJpStation(new JpStationDto());
List<String> stationIds = jpStation.stream().map(jpStation1 -> jpStation1.getThirdStationId()).collect(Collectors.toList());
@RequestMapping(value = "/jpstationReportExport", method = RequestMethod.POST)
@ApiOperation(httpMethod = "POST", value = "电站报表导出", notes = "电站报表导出")
public void jpstationReportExport( HttpServletResponse response,@RequestBody JpStationDto reviewDto,@RequestParam(value = "type")String type) {
// List<JpStation> jpStation=jpStationServiceImpl.getJpStation(new JpStationDto());
// List<String> stationIds = jpStation.stream().map(jpStation1 -> jpStation1.getThirdStationId()).collect(Collectors.toList());
List<JpStationDto> jpStationDtos = jpStationServiceImpl.selectReportDate(reviewDto, type,response);
// try {
......
......@@ -492,7 +492,7 @@ public class JpStationServiceImpl extends BaseService<JpStationDto,JpStation,JpS
hd.setFullhour(dayGenerate.getFullhour()!=null?Double.valueOf(String.format("%.2f",dayGenerate.getFullhour())):null);
hd.setDayGenerate(dayGenerate.getGenerate());
hd.setTimeDate(dayGenerate.getDayTime());
hd.setDayIncome(dayGenerate.getDayIncome());
hd.setDayIncome(dayGenerate.getIncome());
break;
}
}
......@@ -515,7 +515,7 @@ public class JpStationServiceImpl extends BaseService<JpStationDto,JpStation,JpS
hd.setThirdStationId(jpStation.getThirdStationId());
hd.setAccumulatedPower(jpStation.getAccumulatedPower());
hd.setMonthGenerate(dayGenerate.getGenerate());
hd.setMonthIncome(dayGenerate.getMonthIncome());
hd.setMonthIncome(dayGenerate.getIncome());
hd.setTimeDate(dayGenerate.getMonthTime());
hd.setFullhour(dayGenerate.getFullhour()!=null?Double.valueOf(String.format("%.2f",dayGenerate.getFullhour())):null);
break;
......@@ -541,7 +541,7 @@ public class JpStationServiceImpl extends BaseService<JpStationDto,JpStation,JpS
hd.setThirdStationId(jpStation.getThirdStationId());
hd.setFullhour(dayGenerate.getFullhour()!=null?Double.valueOf(String.format("%.2f",dayGenerate.getFullhour())):null);
hd.setYearGenerate(dayGenerate.getGenerate());
hd.setYearIncome(dayGenerate.getYearIncome());
hd.setYearIncome(dayGenerate.getIncome());
hd.setTimeDate(dayGenerate.getYearTime());
break;
}
......@@ -633,7 +633,7 @@ public class JpStationServiceImpl extends BaseService<JpStationDto,JpStation,JpS
hd.setFullhour(dayGenerate.getFullhour()!=null?Double.valueOf(String.format("%.2f",dayGenerate.getFullhour())):null);
hd.setDayGenerate(dayGenerate.getGenerate());
hd.setTimeDate(dayGenerate.getDayTime());
hd.setDayIncome(dayGenerate.getDayIncome());
hd.setDayIncome(dayGenerate.getIncome());
break;
}
}
......@@ -654,7 +654,7 @@ public class JpStationServiceImpl extends BaseService<JpStationDto,JpStation,JpS
hd.setStationContact(jpStation.getStationContact());
hd.setAccumulatedPower(jpStation.getAccumulatedPower());
hd.setMonthGenerate(dayGenerate.getGenerate());
hd.setMonthIncome(dayGenerate.getMonthIncome());
hd.setMonthIncome(dayGenerate.getIncome());
hd.setTimeDate(dayGenerate.getMonthTime());
hd.setFullhour(dayGenerate.getFullhour()!=null?Double.valueOf(String.format("%.2f",dayGenerate.getFullhour())):null);
break;
......@@ -679,7 +679,7 @@ public class JpStationServiceImpl extends BaseService<JpStationDto,JpStation,JpS
hd.setFullhour(dayGenerate.getFullhour()!=null?Double.valueOf(String.format("%.2f",dayGenerate.getFullhour())):null);
hd.setYearGenerate(dayGenerate.getGenerate());
hd.setYearIncome(dayGenerate.getYearIncome());
hd.setYearIncome(dayGenerate.getIncome());
hd.setTimeDate(dayGenerate.getYearTime());
break;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment