Browse Source

网格 治理能力 相关

master
zxc 5 years ago
parent
commit
41cd752143
  1. 1
      epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java
  2. 12
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/constant/ExtractConstant.java
  3. 19
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/constant/ProjectEvaluateConstant.java
  4. 16
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/result/CalSatisfactionResultDTO.java
  5. 25
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/result/GridProjectClosedTotalResultDTO.java
  6. 32
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/result/NotReturnProjectResultDTO.java
  7. 37
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/result/ProjectEvaluateResultDTO.java
  8. 24
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginProjectLogDailyDao.java
  9. 11
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginProjectMainDailyDao.java
  10. 20
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/FactOriginProjectLogDailyService.java
  11. 11
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/FactOriginProjectMainDailyService.java
  12. 120
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/impl/CalGridIndexServiceImpl.java
  13. 26
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/impl/FactOriginProjectLogDailyServiceImpl.java
  14. 14
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/impl/FactOriginProjectMainDailyServiceImpl.java
  15. 50
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectLogDailyDao.xml
  16. 15
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectMainDailyDao.xml

1
epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java

@ -38,6 +38,7 @@ public interface NumConstant {
int ONE_THOUSAND = 1000;
int MAX = 99999999;
int EIGHTY_EIGHT = 88;
int EIGHTY = 80;
double ZERO_DOT_ZERO = 0.0;

12
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/constant/ExtractConstant.java

@ -20,4 +20,16 @@ public interface ExtractConstant {
String SHIFT_PROJECT = "shift_project";
String CLOSED = "closed";
String GRID_ORG_TYPE = "grid";
String RETURN_ACTION_CODE = "return";
String EVALUATE_BAD = "bad";
String EVALUATE_GOOD = "good";
String EVALUATE_PERFECT = "perfect";
}

19
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/constant/ProjectEvaluateConstant.java

@ -0,0 +1,19 @@
package com.epmet.constant;
import com.epmet.commons.tools.constant.NumConstant;
/**
* @Author zxc
* @DateTime 2020/9/18 3:49 下午
*/
public interface ProjectEvaluateConstant {
// BigDecimal BAD = new BigDecimal(NumConstant.SIXTY);
// BigDecimal GOOD = new BigDecimal(NumConstant.EIGHTY);
// BigDecimal PERFECT = new BigDecimal(NumConstant.ONE_HUNDRED);
Integer BAD = NumConstant.SIXTY;
Integer GOOD = NumConstant.EIGHTY;
Integer PERFECT = NumConstant.ONE_HUNDRED;
}

16
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/result/CalSatisfactionResultDTO.java

@ -0,0 +1,16 @@
package com.epmet.dto.extract.result;
import lombok.Data;
import java.io.Serializable;
/**
* @Author zxc
* @DateTime 2020/9/18 4:01 下午
*/
@Data
public class CalSatisfactionResultDTO implements Serializable {
private static final long serialVersionUID = -7514945819312915670L;
}

25
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/result/GridProjectClosedTotalResultDTO.java

@ -0,0 +1,25 @@
package com.epmet.dto.extract.result;
import lombok.Data;
import java.io.Serializable;
/**
* @Author zxc
* @DateTime 2020/9/18 2:02 下午
*/
@Data
public class GridProjectClosedTotalResultDTO implements Serializable {
private static final long serialVersionUID = 5144371528837124674L;
/**
* 网格ID
*/
private String gridId;
/**
* 网格办结项目数
*/
private Integer resolveProjectCount;
}

32
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/result/NotReturnProjectResultDTO.java

@ -0,0 +1,32 @@
package com.epmet.dto.extract.result;
import com.epmet.commons.tools.constant.NumConstant;
import lombok.Data;
import java.io.Serializable;
import java.math.BigDecimal;
/**
* @Author zxc
* @DateTime 2020/9/18 2:46 下午
*/
@Data
public class NotReturnProjectResultDTO implements Serializable {
private static final long serialVersionUID = -2931817313224740122L;
/**
* 网格ID
*/
private String gridId;
/**
* 未被退回的项目
*/
private Integer notReturnProject = NumConstant.ZERO;
/**
* 网格吹哨部门准确率
*/
private BigDecimal transferRightRatio = new BigDecimal(NumConstant.ZERO);
}

37
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/result/ProjectEvaluateResultDTO.java

@ -0,0 +1,37 @@
package com.epmet.dto.extract.result;
import com.epmet.commons.tools.constant.NumConstant;
import lombok.Data;
import java.io.Serializable;
import java.math.BigDecimal;
/**
* @Author zxc
* @DateTime 2020/9/18 3:23 下午
*/
@Data
public class ProjectEvaluateResultDTO implements Serializable {
private static final long serialVersionUID = 6042094904405338630L;
/**
* 动作code
*/
private String actionCode;
/**
* 网格ID
*/
private String gridId;
/**
* 满意度评价对应的分数
*/
private Integer score = NumConstant.ZERO;
/**
* 项目ID
*/
private String projectId;
}

24
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginProjectLogDailyDao.java

@ -18,8 +18,13 @@
package com.epmet.dao.evaluationindex.extract;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.dto.extract.result.NotReturnProjectResultDTO;
import com.epmet.dto.extract.result.ProjectEvaluateResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginProjectLogDailyEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;
/**
* 项目明细_日统计
@ -29,5 +34,22 @@ import org.apache.ibatis.annotations.Mapper;
*/
@Mapper
public interface FactOriginProjectLogDailyDao extends BaseDao<FactOriginProjectLogDailyEntity> {
/**
* @Description 查询未被退回的项目数
* @param customerId
* @param monthId
* @author zxc
* @date 2020/9/18 2:50 下午
*/
List<NotReturnProjectResultDTO> selectNotReturnProject(@Param("customerId") String customerId,@Param("monthId") String monthId,@Param("actionCode") String actionCode,@Param("orgType") String orgType);
/**
* @Description 查询项目评价信息
* @param customerId
* @param monthId
* @author zxc
* @date 2020/9/18 3:28 下午
*/
List<ProjectEvaluateResultDTO> selectProjectEvaluate(@Param("customerId") String customerId,@Param("monthId") String monthId);
}

11
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginProjectMainDailyDao.java

@ -19,6 +19,7 @@ package com.epmet.dao.evaluationindex.extract;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.dto.extract.FactOriginProjectMainDailyDTO;
import com.epmet.dto.extract.result.GridProjectClosedTotalResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginProjectMainDailyEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
@ -51,4 +52,14 @@ public interface FactOriginProjectMainDailyDao extends BaseDao<FactOriginProject
* @return java.util.List<com.epmet.dto.extract.FactOriginProjectMainDailyDTO>
*/
List<FactOriginProjectMainDailyDTO> getPendingList(@Param("customerId") String customerId);
/**
* @Description 网格办结项目数
* @param customerId
* @param monthId
* @param status
* @author zxc
* @date 2020/9/18 2:06 下午
*/
List<GridProjectClosedTotalResultDTO> selectGridClosedProject(@Param("customerId") String customerId,@Param("monthId") String monthId,@Param("status") String status);
}

