|
|
@ -36,6 +36,7 @@ import com.epmet.constant.SmsTemplateConstant; |
|
|
|
import com.epmet.constant.UserMessageConstant; |
|
|
|
import com.epmet.dao.ProjectDao; |
|
|
|
import com.epmet.dao.ProjectOrgRelationDao; |
|
|
|
import com.epmet.dao.ProjectSatisfactionStatisticsDao; |
|
|
|
import com.epmet.dto.*; |
|
|
|
import com.epmet.dto.form.*; |
|
|
|
import com.epmet.dto.result.*; |
|
|
@ -132,6 +133,8 @@ public class ProjectServiceImpl extends BaseServiceImpl<ProjectDao, ProjectEntit |
|
|
|
private ProjectTraceService projectTraceService; |
|
|
|
@Autowired |
|
|
|
private ResiGroupOpenFeignClient resiGroupOpenFeignClient; |
|
|
|
@Autowired |
|
|
|
private ProjectSatisfactionStatisticsDao statisticsDao; |
|
|
|
|
|
|
|
|
|
|
|
private final static String ONE_DAY = "<1"; |
|
|
@ -712,6 +715,24 @@ public class ProjectServiceImpl extends BaseServiceImpl<ProjectDao, ProjectEntit |
|
|
|
if (!msgResult) { |
|
|
|
log.error("项目实时统计消息发送失败"); |
|
|
|
} |
|
|
|
|
|
|
|
// 项目评价初始化信息插入
|
|
|
|
// 应评价数 = 话题创建者 + 议题发起者 + 议题表决人 【去重】
|
|
|
|
// 议题发起者 和 议题表决人 和 话题创建者 查询
|
|
|
|
Result<List<String>> canEvaluateProjectCount = govIssueOpenFeignClient.canEvaluateProjectCount(projectEntity.getOriginId()); |
|
|
|
if (!canEvaluateProjectCount.success()){ |
|
|
|
throw new RenException("【查询项目应评价人数失败】,【"+canEvaluateProjectCount.getMsg()+"】"); |
|
|
|
} |
|
|
|
List<String> userIds = canEvaluateProjectCount.getData(); |
|
|
|
ProjectSatisfactionStatisticsEntity entity1 = new ProjectSatisfactionStatisticsEntity(); |
|
|
|
entity1.setShouldEvaluateCount(userIds.size()); |
|
|
|
entity1.setCustomerId(projectEntity.getCustomerId()); |
|
|
|
entity1.setProjectId(fromDTO.getProjectId()); |
|
|
|
entity1.setBadCount(NumConstant.ZERO); |
|
|
|
entity1.setGoodCount(NumConstant.ZERO); |
|
|
|
entity1.setPerfectCount(NumConstant.ZERO); |
|
|
|
// 新添一条记录
|
|
|
|
statisticsDao.insert(entity1); |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|