|
@@ -203,37 +203,38 @@ public class ElectricityMeteringService {
|
|
|
AtomicReference<Double> ncydl = new AtomicReference<>((double) 0);
|
|
|
proBasicPros.stream().forEach(line->{ //期次
|
|
|
try {
|
|
|
- double linerfdl = getLineValue(line.getId(), ContantXk.RFDLSYZ, currentDate, linepointmap);
|
|
|
+ double linerfdl = getLineValue(line.getId(), ContantXk.RFDLSYZ, currentDate, propointmap);
|
|
|
rfdl.updateAndGet(v -> new Double((double) (v + linerfdl)));
|
|
|
- double lineyfdl = getLineValue(line.getId(), ContantXk.YFDLSYZ, currentDate, linepointmap);
|
|
|
+ double lineyfdl = getLineValue(line.getId(), ContantXk.YFDLSYZ, currentDate, propointmap);
|
|
|
yfdl.updateAndGet(v -> new Double((double) (v + lineyfdl)));
|
|
|
- double linenfdl = getLineValue(line.getId(), ContantXk.NFDLSYZ, currentDate, linepointmap);
|
|
|
+ double linenfdl = getLineValue(line.getId(), ContantXk.NFDLSYZ, currentDate, propointmap);
|
|
|
nfdl.updateAndGet(v -> new Double((double) (v + linenfdl)));
|
|
|
- double linerswdl = getLineValue(line.getId(), ContantXk.RSWDL, currentDate, linepointmap);
|
|
|
+ double linerswdl = getLineValue(line.getId(), ContantXk.RSWDL, currentDate, propointmap);
|
|
|
rswdl.updateAndGet(v -> new Double((double) (v + linerswdl)));
|
|
|
- double lineyswdl = getLineValue(line.getId(), ContantXk.YSWDL, currentDate, linepointmap);
|
|
|
+ double lineyswdl = getLineValue(line.getId(), ContantXk.YSWDL, currentDate, propointmap);
|
|
|
yswdl.updateAndGet(v -> new Double((double) (v + lineyswdl)));
|
|
|
- double linenswdl = getLineValue(line.getId(), ContantXk.NSWDL, currentDate, linepointmap);
|
|
|
+ double linenswdl = getLineValue(line.getId(), ContantXk.NSWDL, currentDate, propointmap);
|
|
|
nswdl.updateAndGet(v -> new Double((double) (v + linenswdl)));
|
|
|
- double linergwgwdl = getLineValue(line.getId(), ContantXk.RGWGWDL, currentDate, linepointmap);
|
|
|
+ double linergwgwdl = getLineValue(line.getId(), ContantXk.RGWGWDL, currentDate, propointmap);
|
|
|
rgwgwdl.updateAndGet(v -> new Double((double) (v + linergwgwdl)));
|
|
|
- double lineygwgwdl = getLineValue(line.getId(), ContantXk.YGWGWDL, currentDate, linepointmap);
|
|
|
+ double lineygwgwdl = getLineValue(line.getId(), ContantXk.YGWGWDL, currentDate, propointmap);
|
|
|
ygwgwdl.updateAndGet(v -> new Double((double) (v + lineygwgwdl)));
|
|
|
- double linengwgwdl = getLineValue(line.getId(), ContantXk.NGWGWDL, currentDate, linepointmap);
|
|
|
+ double linengwgwdl = getLineValue(line.getId(), ContantXk.NGWGWDL, currentDate, propointmap);
|
|
|
ngwgwdl.updateAndGet(v -> new Double((double) (v + linengwgwdl)));
|
|
|
- double linernwgwdl = getLineValue(line.getId(), ContantXk.RNWGWDL, currentDate, linepointmap);
|
|
|
+ double linernwgwdl = getLineValue(line.getId(), ContantXk.RNWGWDL, currentDate, propointmap);
|
|
|
rnwgwdl.updateAndGet(v -> new Double((double) (v + linernwgwdl)));
|
|
|
- double lineynwgwdl = getLineValue(line.getId(), ContantXk.YNWGWDL, currentDate, linepointmap);
|
|
|
+ double lineynwgwdl = getLineValue(line.getId(), ContantXk.YNWGWDL, currentDate, propointmap);
|
|
|
ynwgwdl.updateAndGet(v -> new Double((double) (v + lineynwgwdl)));
|
|
|
- double linennwgwdl = getLineValue(line.getId(), ContantXk.NNWGWDL, currentDate, linepointmap);
|
|
|
+ double linennwgwdl = getLineValue(line.getId(), ContantXk.NNWGWDL, currentDate, propointmap);
|
|
|
nnwgwdl.updateAndGet(v -> new Double((double) (v + linennwgwdl)));
|
|
|
- double linercydl = getLineValue(line.getId(), ContantXk.RCYDL, currentDate, linepointmap);
|
|
|
+ double linercydl = getLineValue(line.getId(), ContantXk.RCYDL, currentDate, propointmap);
|
|
|
rcydl.updateAndGet(v -> new Double((double) (v + linercydl)));
|
|
|
- double lineycydl = getLineValue(line.getId(), ContantXk.YCYDL, currentDate, linepointmap);
|
|
|
+ double lineycydl = getLineValue(line.getId(), ContantXk.YCYDL, currentDate, propointmap);
|
|
|
ycydl.updateAndGet(v -> new Double((double) (v + lineycydl)));
|
|
|
- double linencydl = getLineValue(line.getId(), ContantXk.NCYDL, currentDate, linepointmap);
|
|
|
+ double linencydl = getLineValue(line.getId(), ContantXk.NCYDL, currentDate, propointmap);
|
|
|
ncydl.updateAndGet(v -> new Double((double) (v + linencydl)));
|
|
|
} catch (Exception e) {
|
|
|
+
|
|
|
e.printStackTrace();
|
|
|
}
|
|
|
});
|
|
@@ -278,7 +279,12 @@ public class ElectricityMeteringService {
|
|
|
}
|
|
|
|
|
|
private double getLineValue(String lineid, String uniformcode, Date currentDate, Map<String, Map<String, ProBasicPowerstationPoint>> linepointmap) throws Exception {
|
|
|
- ProBasicPowerstationPoint proBasicWppoint = linepointmap.get(lineid).get(uniformcode);
|
|
|
+ ProBasicPowerstationPoint proBasicWppoint = null;
|
|
|
+ try{
|
|
|
+ proBasicWppoint = linepointmap.get(lineid).get(uniformcode);
|
|
|
+ }catch (Exception e){
|
|
|
+ linepointmap.get(lineid).get(uniformcode);
|
|
|
+ }
|
|
|
return edosUtil.getSectionData(proBasicWppoint,currentDate.getTime()).getPointValueInDouble();
|
|
|
}
|
|
|
|