20
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/FactOriginProjectLogDailyService.java

@ -20,6 +20,8 @@ package com.epmet.service.evaluationindex.extract;
import com.epmet.commons.mybatis.service.BaseService;
import com.epmet.commons.tools.page.PageData;
import com.epmet.dto.extract.FactOriginProjectLogDailyDTO;
import com.epmet.dto.extract.result.NotReturnProjectResultDTO;
import com.epmet.dto.extract.result.ProjectEvaluateResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginProjectLogDailyEntity;
import java.util.List;
@ -92,4 +94,22 @@ public interface FactOriginProjectLogDailyService extends BaseService<FactOrigin
* @date 2020-09-16
*/
void delete(String[] ids);
/**
* @Description 查询未被退回的项目数
* @param customerId
* @param monthId
* @author zxc
* @date 2020/9/18 2:50 下午
*/
List<NotReturnProjectResultDTO> selectNotReturnProject(String customerId,String monthId,String actionCode,String orgType);
/**
* @Description 查询项目评价信息
* @param customerId
* @param monthId
* @author zxc
* @date 2020/9/18 3:28 下午
*/
List<ProjectEvaluateResultDTO> selectProjectEvaluate(String customerId,String monthId);
}

11
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/FactOriginProjectMainDailyService.java

@ -20,6 +20,7 @@ package com.epmet.service.evaluationindex.extract;
import com.epmet.commons.mybatis.service.BaseService;
import com.epmet.commons.tools.page.PageData;
import com.epmet.dto.extract.FactOriginProjectMainDailyDTO;
import com.epmet.dto.extract.result.GridProjectClosedTotalResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginProjectMainDailyEntity;
import java.util.List;
@ -110,4 +111,14 @@ public interface FactOriginProjectMainDailyService extends BaseService<FactOrigi
* @return java.util.List<com.epmet.dto.extract.FactOriginProjectMainDailyDTO>
*/
List<FactOriginProjectMainDailyDTO> getPendingList(String customerId);
/**
* @Description 网格办结项目数
* @param customerId
* @param monthId
* @param status
* @author zxc
* @date 2020/9/18 2:06 下午
*/
List<GridProjectClosedTotalResultDTO> selectGridClosedProject(String customerId,String monthId,String status);
}

