Browse Source

Merge remote-tracking branch 'origin/develop' into develop

dev_shibei_match
wxz 4 years ago
parent
commit
46a6c429eb
  1. 4
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectMainDailyDao.xml
  2. 2
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/project/ProjectDao.xml
  3. 20
      epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/EventTitleOrgResultDTO.java
  4. 14
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java
  5. 9
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffGridDao.java
  6. 9
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java
  7. 12
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java
  8. 21
      epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml
  9. 2
      epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/dao/ProjectDao.java
  10. 3
      epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java
  11. 5
      epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java
  12. 4
      epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectTraceServiceImpl.java
  13. 7
      epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ResiEventServiceImpl.java
  14. 5
      epmet-module/gov-project/gov-project-server/src/main/resources/mapper/ProjectDao.xml

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

@ -1083,7 +1083,7 @@
FROM
fact_origin_project_main_daily
WHERE
ORIGIN = 'agency'
(ORIGIN = 'agency' OR ORIGIN = 'resi_event')
AND CUSTOMER_ID = #{customerId}
<if test='null != dateId and "" != dateId'>
AND DATE_ID = #{dateId}
@ -1101,7 +1101,7 @@
FROM
fact_origin_project_main_daily
WHERE
ORIGIN = 'agency'
(ORIGIN = 'agency' OR ORIGIN = 'resi_event')
AND CUSTOMER_ID = #{customerId}
<if test='null != dateId and "" != dateId'>
AND DATE_ID &lt;= #{dateId}

2
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/project/ProjectDao.xml

@ -227,7 +227,7 @@
rero.ORG_ID,
rero.ORG_PID,
rero.ORG_PIDS,
re.PROJECT_ID.CREATED_BY,
re.CREATED_BY,
re.PROJECT_ID
from resi_event_report_org rero
inner join resi_event re on rero.RESI_EVENT_ID = re.id and re.SHIFT_PROJECT = 1 and re.DEL_FLAG = '0'

20
epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/EventTitleOrgResultDTO.java

@ -0,0 +1,20 @@
package com.epmet.dto.result;
import lombok.Data;
import java.io.Serializable;
/**
* @Author zxc
* @DateTime 2021/8/5 5:23 下午
* @DESC
*/
@Data
public class EventTitleOrgResultDTO implements Serializable {
private static final long serialVersionUID = -517506506008916648L;
private String agencyId;
private String gridId;
private String gridName;
}

14
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java

@ -17,7 +17,9 @@
package com.epmet.controller;
import com.epmet.commons.tools.annotation.LoginUser;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.security.dto.TokenDto;
import com.epmet.commons.tools.utils.ExcelUtils;
import com.epmet.commons.tools.utils.Result;
import com.epmet.commons.tools.validator.AssertUtils;
@ -29,6 +31,7 @@ import com.epmet.dto.CustomerStaffGridDTO;
import com.epmet.dto.form.CommonGridIdFormDTO;
import com.epmet.dto.form.LatestGridFormDTO;
import com.epmet.dto.result.CustomerGridByUserIdResultDTO;
import com.epmet.dto.result.EventTitleOrgResultDTO;
import com.epmet.dto.result.GridStaffResultDTO;
import com.epmet.excel.CustomerStaffGridExcel;
import com.epmet.service.CustomerStaffGridService;
@ -131,4 +134,15 @@ public class CustomerStaffGridController {
public Result<List<GridStaffResultDTO>> selectGridStaffByGridIds(@RequestBody List<String> gridIds){
return new Result<List<GridStaffResultDTO>>().ok(customerStaffGridService.selectGridStaffByGridIds(gridIds));
}
/**
* @Description 查询ORG
* @Param userId
* @author zxc
* @date 2021/8/5 5:36 下午
*/
@PostMapping("eventorg")
public Result<List<EventTitleOrgResultDTO>> eventOrg(@LoginUser TokenDto tokenDto){
return new Result<List<EventTitleOrgResultDTO>>().ok(customerStaffGridService.eventOrg(tokenDto.getUserId()));
}
}

9
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffGridDao.java

