diff --git a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexAgencyScoreDao.java b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexAgencyScoreDao.java index 66cbc46d42..0c30eddd50 100644 --- a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexAgencyScoreDao.java +++ b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexAgencyScoreDao.java @@ -39,10 +39,10 @@ public interface FactIndexAgencyScoreDao { /** * @param formDTO - * @Description 分别查询区县、乡镇街道过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 + * @Description 分别查询区县、乡镇街道过去12个月党建能力、治理能力、服务能力每月各项乘以权重后的得分数据 * @author sun */ - LinkedList selectAblityIndex(AblityIndexFormDTO formDTO); + LinkedList selectAgencyAblityWeightScoreIndex(AblityIndexFormDTO formDTO); /** * @param formDTO @@ -56,5 +56,5 @@ public interface FactIndexAgencyScoreDao { * @Description 分别查询区县、乡镇街道过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 * @author sun */ - LinkedList selectMonthScoreList(MonthScoreListFormDTO formDTO); + LinkedList selectAgencyMonthWeightScoreList(MonthScoreListFormDTO formDTO); } diff --git a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexCommunityScoreDao.java b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexCommunityScoreDao.java index 0c7a7a7f65..1d1efd2b94 100644 --- a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexCommunityScoreDao.java +++ b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexCommunityScoreDao.java @@ -42,7 +42,7 @@ public interface FactIndexCommunityScoreDao { * @Description 分别查询社区过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 * @author sun */ - LinkedList selectCommunityAblityIndex(AblityIndexFormDTO formDTO); + LinkedList selectCommunityAblityWeightScore(AblityIndexFormDTO formDTO); /** * @param formDTO @@ -56,5 +56,5 @@ public interface FactIndexCommunityScoreDao { * @Description 分别查询社区过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 * @author sun */ - LinkedList selectCommunityMonthScoreList(MonthScoreListFormDTO formDTO); + LinkedList selectCommunityMonthWeightScoreList(MonthScoreListFormDTO formDTO); } diff --git a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexGridScoreDao.java b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexGridScoreDao.java index c5153b0933..8a36678362 100644 --- a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexGridScoreDao.java +++ b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/dao/fact/FactIndexGridScoreDao.java @@ -42,7 +42,7 @@ public interface FactIndexGridScoreDao { * @Description 分别查网格过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 * @author sun */ - LinkedList selectGridAblityIndex(AblityIndexFormDTO formDTO); + LinkedList selectGridAblityWeightScore(AblityIndexFormDTO formDTO); /** * @param formDTO @@ -56,5 +56,5 @@ public interface FactIndexGridScoreDao { * @Description 分别查网格过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 * @author sun */ - LinkedList selectGridMonthScoreList(MonthScoreListFormDTO formDTO); + LinkedList selectGridMonthWeightScoreList(MonthScoreListFormDTO formDTO); } diff --git a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/service/fact/impl/FactIndexServiceImpl.java b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/service/fact/impl/FactIndexServiceImpl.java index a73529b0dc..38510aa15b 100644 --- a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/service/fact/impl/FactIndexServiceImpl.java +++ b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/service/fact/impl/FactIndexServiceImpl.java @@ -79,12 +79,12 @@ public class FactIndexServiceImpl implements FactIndexService { //区县级、乡镇街道级 if ("district".equals(agency.getLevel()) || "street".equals(agency.getLevel())) { //4-1.查询过去12个月党建能力、治理能力、服务能力每月总分数据 - list = factIndexAgencyScoreDao.selectAblityIndex(formDTO); + list = factIndexAgencyScoreDao.selectAgencyAblityWeightScoreIndex(formDTO); //社区级 } else if ("community".equals(agency.getLevel())) { //4-1.查询过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 - list = factIndexCommunityScoreDao.selectCommunityAblityIndex(formDTO); + list = factIndexCommunityScoreDao.selectCommunityAblityWeightScore(formDTO); } else { //throw new RenException(String.format("根据组织Id查询到的组织级别信息错误,组织Id:%s", formDTO.getOrgId())); return resultList; @@ -92,7 +92,7 @@ public class FactIndexServiceImpl implements FactIndexService { //网格层级数据 } else if (FactConstant.GRID.equals(formDTO.getOrgType())) { //5.查询网格过去12个月党建能力、治理能力、服务能力每月总分数据 - list = factIndexGridScoreDao.selectGridAblityIndex(formDTO); + list = factIndexGridScoreDao.selectGridAblityWeightScore(formDTO); } else { throw new RenException(String.format("能力指数查询,orgType类型错误,组织Id:%s,类型Type:%s", formDTO.getOrgId(), formDTO.getOrgType())); } @@ -229,12 +229,12 @@ public class FactIndexServiceImpl implements FactIndexService { //区县级、乡镇街道级 if ("district".equals(agency.getLevel()) || "street".equals(agency.getLevel())) { //4-1.查询过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 - list = factIndexAgencyScoreDao.selectMonthScoreList(formDTO); + list = factIndexAgencyScoreDao.selectAgencyMonthWeightScoreList(formDTO); //社区级 } else if ("community".equals(agency.getLevel())) { //4-1.查询过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 - list = factIndexCommunityScoreDao.selectCommunityMonthScoreList(formDTO); + list = factIndexCommunityScoreDao.selectCommunityMonthWeightScoreList(formDTO); } else { //throw new RenException(String.format("根据组织Id查询到的组织级别信息错误,组织Id:%s", formDTO.getOrgId())); return resultList; @@ -242,7 +242,7 @@ public class FactIndexServiceImpl implements FactIndexService { //网格层级数据 } else if (FactConstant.GRID.equals(formDTO.getOrgType())) { //5.查询网格过去12个月党建能力、治理能力、服务能力每月总分、本级得分、下级得分数据 - list = factIndexGridScoreDao.selectGridMonthScoreList(formDTO); + list = factIndexGridScoreDao.selectGridMonthWeightScoreList(formDTO); } else { throw new RenException(String.format("能力指数查询,orgType类型错误,组织Id:%s,类型Type:%s", formDTO.getOrgId(), formDTO.getOrgType())); } diff --git a/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexAgencyScoreDao.xml b/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexAgencyScoreDao.xml index 484abef720..8494abf052 100644 --- a/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexAgencyScoreDao.xml +++ b/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexAgencyScoreDao.xml @@ -3,10 +3,10 @@ - SELECT fact.month_id AS "monthId", - ROUND(fact.score, 1) AS "indexTotal", + ROUND(fact.score*fact.WEIGHT, 1) AS "indexTotal", fact.index_code AS "indexCode" FROM fact_index_agency_score fact @@ -41,12 +41,12 @@ AND fact.month_id = #{monthId} - SELECT fact.month_id AS "monthId", - ROUND(fact.score, 1) AS "indexTotal", - ROUND(self.self_score, 1) AS "agencyScore", - ROUND(self.sub_score, 1) AS "subAgencyScore", + ROUND(fact.score*fact.WEIGHT, 1) AS "indexTotal", + ROUND(self.self_score*self.SELF_WEIGHT, 1) AS "agencyScore", + ROUND(self.sub_score*self.SUB_WEIGHT, 1) AS "subAgencyScore", fact.index_code AS "indexCode" FROM fact_index_agency_score fact diff --git a/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexCommunityScoreDao.xml b/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexCommunityScoreDao.xml index a2a4e89303..2bd729444b 100644 --- a/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexCommunityScoreDao.xml +++ b/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexCommunityScoreDao.xml @@ -3,10 +3,10 @@ - SELECT fact.month_id AS "monthId", - ROUND(fact.score, 1) AS "indexTotal", + ROUND(fact.score*fact.WEIGHT, 1) AS "indexTotal", fact.index_code AS "indexCode" FROM fact_index_community_score fact @@ -41,12 +41,12 @@ AND fact.month_id = #{monthId} - SELECT fact.month_id AS "monthId", - ROUND(fact.score, 1) AS "indexTotal", - ROUND(self.self_score, 1) AS "agencyScore", - ROUND(self.sub_score, 1) AS "subAgencyScore", + ROUND(fact.score*fact.WEIGHT, 1) AS "indexTotal", + ROUND(self.self_score*self.SELF_WEIGHT, 1) AS "agencyScore", + ROUND(self.sub_score*self.SUB_WEIGHT, 1) AS "subAgencyScore", fact.index_code AS "indexCode" FROM fact_index_community_score fact diff --git a/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexGridScoreDao.xml b/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexGridScoreDao.xml index 65e511d43e..33c401d10b 100644 --- a/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexGridScoreDao.xml +++ b/epmet-module/data-report/data-report-server/src/main/resources/mapper/fact/FactIndexGridScoreDao.xml @@ -3,10 +3,10 @@ - SELECT fact.month_id AS "monthId", - ROUND(fact.score, 1) AS "indexTotal", + ROUND(fact.score*fact.WEIGHT, 1) AS "indexTotal", fact.index_code AS "indexCode" FROM fact_index_grid_score fact @@ -42,12 +42,12 @@ AND fact.month_id = #{monthId} - SELECT fact.month_id AS "monthId", - ROUND(fact.score, 1) AS "indexTotal", - ROUND(self.self_score, 1) AS "agencyScore", - ROUND(self.sub_score, 1) AS "subAgencyScore", + ROUND(fact.score*fact.WEIGHT, 1) AS "indexTotal", + ROUND(self.self_score*self.SELF_WEIGHT, 1) AS "agencyScore", + ROUND(self.sub_score*self.SUB_WEIGHT, 1) AS "subAgencyScore", fact.index_code AS "indexCode" FROM fact_index_grid_score fact