120
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/impl/CalGridIndexServiceImpl.java

@ -5,11 +5,17 @@ import com.epmet.commons.tools.constant.NumConstant;
import com.epmet.commons.tools.exception.RenException;
import com.epmet.constant.DataSourceConstant;
import com.epmet.constant.ExtractConstant;
import com.epmet.constant.ProjectEvaluateConstant;
import com.epmet.dao.evaluationindex.indexcoll.FactIndexGovrnAblityGridMonthlyDao;
import com.epmet.dto.extract.form.GovernAbilityGridMonthlyFormDTO;
import com.epmet.dto.extract.form.GridIssueCountResultDTO;
import com.epmet.dto.extract.result.GridProjectClosedTotalResultDTO;
import com.epmet.dto.extract.result.GridProjectCountResultDTO;
import com.epmet.dto.extract.result.NotReturnProjectResultDTO;
import com.epmet.dto.extract.result.ProjectEvaluateResultDTO;
import com.epmet.service.evaluationindex.extract.CalGridIndexService;
import com.epmet.service.evaluationindex.extract.FactOriginProjectLogDailyService;
import com.epmet.service.evaluationindex.extract.FactOriginProjectMainDailyService;
import com.epmet.service.evaluationindex.extract.IssueExtractService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.BeanUtils;
@ -18,7 +24,11 @@ import org.springframework.stereotype.Service;
import org.springframework.util.CollectionUtils;
import java.math.BigDecimal;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.concurrent.atomic.AtomicReference;
import java.util.stream.Collectors;
/**
* @Author zxc
@ -33,6 +43,10 @@ public class CalGridIndexServiceImpl implements CalGridIndexService {
private IssueExtractService issueExtractService;
@Autowired
private FactIndexGovrnAblityGridMonthlyDao governAbilityDao;
@Autowired
private FactOriginProjectMainDailyService projectMainService;
@Autowired
private FactOriginProjectLogDailyService projectLogService;
/**
* @Description 计算网格指标党建能力
@ -65,22 +79,63 @@ public class CalGridIndexServiceImpl implements CalGridIndexService {
//网格总项目数
List<GridProjectCountResultDTO> gridProjectTotalList = issueExtractService.selectGridProjectCount(customerId, monthId, ExtractConstant.SHIFT_PROJECT);
//网格议题转项目率
gridProjectTotalList.forEach(project -> {
gridIssueTotalList.forEach(issue ->{
if (project.getGridId().equals(issue.getGridId())){
project.setIssueToProjectRatio(getRound(new BigDecimal(project.getProjectTotal()/issue.getIssueTotal())));
}
if (!CollectionUtils.isEmpty(gridIssueTotalList) && !CollectionUtils.isEmpty(gridProjectTotalList)) {
gridProjectTotalList.forEach(project -> {
gridIssueTotalList.forEach(issue -> {
if (project.getGridId().equals(issue.getGridId())) {
project.setIssueToProjectRatio(getRound(new BigDecimal(project.getProjectTotal() / issue.getIssueTotal())));
}
});
});
});
//网格自治项目数
}
//网格自治项目数 从议题创建到项目关闭,包括处理人,自始至终没有出过议题所属网格
//网格办结项目数
//网格吹哨部门准确率
List<GridProjectClosedTotalResultDTO> gridProjectClosedTotalList = projectMainService.selectGridClosedProject(customerId, monthId, ExtractConstant.CLOSED);
//网格吹哨部门准确率 【没被退回的项目数/项目总数 】
List<NotReturnProjectResultDTO> notReturnProjectList = projectLogService.selectNotReturnProject(customerId, monthId, ExtractConstant.RETURN_ACTION_CODE, ExtractConstant.GRID_ORG_TYPE);
if (!CollectionUtils.isEmpty(gridProjectTotalList) && !CollectionUtils.isEmpty(notReturnProjectList)){
notReturnProjectList.forEach(not -> {
gridProjectTotalList.forEach(total -> {
if (not.getGridId().equals(total.getGridId())){
not.setTransferRightRatio(getRound(new BigDecimal(not.getNotReturnProject()/total.getProjectTotal())));
}
});
});
}
//网格内解决的项目的满意度
//组织内党员的参与议事能力考评分(平均值)
//项目评价(分值定义下非常满意100,满意80,不满意(一般)60)的人数的平均分(每个项目的参加人数的分数和/评论人数=一个项目的平均分)+其他项目得分/已关闭项目总数
List<ProjectEvaluateResultDTO> projectEvaluateList = projectLogService.selectProjectEvaluate(customerId, monthId);
Map<String,BigDecimal> resultSatisfactionScore = new HashMap<>(16);
if (!CollectionUtils.isEmpty(projectEvaluateList)){
Map<String, List<ProjectEvaluateResultDTO>> groupByGrid = projectEvaluateList.stream().collect(Collectors.groupingBy(ProjectEvaluateResultDTO::getGridId));
groupByGrid.forEach((gridId,projectEvaluateInfoList) -> {
Map<String,Integer> scoreMap = new HashMap<>(16);
Map<String, List<ProjectEvaluateResultDTO>> groupByProject = projectEvaluateInfoList.stream().collect(Collectors.groupingBy(ProjectEvaluateResultDTO::getProjectId));
groupByProject.forEach((projectId,projectList) -> {
projectList.forEach(project -> {
switch (project.getActionCode()){
case ExtractConstant.EVALUATE_BAD:
project.setScore(ProjectEvaluateConstant.BAD);
break;
case ExtractConstant.EVALUATE_GOOD:
project.setScore(ProjectEvaluateConstant.GOOD);
break;
case ExtractConstant.EVALUATE_PERFECT:
project.setScore(ProjectEvaluateConstant.PERFECT);
break;
}
});
Integer projectAllScore = projectList.stream().collect(Collectors.summingInt(ProjectEvaluateResultDTO::getScore));
scoreMap.put(projectId,projectAllScore/projectList.size());
});
AtomicReference<Integer> allScore = new AtomicReference<>(0);
scoreMap.forEach((k,v) -> {
allScore.set(++v);
});
resultSatisfactionScore.put(gridId,getRound(new BigDecimal(allScore.get()/scoreMap.size())));
});
}
result.forEach(r -> {
// 1. 网格总议题数目,网格人均议题数目
@ -100,23 +155,32 @@ public class CalGridIndexServiceImpl implements CalGridIndexService {
}
});
}
// 3. 网格办结项目数
if (!CollectionUtils.isEmpty(gridProjectClosedTotalList)){
gridProjectClosedTotalList.forEach(closed -> {
if (r.getGridId().equals(closed.getGridId())){
r.setResolveProjectCount(closed.getResolveProjectCount());
}
});
}
// 4. 网格吹哨部门准确率
if (!CollectionUtils.isEmpty(notReturnProjectList)){
notReturnProjectList.forEach(not -> {
if (r.getGridId().equals(not.getGridId())){
r.setTransferRightRatio(not.getTransferRightRatio());
}
});
}
// 5. 网格内解决的项目的满意度
if (null != resultSatisfactionScore){
resultSatisfactionScore.forEach((k,v) -> {
if (r.getGridId().equals(k)){
r.setSatisfactionRatio(v);
}
});
}
// 6. 网格自治项目数
});
//
return true;
}

26
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/impl/FactOriginProjectLogDailyServiceImpl.java

@ -25,6 +25,8 @@ import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.dao.evaluationindex.extract.FactOriginProjectLogDailyDao;
import com.epmet.dto.extract.FactOriginProjectLogDailyDTO;
import com.epmet.dto.extract.result.NotReturnProjectResultDTO;
import com.epmet.dto.extract.result.ProjectEvaluateResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginProjectLogDailyEntity;
import com.epmet.service.evaluationindex.extract.FactOriginProjectLogDailyService;
import org.apache.commons.lang3.StringUtils;
@ -97,4 +99,28 @@ public class FactOriginProjectLogDailyServiceImpl extends BaseServiceImpl<FactOr
baseDao.deleteBatchIds(Arrays.asList(ids));
}
/**
* @Description 查询未被退回的项目数
* @param customerId
* @param monthId
* @author zxc
* @date 2020/9/18 2:50 下午
*/
@Override
public List<NotReturnProjectResultDTO> selectNotReturnProject(String customerId, String monthId, String actionCode, String orgType) {
return baseDao.selectNotReturnProject(customerId, monthId, actionCode, orgType);
}
/**
* @Description 查询项目评价信息
* @param customerId
* @param monthId
* @author zxc
* @date 2020/9/18 3:28 下午
*/
@Override
public List<ProjectEvaluateResultDTO> selectProjectEvaluate(String customerId, String monthId) {
return baseDao.selectProjectEvaluate(customerId, monthId);
}
}