@ -22,6 +22,7 @@ import com.epmet.dto.CustomerGridDTO;
import com.epmet.dto.CustomerStaffDepartmentDTO;
import com.epmet.dto.CustomerStaffGridDTO;
import com.epmet.dto.form.LatestGridFormDTO;
import com.epmet.dto.result.EventTitleOrgResultDTO;
import com.epmet.dto.result.GridStaffResultDTO;
import com.epmet.entity.CustomerStaffGridEntity;
import org.apache.ibatis.annotations.Mapper;
@ -106,4 +107,12 @@ public interface CustomerStaffGridDao extends BaseDao<CustomerStaffGridEntity> {
* @date 2021/6/8 3:36 下午
*/
List<GridStaffResultDTO> selectGridStaffByGridIds(@Param("gridIds") List<String> gridIds);
/**
* @Description 查询ORG
* @Param userId
* @author zxc
* @date 2021/8/5 5:36 下午
*/
List<EventTitleOrgResultDTO> eventOrg(@Param("userId") String userId);
}

9
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java

@ -26,6 +26,7 @@ import com.epmet.dto.form.CustomerGridFormDTO;
import com.epmet.dto.form.LatestGridFormDTO;
import com.epmet.dto.result.CommonStaffInfoResultDTO;
import com.epmet.dto.result.CustomerGridByUserIdResultDTO;
import com.epmet.dto.result.EventTitleOrgResultDTO;
import com.epmet.dto.result.GridStaffResultDTO;
import com.epmet.entity.CustomerStaffGridEntity;
@ -126,4 +127,12 @@ public interface CustomerStaffGridService extends BaseService<CustomerStaffGridE
* @date 2021/6/8 3:36 下午
*/
List<GridStaffResultDTO> selectGridStaffByGridIds(List<String> gridIds);
/**
* @Description 查询ORG
* @Param userId
* @author zxc
* @date 2021/8/5 5:36 下午
*/
List<EventTitleOrgResultDTO> eventOrg(String userId);
}

12
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java

@ -31,6 +31,7 @@ import com.epmet.dto.CustomerStaffGridDTO;
import com.epmet.dto.form.CommonGridIdFormDTO;
import com.epmet.dto.form.LatestGridFormDTO;
import com.epmet.dto.result.CustomerGridByUserIdResultDTO;
import com.epmet.dto.result.EventTitleOrgResultDTO;
import com.epmet.dto.result.GridStaffResultDTO;
import com.epmet.entity.CustomerStaffGridEntity;
import com.epmet.feign.EpmetUserOpenFeignClient;
@ -181,4 +182,15 @@ public class CustomerStaffGridServiceImpl extends BaseServiceImpl<CustomerStaffG
}
return data;
}
/**
* @Description 查询ORG
* @Param userId
* @author zxc
* @date 2021/8/5 5:36 下午
*/
@Override
public List<EventTitleOrgResultDTO> eventOrg(String userId) {
return baseDao.eventOrg(userId);
}
}

21
epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml

@ -102,6 +102,27 @@
)
</select>
<!-- 查询ORG -->
<select id="eventOrg" resultType="com.epmet.dto.result.EventTitleOrgResultDTO">
SELECT
sa.AGENCY_ID AS agencyId,
sa.AGENCY_ID AS gridId,
ca.ORGANIZATION_NAME AS gridName
FROM customer_staff_agency sa
LEFT JOIN customer_agency ca ON (ca.ID = sa.AGENCY_ID AND ca.DEL_FLAG = 0)
WHERE sa.DEL_FLAG = 0
AND sa.USER_ID = #{userId}
UNION ALL
SELECT
sg.GRID_ID AS gridId,
cg.PID AS agencyId,
cg.GRID_NAME AS gridName
FROM customer_staff_grid sg
LEFT JOIN customer_grid cg ON (cg.ID = sg.GRID_ID AND cg.DEL_FLAG = 0)
WHERE sg.DEL_FLAG = 0
AND sg.USER_ID = #{userId}
</select>
<!-- 批量插入网格工作人员 -->
<insert id="insertBatch" parameterType="java.util.List">
insert into customer_staff_grid

2
epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/dao/ProjectDao.java

@ -215,4 +215,6 @@ public interface ProjectDao extends BaseDao<ProjectEntity> {
* @date 2021/8/4 2:43 下午
*/
EventProjectInfoDTO selectEventProjectInfo(@Param("projectId")String projectId);
List<ProjectEntity> selectByOriginId(String originId);
}

3
epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java

