|
|
@ -5,6 +5,7 @@ import com.epmet.commons.tools.utils.DateUtils; |
|
|
|
import com.epmet.constant.OrgTypeConstant; |
|
|
|
import com.epmet.constant.ProjectConstant; |
|
|
|
import com.epmet.dto.basereport.form.EventInfoFormDTO; |
|
|
|
import com.epmet.dto.basereport.result.EventInfoResultDTO; |
|
|
|
import com.epmet.dto.org.result.CustomerAgencyDTO; |
|
|
|
import com.epmet.dto.org.result.CustomerGridDTO; |
|
|
|
import com.epmet.dto.screen.ScreenCustomerGridDTO; |
|
|
@ -16,7 +17,6 @@ import com.epmet.dto.user.result.MidPatrolDetailResult; |
|
|
|
import com.epmet.dto.user.result.MidPatrolRecordResult; |
|
|
|
import com.epmet.entity.evaluationindex.screen.ScreenCustomerAgencyEntity; |
|
|
|
import com.epmet.entity.stats.CustomerProjectCategoryDictEntity; |
|
|
|
import com.epmet.opendata.dto.BaseDisputeProcessDTO; |
|
|
|
import com.epmet.opendata.dto.form.GridBaseInfoFormDTO; |
|
|
|
import com.epmet.opendata.dto.form.StaffBaseInfoFormDTO; |
|
|
|
import com.epmet.service.DataReportingService; |
|
|
@ -140,13 +140,13 @@ public class DataReportingServiceImpl implements DataReportingService { |
|
|
|
* |
|
|
|
* @param formDTO |
|
|
|
* @Param formDTO |
|
|
|
* @Return {@link List<BaseDisputeProcessDTO>} |
|
|
|
* @Return {@link List<EventInfoResultDTO>} |
|
|
|
* @Author zhaoqifeng |
|
|
|
* @Date 2021/10/15 14:10 |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
public List<BaseDisputeProcessDTO> getEventInfo(EventInfoFormDTO formDTO) { |
|
|
|
List<BaseDisputeProcessDTO> list; |
|
|
|
public List<EventInfoResultDTO> getEventInfo(EventInfoFormDTO formDTO) { |
|
|
|
List<EventInfoResultDTO> list; |
|
|
|
//根据入参,获取项目
|
|
|
|
List<ScreenProjectDataDTO> projectList = screenProjectDataService.getProjectList(formDTO.getCustomerId(), formDTO.getProjectId(), formDTO.getPageNo(), formDTO.getPageSize()); |
|
|
|
//项目列表为空,返回空数组
|
|
|
@ -156,7 +156,7 @@ public class DataReportingServiceImpl implements DataReportingService { |
|
|
|
//项目ID不为空时,因为只有一条,可以直接处理
|
|
|
|
if (StringUtils.isNotEmpty(formDTO.getProjectId())) { |
|
|
|
list = projectList.stream().map(project -> { |
|
|
|
BaseDisputeProcessDTO dto = getBaseDisputeProcessDTO(project); |
|
|
|
EventInfoResultDTO dto = getEventInfoResultDTO(project); |
|
|
|
if (OrgTypeConstant.AGENCY.equals(project.getOrgType())) { |
|
|
|
ScreenCustomerAgencyEntity agency = screenCustomerAgencyService.getAgencyById(project.getOrgId()); |
|
|
|
dto.setOrgCode(agency.getCode()); |
|
|
@ -173,7 +173,7 @@ public class DataReportingServiceImpl implements DataReportingService { |
|
|
|
Map<String, ScreenCustomerAgencyEntity> agencyMap = screenCustomerAgencyService.getAgencyList(formDTO.getCustomerId()); |
|
|
|
Map<String, ScreenCustomerGridDTO> gridMap = screenCustomerGridService.getGridList(formDTO.getCustomerId()); |
|
|
|
list = projectList.stream().map(project -> { |
|
|
|
BaseDisputeProcessDTO dto = getBaseDisputeProcessDTO(project); |
|
|
|
EventInfoResultDTO dto = getEventInfoResultDTO(project); |
|
|
|
if (OrgTypeConstant.AGENCY.equals(project.getOrgType())) { |
|
|
|
ScreenCustomerAgencyEntity agency = agencyMap.get(project.getOrgId()); |
|
|
|
dto.setOrgCode(agency.getCode()); |
|
|
@ -189,8 +189,8 @@ public class DataReportingServiceImpl implements DataReportingService { |
|
|
|
return list.stream().filter(item -> StringUtils.isNotBlank(item.getEventCategory())).collect(Collectors.toList()); |
|
|
|
} |
|
|
|
|
|
|
|
private BaseDisputeProcessDTO getBaseDisputeProcessDTO(ScreenProjectDataDTO project) { |
|
|
|
BaseDisputeProcessDTO dto = new BaseDisputeProcessDTO(); |
|
|
|
private EventInfoResultDTO getEventInfoResultDTO(ScreenProjectDataDTO project) { |
|
|
|
EventInfoResultDTO dto = new EventInfoResultDTO(); |
|
|
|
dto.setId(project.getProjectId()); |
|
|
|
dto.setCustomerId(project.getCustomerId()); |
|
|
|
dto.setEventName(project.getProjectTitle()); |
|
|
|