14
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/impl/FactOriginProjectMainDailyServiceImpl.java

@ -25,6 +25,7 @@ import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.dao.evaluationindex.extract.FactOriginProjectMainDailyDao;
import com.epmet.dto.extract.FactOriginProjectMainDailyDTO;
import com.epmet.dto.extract.result.GridProjectClosedTotalResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginProjectMainDailyEntity;
import com.epmet.service.evaluationindex.extract.FactOriginProjectMainDailyService;
import org.apache.commons.lang3.StringUtils;
@ -106,4 +107,17 @@ public class FactOriginProjectMainDailyServiceImpl extends BaseServiceImpl<FactO
return baseDao.getPendingList(customerId);
}
/**
* @Description 网格办结项目数
* @param customerId
* @param monthId
* @param status
* @author zxc
* @date 2020/9/18 2:06 下午
*/
@Override
public List<GridProjectClosedTotalResultDTO> selectGridClosedProject(String customerId, String monthId, String status) {
return baseDao.selectGridClosedProject(customerId, monthId);
}
}

50
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectLogDailyDao.xml

@ -3,26 +3,36 @@
<mapper namespace="com.epmet.dao.evaluationindex.extract.FactOriginProjectLogDailyDao">
<resultMap type="com.epmet.entity.evaluationindex.extract.FactOriginProjectLogDailyEntity" id="factOriginProjectLogDailyMap">
<result property="id" column="ID"/>
<result property="customerId" column="CUSTOMER_ID"/>
<result property="gridId" column="GRID_ID"/>
<result property="agencyId" column="AGENCY_ID"/>
<result property="dateId" column="DATE_ID"/>
<result property="monthId" column="MONTH_ID"/>
<result property="quarterId" column="QUARTER_ID"/>
<result property="yearId" column="YEAR_ID"/>
<result property="issueId" column="ISSUE_ID"/>
<result property="operationUserId" column="OPERATION_USER_ID"/>
<result property="actionCode" column="ACTION_CODE"/>
<result property="isParty" column="IS_PARTY"/>
<result property="delFlag" column="DEL_FLAG"/>
<result property="revision" column="REVISION"/>
<result property="createdBy" column="CREATED_BY"/>
<result property="createdTime" column="CREATED_TIME"/>
<result property="updatedBy" column="UPDATED_BY"/>
<result property="updatedTime" column="UPDATED_TIME"/>
</resultMap>
<!-- 查询未被退回的项目数 -->
<select id="selectNotReturnProject" resultType="com.epmet.dto.extract.result.NotReturnProjectResultDTO">
SELECT
COUNT( ID ) AS notReturnProject,
ORG_ID AS gridId
FROM
fact_origin_project_log_daily
WHERE
DEL_FLAG = 0
AND org_type = #{orgType}
AND CUSTOMER_ID = #{customerId}
AND MONTH_ID = #{monthId}
AND ACTION_CODE != #{actionCode}
GROUP BY ORG_ID
</select>
<!-- 查询项目评价信息 -->
<select id="selectProjectEvaluate" resultType="com.epmet.dto.extract.result.ProjectEvaluateResultDTO">
SELECT
ACTION_CODE,
ORG_ID AS gridId,
PROJECT_ID
FROM
fact_origin_project_log_daily
WHERE
DEL_FLAG = 0
AND org_type = 'grid'
AND CUSTOMER_ID = #{customerId}
AND MONTH_ID = #{monthId}
AND (ACTION_CODE = 'bad' OR ACTION_CODE = 'good' OR ACTION_CODE = 'perfect')
</select>
</mapper>

15
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectMainDailyDao.xml

@ -45,5 +45,20 @@
AND PROJECT_STATUS = 'pending'
</select>
<!-- 网格办结项目数 -->
<select id="selectGridClosedProject" resultType="com.epmet.dto.extract.result.GridProjectClosedTotalResultDTO">
SELECT
COUNT(ID) AS resolveProjectCount,
GRID_ID
FROM
fact_origin_project_main_daily
WHERE
DEL_FLAG = 0
AND PROJECT_STATUS = #{status}
AND CUSTOMER_ID = #{customerId}
AND MONTH_ID = #{monthId}
GROUP BY GRID_ID
</select>
</mapper>
Loading…
Cancel
Save