From 8702bcdf1de0f81882e382a8eb8b17723a3de712 Mon Sep 17 00:00:00 2001 From: jianjun Date: Tue, 20 Oct 2020 09:34:10 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E4=B8=8B=E7=BA=A7=E5=92=8C?= =?UTF-8?q?=E8=87=AA=E8=BA=AB=E6=9D=83=E9=87=8D=E4=B8=8D=E5=AF=B9=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../indexcal/impl/GridCorreLationServiceImpl.java | 6 ++---- .../indexcal/impl/IndexCalculateCommunityServiceImpl.java | 7 +++---- .../indexcal/impl/IndexCalculateDistrictServiceImpl.java | 6 ++---- .../indexcal/impl/IndexCalculateStreetServiceImpl.java | 6 ++---- 4 files changed, 9 insertions(+), 16 deletions(-) diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/GridCorreLationServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/GridCorreLationServiceImpl.java index 7a65b73f72..aadeb397b8 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/GridCorreLationServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/GridCorreLationServiceImpl.java @@ -151,16 +151,14 @@ public class GridCorreLationServiceImpl implements GridCorreLationService { scoreEntity.setSelfScore(new BigDecimal(0)); scoreEntity.setSubScore(new BigDecimal(0)); scoreEntity.setParentIndexCode(index.getIndexCode()); - scoreEntity.setSelfWeight(new BigDecimal(0)); - scoreEntity.setSubWeight(new BigDecimal(0)); + scoreEntity.setSubWeight(weightMap.get(ProjectConstant.XIA_JI)); + scoreEntity.setSubWeight(weightMap.get(ProjectConstant.ZI_SHEN)); } BigDecimal partScore = score.getScore().multiply(score.getWeight()); if (selfSubParentMap.get(ProjectConstant.XIA_JI).contains(score.getIndexCode())) { scoreEntity.setSubScore(scoreEntity.getSubScore().add(partScore)); - scoreEntity.setSubWeight(weightMap.get(ProjectConstant.XIA_JI)); } else { scoreEntity.setSelfScore(scoreEntity.getSelfScore().add(partScore)); - scoreEntity.setSubWeight(weightMap.get(ProjectConstant.ZI_SHEN)); } log.debug("=====key" + key + ",grid:{},originScore:{},weight:{},finalScore:{},total", score.getGridId(), score.getScore(), score.getWeight(), partScore); }); diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateCommunityServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateCommunityServiceImpl.java index 0b0ad32dc8..bd290fd73d 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateCommunityServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateCommunityServiceImpl.java @@ -159,16 +159,15 @@ public class IndexCalculateCommunityServiceImpl implements IndexCalculateCommuni scoreEntity.setSelfScore(new BigDecimal(0)); scoreEntity.setSubScore(new BigDecimal(0)); scoreEntity.setParentIndexCode(index.getIndexCode()); - scoreEntity.setSelfWeight(new BigDecimal(0)); - scoreEntity.setSubWeight(new BigDecimal(0)); + scoreEntity.setSubWeight(weightMap.get(ProjectConstant.XIA_JI)); + scoreEntity.setSelfWeight(weightMap.get(ProjectConstant.ZI_SHEN)); } BigDecimal partScore = score.getScore().multiply(score.getWeight()); + if (selfSubParentMap.get(ProjectConstant.XIA_JI).contains(score.getIndexCode())) { scoreEntity.setSubScore(scoreEntity.getSubScore().add(partScore)); - scoreEntity.setSubWeight(weightMap.get(ProjectConstant.XIA_JI)); } else { scoreEntity.setSelfScore(scoreEntity.getSelfScore().add(partScore)); - scoreEntity.setSelfWeight(weightMap.get(ProjectConstant.ZI_SHEN)); } log.debug("=====key" + key + ",grid:{},originScore:{},weight:{},finalScore:{},total", score.getAgencyId(), score.getScore(), score.getWeight(), partScore); }); diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateDistrictServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateDistrictServiceImpl.java index f295a69d83..7ffd2dd146 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateDistrictServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateDistrictServiceImpl.java @@ -157,16 +157,14 @@ public class IndexCalculateDistrictServiceImpl implements IndexCalculateDistrict scoreEntity.setSelfScore(new BigDecimal(0)); scoreEntity.setSubScore(new BigDecimal(0)); scoreEntity.setParentIndexCode(index.getIndexCode()); - scoreEntity.setSelfWeight(new BigDecimal(0)); - scoreEntity.setSubWeight(new BigDecimal(0)); + scoreEntity.setSubWeight(weightMap.get(ProjectConstant.XIA_JI)); + scoreEntity.setSubWeight(weightMap.get(ProjectConstant.ZI_SHEN)); } BigDecimal partScore = score.getScore().multiply(score.getWeight()); if (selfSubParentMap.get(ProjectConstant.XIA_JI).contains(score.getIndexCode())) { scoreEntity.setSubScore(scoreEntity.getSubScore().add(partScore)); - scoreEntity.setSubWeight(weightMap.get(ProjectConstant.XIA_JI)); } else { scoreEntity.setSelfScore(scoreEntity.getSelfScore().add(partScore)); - scoreEntity.setSubWeight(weightMap.get(ProjectConstant.ZI_SHEN)); } log.debug("=====key" + key + ",grid:{},originScore:{},weight:{},finalScore:{},total", score.getAgencyId(), score.getScore(), score.getWeight(), partScore); }); diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateStreetServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateStreetServiceImpl.java index 842e9e3c81..d900716881 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateStreetServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateStreetServiceImpl.java @@ -161,16 +161,14 @@ public class IndexCalculateStreetServiceImpl implements IndexCalculateStreetServ scoreEntity.setSelfScore(new BigDecimal(0)); scoreEntity.setSubScore(new BigDecimal(0)); scoreEntity.setParentIndexCode(index.getIndexCode()); - scoreEntity.setSelfWeight(new BigDecimal(0)); - scoreEntity.setSubWeight(new BigDecimal(0)); + scoreEntity.setSubWeight(weightMap.get(ProjectConstant.XIA_JI)); + scoreEntity.setSelfWeight(weightMap.get(ProjectConstant.ZI_SHEN)); } BigDecimal partScore = score.getScore().multiply(score.getWeight()); if (selfSubParentMap.get(ProjectConstant.XIA_JI).contains(score.getIndexCode())) { scoreEntity.setSubScore(scoreEntity.getSubScore().add(partScore)); - scoreEntity.setSubWeight(weightMap.get(ProjectConstant.XIA_JI)); } else { scoreEntity.setSelfScore(scoreEntity.getSelfScore().add(partScore)); - scoreEntity.setSelfWeight(weightMap.get(ProjectConstant.ZI_SHEN)); } log.debug("=====key" + key + ",grid:{},originScore:{},weight:{},finalScore:{},total", score.getAgencyId(), score.getScore(), score.getWeight(), partScore); });