diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactAgencyGovernDailyServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactAgencyGovernDailyServiceImpl.java index 5603dfde68..ba1ee9853d 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactAgencyGovernDailyServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactAgencyGovernDailyServiceImpl.java @@ -18,11 +18,25 @@ package com.epmet.service.evaluationindex.extract.todata.impl; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.commons.tools.constant.NumConstant; import com.epmet.dao.evaluationindex.extract.FactAgencyGovernDailyDao; +import com.epmet.dto.extract.result.OrgStatisticsResultDTO; +import com.epmet.dto.stats.DimAgencyDTO; import com.epmet.entity.evaluationindex.extract.FactAgencyGovernDailyEntity; import com.epmet.service.evaluationindex.extract.todata.FactAgencyGovernDailyService; +import com.epmet.service.evaluationindex.extract.todata.FactOriginIssueMainDailyService; +import com.epmet.service.evaluationindex.extract.todata.FactOriginProjectMainDailyService; +import com.epmet.service.evaluationindex.extract.todata.FactOriginTopicMainDailyService; +import com.epmet.service.stats.DimAgencyService; +import com.epmet.util.DimIdGenerator; import org.springframework.stereotype.Service; +import javax.annotation.Resource; +import java.math.BigDecimal; +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + /** * 组织的治理指数,按天统计 * @@ -32,6 +46,14 @@ import org.springframework.stereotype.Service; @Service public class FactAgencyGovernDailyServiceImpl extends BaseServiceImpl implements FactAgencyGovernDailyService { + @Resource + private DimAgencyService dimAgencyService; + @Resource + private FactOriginTopicMainDailyService factOriginTopicMainDailyService; + @Resource + private FactOriginIssueMainDailyService factOriginIssueMainDailyService; + @Resource + private FactOriginProjectMainDailyService factOriginProjectMainDailyService; /** * 治理指数-组织相关 @@ -44,8 +66,14 @@ public class FactAgencyGovernDailyServiceImpl extends BaseServiceImpl agencyList = dimAgencyService.getAgencyInfoByCustomerId(customerId); + List agencyGovernDailyList = agencyList.stream().map(agency -> { + FactAgencyGovernDailyEntity entity = initEntity(agency, dateId); + return entity; + }).collect(Collectors.toList()); // 问题解决总数:当前组织下,话题关闭(已解决+无需解决)总数、议题关闭(已解决+无需解决)总数和项目结案(议题转为项目的结案数+项目立项结案数)总数之和 - + Map topicTotal = factOriginTopicMainDailyService.getAgencyClosedTopicCount(customerId, dateId, null, + null); // 党群自治占比:当前组织下,所有小组内关闭(已解决+无需解决)的话题数与问题解决总数之比(未出小组:未转议题的) // 网格自治占比:当前组织下,所有网格内结案项目数与问题解决总数之比(未出网格) // 参考:fact_index_govrn_ablity_grid_monthly的SELF_SOLVE_PROJECT_COUNT计算 @@ -61,4 +89,35 @@ public class FactAgencyGovernDailyServiceImpl extends BaseServiceImpl