Commit 7c64b560 authored by chenzhao's avatar chenzhao

修改bug

parent 789f9d37
...@@ -80,42 +80,42 @@ public class TdHYGFInverterDayGenerate implements Serializable { ...@@ -80,42 +80,42 @@ public class TdHYGFInverterDayGenerate implements Serializable {
/** /**
* 交流电压1 * 交流电压1
*/ */
@ExcelProperty("交流电压1(V)") @ExcelProperty("交流电压U(V)")
private Double dcv1; private Double dcv1;
/** /**
* 交流电压2 * 交流电压2
*/ */
@ExcelProperty("交流电压2(V)") @ExcelProperty("交流电压V(V)")
private Double dcv2; private Double dcv2;
/** /**
* 交流电压3 * 交流电压3
*/ */
@ExcelProperty("交流电压3(V)") @ExcelProperty("交流电压W(V)")
private Double dcv3; private Double dcv3;
/** /**
* 交流电压4 * 交流电压4
*/ */
@ExcelProperty("交流电压4(V)") @ExcelIgnore
private Double dcv4; private Double dcv4;
/** /**
* 交流电流1 * 交流电流1
*/ */
@ExcelProperty("交流电流1(A)") @ExcelProperty("交流电流U(A)")
private Double dcc1; private Double dcc1;
/** /**
* 交流电流2 * 交流电流2
*/ */
@ExcelProperty("交流电流2(A)") @ExcelProperty("交流电流V(A)")
private Double dcc2; private Double dcc2;
/** /**
* 交流电流3 * 交流电流3
*/ */
@ExcelProperty("交流电流3(A)") @ExcelProperty("交流电流W(A)")
private Double dcc3; private Double dcc3;
/** /**
* 交流电流4 * 交流电流4
*/ */
@ExcelProperty("交流电流4(A)") @ExcelIgnore
private Double dcc4; private Double dcc4;
/** /**
......
...@@ -178,7 +178,7 @@ ...@@ -178,7 +178,7 @@
<if test="dto.area!=null"> <if test="dto.area!=null">
and hygf_jp_station.area like concat(concat("%",#{dto.area}),"%") and hygf_jp_station.area like concat(concat("%",#{dto.area}),"%")
</if> </if>
<if test="dto.thirdStationIds!=null"> <if test="dto.thirdStationIds!=null and dto.thirdStationIds.size()> 0 ">
and hygf_jp_station.third_station_id in and hygf_jp_station.third_station_id in
<foreach collection="dto.thirdStationIds" item="item" index="index" open="(" separator="," close=")"> <foreach collection="dto.thirdStationIds" item="item" index="index" open="(" separator="," close=")">
#{item} #{item}
......
package com.yeejoin.amos.boot.module.hygf.biz.controller; package com.yeejoin.amos.boot.module.hygf.biz.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.yeejoin.amos.boot.biz.common.utils.DateUtils;
import com.yeejoin.amos.boot.module.hygf.api.config.UserLimits; import com.yeejoin.amos.boot.module.hygf.api.config.UserLimits;
import com.yeejoin.amos.boot.module.hygf.api.dto.JpStationDto; import com.yeejoin.amos.boot.module.hygf.api.dto.JpStationDto;
import com.yeejoin.amos.boot.module.hygf.api.entity.JpPersonStation; import com.yeejoin.amos.boot.module.hygf.api.entity.JpPersonStation;
...@@ -17,10 +18,9 @@ import io.swagger.annotations.Api; ...@@ -17,10 +18,9 @@ import io.swagger.annotations.Api;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import com.yeejoin.amos.boot.biz.common.controller.BaseController; import com.yeejoin.amos.boot.biz.common.controller.BaseController;
import java.util.ArrayList; import java.text.ParseException;
import java.util.HashMap; import java.text.SimpleDateFormat;
import java.util.List; import java.util.*;
import java.util.Map;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import com.yeejoin.amos.boot.module.hygf.biz.service.impl.TdHygfJpInverterWarnServiceImpl; import com.yeejoin.amos.boot.module.hygf.biz.service.impl.TdHygfJpInverterWarnServiceImpl;
...@@ -252,7 +252,7 @@ public class TdHygfJpInverterWarnController extends BaseController { ...@@ -252,7 +252,7 @@ public class TdHygfJpInverterWarnController extends BaseController {
Page<TdHygfJpInverterWarnDto> result = new Page<>(); Page<TdHygfJpInverterWarnDto> result = new Page<>();
JpStationDto reviewDto = new JpStationDto(); JpStationDto reviewDto = new JpStationDto();
Map<String, String> nameMaps = new HashMap<>(); Map<String, String> nameMaps = new HashMap<>();
if (null != stationName){ if (null != stationName && stationName != ""){
reviewDto.setName(stationName); reviewDto.setName(stationName);
} }
List<JpStation> jpStation = jpStationMapper.getJpStation(reviewDto); List<JpStation> jpStation = jpStationMapper.getJpStation(reviewDto);
...@@ -264,8 +264,13 @@ public class TdHygfJpInverterWarnController extends BaseController { ...@@ -264,8 +264,13 @@ public class TdHygfJpInverterWarnController extends BaseController {
String startTime =""; String startTime ="";
String endTime = ""; String endTime = "";
if (null != time){ if (null != time){
startTime = time.get(0);
endTime = time.get(1); try {
startTime = String.valueOf( DateUtils.dateParse(time.get(0), null).getTime());
endTime = String.valueOf( DateUtils.dateParse(time.get(1), null).getTime());
} catch (ParseException e) {
e.printStackTrace();
}
} }
if (StringUtils.isNotEmpty(snCode)){ if (StringUtils.isNotEmpty(snCode)){
snCode = '%'+snCode+'%'; snCode = '%'+snCode+'%';
......
...@@ -449,7 +449,7 @@ public class JpStationServiceImpl extends BaseService<JpStationDto,JpStation,JpS ...@@ -449,7 +449,7 @@ public class JpStationServiceImpl extends BaseService<JpStationDto,JpStation,JpS
hd.setState(jpStation.getState()); hd.setState(jpStation.getState());
hd.setThirdStationId(jpStation.getThirdStationId()); hd.setThirdStationId(jpStation.getThirdStationId());
hd.setAccumulatedPower(jpStation.getAccumulatedPower()); hd.setAccumulatedPower(jpStation.getAccumulatedPower());
hd.setFullhour(Double.valueOf(String.format("%.2f", jpStation.getAccumulatedPower()/jpStation.getCapacity()))); hd.setFullhour(Double.valueOf(String.format("%.2f", jpStation.getAccumulatedPower()*1000/jpStation.getRatedPower())));
hd.setAccumulatedPower(jpStation.getAccumulatedPower()); hd.setAccumulatedPower(jpStation.getAccumulatedPower());
hd.setCumulativeIncome(jpStation.getCumulativeIncome()); hd.setCumulativeIncome(jpStation.getCumulativeIncome());
ld.add(hd); ld.add(hd);
......
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