Browse Source

小数修改

dev_shibei_match
zxc 5 years ago
parent
commit
c42e3b2377
  1. 8
      epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/service/evaluationindex/screen/impl/IndexServiceImpl.java
  2. 7
      epmet-module/data-report/data-report-server/src/main/resources/mapper/screen/ScreenIndexDataMonthlyDao.xml
  3. 8
      epmet-module/data-report/data-report-server/src/main/resources/mapper/screen/ScreenIndexDataYearlyDao.xml

8
epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/service/evaluationindex/screen/impl/IndexServiceImpl.java

@ -57,7 +57,7 @@ public class IndexServiceImpl implements IndexService {
yearAverageIndexResultDTO.setPartyDevAbility(getRound(yearAverageIndexResultDTO.getPartyDevAbility()));
yearAverageIndexResultDTO.setGovernAbility(getRound(yearAverageIndexResultDTO.getGovernAbility()));
yearAverageIndexResultDTO.setServiceAbility(getRound(yearAverageIndexResultDTO.getServiceAbility()));
yearAverageIndexResultDTO.setYearAverageIndex(getRound(yearAverageIndexResultDTO.getYearAverageIndex()));
yearAverageIndexResultDTO.setYearAverageIndex(yearAverageIndexResultDTO.getPartyDevAbility() + yearAverageIndexResultDTO.getGovernAbility() + yearAverageIndexResultDTO.getServiceAbility());
return yearAverageIndexResultDTO;
}
@ -126,7 +126,7 @@ public class IndexServiceImpl implements IndexService {
barchart.setPartyDevAbility(getRound(barchart.getPartyDevAbility()));
barchart.setGovernAbility(getRound(barchart.getGovernAbility()));
barchart.setServiceAbility(getRound(barchart.getServiceAbility()));
barchart.setIndexTotal(getRound(barchart.getIndexTotal()));
barchart.setIndexTotal(barchart.getPartyDevAbility() + barchart.getGovernAbility() + barchart.getServiceAbility());
});
List<MonthBarchartResult> collect = monthBarchartResults.stream().sorted(Comparator.comparing(MonthBarchartResult::getMonthId)).collect(Collectors.toList());
//升序 当前月份在队尾
@ -199,7 +199,7 @@ public class IndexServiceImpl implements IndexService {
indexRank.setPartyDevAbility(getRound(indexRank.getPartyDevAbility()));
indexRank.setGovernAbility(getRound(indexRank.getGovernAbility()));
indexRank.setServiceAbility(getRound(indexRank.getServiceAbility()));
indexRank.setTotalIndex(getRound(indexRank.getTotalIndex()));
indexRank.setTotalIndex(indexRank.getPartyDevAbility() + indexRank.getGovernAbility() + indexRank.getServiceAbility());
});
return subAgencyIndexRankResultDTOS;
}
@ -218,7 +218,7 @@ public class IndexServiceImpl implements IndexService {
rank.setPartyDevAbility(getRound(rank.getPartyDevAbility()));
rank.setGovernAbility(getRound(rank.getGovernAbility()));
rank.setServiceAbility(getRound(rank.getServiceAbility()));
rank.setTotalIndex(getRound(rank.getTotalIndex()));
rank.setTotalIndex(rank.getPartyDevAbility() + rank.getGovernAbility() + rank.getServiceAbility());
});
}
return subAgencyIndexRankResultDTOS;

7
epmet-module/data-report/data-report-server/src/main/resources/mapper/screen/ScreenIndexDataMonthlyDao.xml

@ -32,8 +32,7 @@
month_id AS monthId,
service_ablity * SERVICE_ABLITY_WEIGHT AS serviceAbility,
party_dev_ablity * PARTY_DEV_WEIGHT AS partyDevAbility,
govern_ablity * GOVERN_ABLITY_WEIGHT AS governAbility,
(service_ablity * SERVICE_ABLITY_WEIGHT + party_dev_ablity * PARTY_DEV_WEIGHT + govern_ablity * GOVERN_ABLITY_WEIGHT) AS indexTotal
govern_ablity * GOVERN_ABLITY_WEIGHT AS governAbility
FROM
screen_index_data_monthly
WHERE
@ -47,7 +46,6 @@
<select id="selectSubAgencyIndexRank" parameterType="com.epmet.evaluationindex.screen.dto.form.SubAgencyIndexRankFormDTO" resultType="com.epmet.evaluationindex.screen.dto.result.SubAgencyIndexRankResultDTO">
SELECT
org_name AS NAME,
index_total AS totalIndex,
govern_ablity AS governAbility,
party_dev_ablity AS partyDevAbility,
service_ablity AS serviceAbility
@ -69,8 +67,7 @@
org_name AS `NAME`,
service_ablity * SERVICE_ABLITY_WEIGHT AS serviceAbility,
party_dev_ablity * PARTY_DEV_WEIGHT AS partyDevAbility,
govern_ablity * GOVERN_ABLITY_WEIGHT AS governAbility,
(service_ablity * SERVICE_ABLITY_WEIGHT + party_dev_ablity * PARTY_DEV_WEIGHT + govern_ablity * GOVERN_ABLITY_WEIGHT) AS totalIndex,
govern_ablity * GOVERN_ABLITY_WEIGHT AS governAbility
ORG_ID orgId
FROM
screen_index_data_monthly

8
epmet-module/data-report/data-report-server/src/main/resources/mapper/screen/ScreenIndexDataYearlyDao.xml

@ -6,7 +6,6 @@
<!-- 1、年度平均指数 -->
<select id="selectYearAverageIndex" resultType="com.epmet.evaluationindex.screen.dto.result.YearAverageIndexResultDTO">
SELECT
index_total AS yearAverageIndex,
service_ablity AS serviceAbility,
party_dev_ablity AS partyDevAbility,
govern_ablity AS governAbility
@ -24,10 +23,9 @@
resultType="com.epmet.evaluationindex.screen.dto.result.AnNingSubAgencyIndexRankResultDTO">
SELECT
org_name AS `NAME`,
ROUND(index_total, 1) AS totalIndex,
ROUND(govern_ablity, 1) AS governAbility,
ROUND(party_dev_ablity, 1) AS partyDevAbility,
ROUND(service_ablity, 1) AS serviceAbility,
govern_ablity AS governAbility,
party_dev_ablity AS partyDevAbility,
service_ablity AS serviceAbility,
ORG_ID orgId
FROM
screen_index_data_yearly

Loading…
Cancel
Save