Commit ac8055d2 authored by tangwei's avatar tangwei

解决冲突

parents f4141ca0 36413e3c
...@@ -412,7 +412,7 @@ public class JpStationController extends BaseController { ...@@ -412,7 +412,7 @@ public class JpStationController extends BaseController {
@ApiOperation(httpMethod = "GET",value = "电站发电量统计", notes = "电站发电量统计") @ApiOperation(httpMethod = "GET",value = "电站发电量统计", notes = "电站发电量统计")
@GetMapping(value = "/getCountJpStationdata") @GetMapping(value = "/getCountJpStationdata")
@UserLimits @UserLimits
public ResponseModel< List<JpStationDto>> getCountJpStationdata(JpStationDto reviewDto) { public ResponseModel< Page<JpStationDto>> getCountJpStationdata(JpStationDto reviewDto) {
JpStationDto jpStation= jpStationMapper.getCountJpStationdata(reviewDto); JpStationDto jpStation= jpStationMapper.getCountJpStationdata(reviewDto);
List<Map<String,Object>> powerRatio=new ArrayList<>(); List<Map<String,Object>> powerRatio=new ArrayList<>();
Map<String,Object> map=new HashMap<>(); Map<String,Object> map=new HashMap<>();
...@@ -421,7 +421,11 @@ public class JpStationController extends BaseController { ...@@ -421,7 +421,11 @@ public class JpStationController extends BaseController {
jpStation.setPowerRatio(powerRatio); jpStation.setPowerRatio(powerRatio);
List<JpStationDto> list=new ArrayList<>(); List<JpStationDto> list=new ArrayList<>();
list.add(jpStation); list.add(jpStation);
return ResponseHelper.buildResponse(list); Page<JpStationDto> result = new Page<>();
result.setCurrent(1);
result.setTotal(1);
result.setRecords(list);
return ResponseHelper.buildResponse(result);
} }
//电站分布 //电站分布
...@@ -440,7 +444,9 @@ public class JpStationController extends BaseController { ...@@ -440,7 +444,9 @@ public class JpStationController extends BaseController {
@ApiOperation(httpMethod = "GET",value = "节能减排", notes = "节能减排") @ApiOperation(httpMethod = "GET",value = "节能减排", notes = "节能减排")
@GetMapping(value = "/getEnergyConservation") @GetMapping(value = "/getEnergyConservation")
@UserLimits @UserLimits
public ResponseModel< Map<String,Object>> getEnergyConservation(JpStationDto reviewDto) { public ResponseModel< Page<Map<String,Object>>> getEnergyConservation(JpStationDto reviewDto) {
Page<Map<String,Object>> result =new Page<>();
List<Map<String,Object>> itemList =new ArrayList<>();
JpStationDto jpStation= jpStationMapper.getCountJpStationdata(reviewDto); JpStationDto jpStation= jpStationMapper.getCountJpStationdata(reviewDto);
Map<String,Object> map=new HashMap<>(); Map<String,Object> map=new HashMap<>();
DecimalFormat format2 = new DecimalFormat("#.00"); DecimalFormat format2 = new DecimalFormat("#.00");
...@@ -452,7 +458,11 @@ public class JpStationController extends BaseController { ...@@ -452,7 +458,11 @@ public class JpStationController extends BaseController {
map.put("dust",format2.format(jpStation.getAccumulatedPower()*DUST)); map.put("dust",format2.format(jpStation.getAccumulatedPower()*DUST));
//煤 //煤
map.put("coal",format2.format(jpStation.getAccumulatedPower()*COAL)); map.put("coal",format2.format(jpStation.getAccumulatedPower()*COAL));
return ResponseHelper.buildResponse(map); itemList.add(map);
result.setCurrent(1);
result.setTotal(1);
result.setRecords(itemList);
return ResponseHelper.buildResponse(result);
} }
...@@ -519,8 +529,8 @@ public class JpStationController extends BaseController { ...@@ -519,8 +529,8 @@ public class JpStationController extends BaseController {
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "GET",value = "电站统计", notes = "电站统计") @ApiOperation(httpMethod = "GET",value = "电站统计", notes = "电站统计")
@GetMapping(value = "/getcountJpStation") @GetMapping(value = "/getcountJpStation")
public ResponseModel< Map<String,Object>> getcountJpStation(JpStationDto reviewDto) { public ResponseModel<Page< Map<String,Object>>> getcountJpStation(JpStationDto reviewDto) {
List<Map<String,Object>> itemList =new ArrayList<>();
Map<String,Object> collector =new HashMap<>(); Map<String,Object> collector =new HashMap<>();
collector.put("zx",0); collector.put("zx",0);
collector.put("bj",0); collector.put("bj",0);
...@@ -546,7 +556,12 @@ public class JpStationController extends BaseController { ...@@ -546,7 +556,12 @@ public class JpStationController extends BaseController {
collector.put("tc",tc.get("num")); collector.put("tc",tc.get("num"));
collector.put("jr",jr.get("num")); collector.put("jr",jr.get("num"));
collector.put("zs",zs.get("num")); collector.put("zs",zs.get("num"));
return ResponseHelper.buildResponse(collector); itemList.add(collector);
Page< Map<String,Object>> result =new Page<>();
result.setCurrent(1);
result.setTotal(1);
result.setRecords(itemList);
return ResponseHelper.buildResponse(result);
} }
//日满发小时排行 //日满发小时排行
......
...@@ -130,7 +130,8 @@ public class CommonConstans { ...@@ -130,7 +130,8 @@ public class CommonConstans {
public static final List<String> xiazaoElectricityMeter = new ArrayList<>(Arrays.asList("夏雩线212主表", "夏雩线212副表", "1号主变高压侧201", "1号主变低压侧301", public static final List<String> xiazaoElectricityMeter = new ArrayList<>(Arrays.asList("夏雩线212主表", "夏雩线212副表", "1号主变高压侧201", "1号主变低压侧301",
"35kV集电Ⅰ线311", "35kV集电Ⅱ线312", "35kV集电Ⅲ线313", "35kV集电Ⅳ线314", "35kV集电V线315", "35kV#1SVG316", "35kV#1SVG317", "35kV#1接地变307")); "35kV集电Ⅰ线311", "35kV集电Ⅱ线312", "35kV集电Ⅲ线313", "35kV集电Ⅳ线314", "35kV集电V线315", "35kV#1SVG316", "35kV#1SVG317", "35kV#1接地变307"));
public static final List<String> taiheElectricityMeter = new ArrayList<>(Arrays.asList("前光Ⅰ线", "前光Ⅱ线", "消弧线圈兼接地变", "#1SVG", "前万线")); // public static final List<String> taiheElectricityMeter = new ArrayList<>(Arrays.asList("前光Ⅰ线", "前光Ⅱ线", "消弧线圈兼接地变", "#1SVG", "前万线"));
public static final List<String> taiheElectricityMeter = new ArrayList<>(Arrays.asList("前光Ⅰ线", "前光Ⅱ线", "#1SVG", "前万线"));
public static final HashMap<String, List<String>> xiazaoElectricityMeterPointSort = new HashMap<String, List<String>>() { public static final HashMap<String, List<String>> xiazaoElectricityMeterPointSort = new HashMap<String, List<String>>() {
...@@ -153,7 +154,7 @@ public class CommonConstans { ...@@ -153,7 +154,7 @@ public class CommonConstans {
{ {
put("前光Ⅰ线", Arrays.asList("314前光Ⅰ线保测_总正向有功电度", "314前光Ⅰ线保测_总反向有功电度", "314前光Ⅰ线保测_总感性无功电度", "314前光Ⅰ线保测_总容性无功电度")); put("前光Ⅰ线", Arrays.asList("314前光Ⅰ线保测_总正向有功电度", "314前光Ⅰ线保测_总反向有功电度", "314前光Ⅰ线保测_总感性无功电度", "314前光Ⅰ线保测_总容性无功电度"));
put("前光Ⅱ线", Arrays.asList("315前光Ⅱ线保测_总正向有功电度", "315前光Ⅱ线保测_总反向有功电度", "315前光Ⅱ线保测_总感性无功电度", "315前光Ⅱ线保测_总容性无功电度")); put("前光Ⅱ线", Arrays.asList("315前光Ⅱ线保测_总正向有功电度", "315前光Ⅱ线保测_总反向有功电度", "315前光Ⅱ线保测_总感性无功电度", "315前光Ⅱ线保测_总容性无功电度"));
put("消弧线圈兼接地变", Arrays.asList("311#1消弧线圈_总正向有功电度", "311#1消弧线圈_总反向有功电度", "311#1消弧线圈_总感性无功电度", "311#1消弧线圈_总容性无功电度")); // put("消弧线圈兼接地变", Arrays.asList("311#1消弧线圈_总正向有功电度", "311#1消弧线圈_总反向有功电度", "311#1消弧线圈_总感性无功电度", "311#1消弧线圈_总容性无功电度"));
put("#1SVG", Arrays.asList("312#1SVG_总正向有功电度", "312#1SVG_总反向有功电度", "312#1SVG_总感性无功电度", "312#1SVG_总容性无功电度")); put("#1SVG", Arrays.asList("312#1SVG_总正向有功电度", "312#1SVG_总反向有功电度", "312#1SVG_总感性无功电度", "312#1SVG_总容性无功电度"));
put("前万线", Arrays.asList("313光差保护_总正向有功电度", "313光差保护_总反向有功电度", "313光差保护_总感性无功电度", "313光差保护_总容性无功电度")); put("前万线", Arrays.asList("313光差保护_总正向有功电度", "313光差保护_总反向有功电度", "313光差保护_总感性无功电度", "313光差保护_总容性无功电度"));
} }
......
...@@ -953,9 +953,8 @@ public class MonitoringServiceImpl { ...@@ -953,9 +953,8 @@ public class MonitoringServiceImpl {
List<StationBasic> stationBasicListAll = stationBasicMapper.selectList(new QueryWrapper<StationBasic>().isNotNull("fan_gateway_id")); List<StationBasic> stationBasicListAll = stationBasicMapper.selectList(new QueryWrapper<StationBasic>().isNotNull("fan_gateway_id"));
List<StationBasic> fdzList = stationBasicListAll.stream().filter(stationBasic -> stationBasic.getStationType().equals("FDZ")).collect(Collectors.toList()); List<StationBasic> fdzList = stationBasicListAll.stream().filter(stationBasic -> stationBasic.getStationType().equals("FDZ")).collect(Collectors.toList());
List<StationBasic> jzsgfdzList = stationBasicListAll.stream().filter(stationBasic -> stationBasic.getStationType().equals("JZSGFDZ")).collect(Collectors.toList()); List<StationBasic> gfList = stationBasicListAll.stream().filter(stationBasic -> stationBasic.getStationType().contains("GFDZ")).collect(Collectors.toList());
List<StationBasic> fbsgfdzList = stationBasicListAll.stream().filter(stationBasic -> stationBasic.getStationType().equals("FBSGFDZ")).collect(Collectors.toList()); List<StationBasic> cnList = stationBasicListAll.stream().filter(stationBasic -> stationBasic.getStationType().equals("CNDZ")).collect(Collectors.toList());
List<StationBasic> gfList = stationBasicListAll.stream().filter(stationBasic -> !stationBasic.getStationType().equals("FDZ")).collect(Collectors.toList());
Page<HashMap<String, String>> page = new Page<>(1, 10); Page<HashMap<String, String>> page = new Page<>(1, 10);
Page<HashMap<String, String>> page1 = new Page<>(1, 10); Page<HashMap<String, String>> page1 = new Page<>(1, 10);
Page<HashMap<String, String>> page2 = new Page<>(1, 10); Page<HashMap<String, String>> page2 = new Page<>(1, 10);
...@@ -974,17 +973,17 @@ public class MonitoringServiceImpl { ...@@ -974,17 +973,17 @@ public class MonitoringServiceImpl {
stringHashMap1.put("title", fdzInstall.toString()); stringHashMap1.put("title", fdzInstall.toString());
stringHashMap1.put("data", String.valueOf(fdzList.size())); stringHashMap1.put("data", String.valueOf(fdzList.size()));
list.add(stringHashMap1); list.add(stringHashMap1);
//集中式光伏电站 //光伏电站
HashMap<String, String> stringHashMap2 = new HashMap<>(); HashMap<String, String> stringHashMap2 = new HashMap<>();
BigDecimal jzsInstall = new BigDecimal(getInstallCapity(jzsgfdzList)); BigDecimal jzsInstall = new BigDecimal(getInstallCapity(gfList));
stringHashMap2.put("title", jzsInstall.toString()); stringHashMap2.put("title", jzsInstall.toString());
stringHashMap2.put("data", String.valueOf(jzsgfdzList.size())); stringHashMap2.put("data", String.valueOf(gfList.size()));
list.add(stringHashMap2); list.add(stringHashMap2);
//分布式光伏电 //储能
HashMap<String, String> stringHashMap3 = new HashMap<>(); HashMap<String, String> stringHashMap3 = new HashMap<>();
BigDecimal fbsInstall = new BigDecimal(getInstallCapity(fbsgfdzList)); BigDecimal fbsInstall = new BigDecimal(getInstallCapity(cnList));
stringHashMap3.put("title", fbsInstall.toString()); stringHashMap3.put("title", fbsInstall.toString());
stringHashMap3.put("data", String.valueOf(fbsgfdzList.size())); stringHashMap3.put("data", String.valueOf(cnList.size()));
list.add(stringHashMap3); list.add(stringHashMap3);
page.setRecords(list); page.setRecords(list);
BigDecimal gfInstall = new BigDecimal(getInstallCapity(gfList)); BigDecimal gfInstall = new BigDecimal(getInstallCapity(gfList));
......
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