@ -19,7 +19,6 @@ package com.epmet.service;
import com.epmet.commons.mybatis.service.BaseService;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.security.dto.TokenDto;
import com.epmet.dto.ProjectDTO;
import com.epmet.dto.form.*;
import com.epmet.dto.result.*;
@ -330,4 +329,6 @@ public interface ProjectService extends BaseService<ProjectEntity> {
* @return java.util.List<com.epmet.dto.result.UnResolvedResultDTO>
*/
List<UnResolvedResultDTO> getUnResolvedListByGrid(ShiftProjectListFromDTO fromDTO);
List<ProjectEntity> getByOriginId(String eventId);
}

5
epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java

@ -2753,4 +2753,9 @@ public class ProjectServiceImpl extends BaseServiceImpl<ProjectDao, ProjectEntit
return baseDao.selectUnResolvedListByGrid(fromDTO.getGridId());
}
@Override
public List<ProjectEntity> getByOriginId(String originId) {
return baseDao.selectByOriginId(originId);
}
}

4
epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectTraceServiceImpl.java

@ -631,6 +631,10 @@ public class ProjectTraceServiceImpl<ProjectTagService> implements ProjectTraceS
if(null==resiEventEntity||resiEventEntity.getShiftProject()){
throw new RenException(EpmetErrorCode.RESI_EVENT_SHIFT_PROJECT.getCode(),EpmetErrorCode.RESI_EVENT_SHIFT_PROJECT.getMsg());
}
List<ProjectEntity> projectEntityList = projectService.getByOriginId(formDTO.getEventId());
if (!CollectionUtils.isEmpty(projectEntityList)) {
throw new RenException(EpmetErrorCode.RESI_EVENT_SHIFT_PROJECT.getCode(), EpmetErrorCode.RESI_EVENT_SHIFT_PROJECT.getMsg());
}
List<TickStaffFormDTO> staffList = formDTO.getStaffList();
//1.文字内容安全校验
List<String> list = new ArrayList<>();

7
epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ResiEventServiceImpl.java

@ -478,8 +478,8 @@ public class ResiEventServiceImpl extends BaseServiceImpl<ResiEventDao, ResiEven
formDTO.getPageSize()).doSelectPageInfo(() -> baseDao.queryMyReported(formDTO.getUserId(),
formDTO.getStatusCondition()));
result.getList().forEach(resultDTO->{
if(EventConstant.EVENT_STATUS_CLOSED_CASE.equals(resultDTO.getStatus())){
// 已办结的不显示回复按钮
if(EventConstant.EVENT_STATUS_CLOSED_CASE.equals(resultDTO.getStatus())||resultDTO.getShiftProject()){
// 已办结的、立项的不显示回复按钮
resultDTO.setReplyButtonFlag("false");
}else{
// 处理中的事件
@ -598,6 +598,7 @@ public class ResiEventServiceImpl extends BaseServiceImpl<ResiEventDao, ResiEven
resiEventEntity.setLatestOperatedTime(formDTO.getShiftProjectTime());
resiEventEntity.setShiftProject(true);
resiEventEntity.setRedDot(true);
resiEventEntity.setProjectId(formDTO.getProjectId());
baseDao.updateById(resiEventEntity);
// 2、记录操作日志
ResiEventOperationLogEntity reCallLog=new ResiEventOperationLogEntity();
@ -607,7 +608,7 @@ public class ResiEventServiceImpl extends BaseServiceImpl<ResiEventDao, ResiEven
reCallLog.setUserIdentity(EventConstant.STAFF);
reCallLog.setActionCode(ResiEventAction.SHIFIT_PROJECT.getCode());
reCallLog.setActionDesc(ResiEventAction.SHIFIT_PROJECT.getDesc());
reCallLog.setOperateTime(resiEventEntity.getCloseCaseTime());
reCallLog.setOperateTime(resiEventEntity.getLatestOperatedTime());
resiEventOperationLogDao.insert(reCallLog);
//3、所有被艾特的人应该都通知
resiEventMentionDao.updateRedDotShow(formDTO.getEventId(),null);

5
epmet-module/gov-project/gov-project-server/src/main/resources/mapper/ProjectDao.xml

@ -392,4 +392,9 @@
AND p.ID = #{projectId}
</select>
<select id="selectByOriginId" resultType="com.epmet.entity.ProjectEntity">
select p.id from project p
where p.DEL_FLAG = '0'
AND p.ORIGIN_ID = #{originId}
</select>
</mapper>
Loading…
Cancel
Save