diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectMainDailyDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectMainDailyDao.xml index 11ce137aab..fdf90af1f3 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectMainDailyDao.xml +++ b/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} 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} AND DATE_ID <= #{dateId} diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/project/ProjectDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/project/ProjectDao.xml index 7b217ec4ff..476ae619c8 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/project/ProjectDao.xml +++ b/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' diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/EventTitleOrgResultDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/EventTitleOrgResultDTO.java new file mode 100644 index 0000000000..50b05afb6c --- /dev/null +++ b/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; +} diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java index 53e6330d06..cba514d051 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java +++ b/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> selectGridStaffByGridIds(@RequestBody List gridIds){ return new Result>().ok(customerStaffGridService.selectGridStaffByGridIds(gridIds)); } + + /** + * @Description 查询ORG + * @Param userId + * @author zxc + * @date 2021/8/5 5:36 下午 + */ + @PostMapping("eventorg") + public Result> eventOrg(@LoginUser TokenDto tokenDto){ + return new Result>().ok(customerStaffGridService.eventOrg(tokenDto.getUserId())); + } } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffGridDao.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffGridDao.java index d9ce1b0e61..426a0e6b3a 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffGridDao.java +++ b/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 { * @date 2021/6/8 3:36 下午 */ List selectGridStaffByGridIds(@Param("gridIds") List gridIds); + + /** + * @Description 查询ORG + * @Param userId + * @author zxc + * @date 2021/8/5 5:36 下午 + */ + List eventOrg(@Param("userId") String userId); } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java index 0cf4041cce..1e78f3725b 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java +++ b/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 selectGridStaffByGridIds(List gridIds); + + /** + * @Description 查询ORG + * @Param userId + * @author zxc + * @date 2021/8/5 5:36 下午 + */ + List eventOrg(String userId); } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java index ac8abc82fc..27d3da6576 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java +++ b/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 eventOrg(String userId) { + return baseDao.eventOrg(userId); + } } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml index 5e08a59b97..05277137da 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml @@ -102,6 +102,27 @@ ) + + + insert into customer_staff_grid diff --git a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/dao/ProjectDao.java b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/dao/ProjectDao.java index a4c1b69b36..0040584f81 100644 --- a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/dao/ProjectDao.java +++ b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/dao/ProjectDao.java @@ -215,4 +215,6 @@ public interface ProjectDao extends BaseDao { * @date 2021/8/4 2:43 下午 */ EventProjectInfoDTO selectEventProjectInfo(@Param("projectId")String projectId); + + List selectByOriginId(String originId); } \ No newline at end of file diff --git a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java index 7a5ac21888..1f0fd17a0d 100644 --- a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java +++ b/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 { * @return java.util.List */ List getUnResolvedListByGrid(ShiftProjectListFromDTO fromDTO); + + List getByOriginId(String eventId); } \ No newline at end of file diff --git a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java index f15a2a7c24..bc6a2616c7 100644 --- a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java +++ b/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 getByOriginId(String originId) { + return baseDao.selectByOriginId(originId); + } + } \ No newline at end of file diff --git a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectTraceServiceImpl.java b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectTraceServiceImpl.java index 676b3bdc56..1e4a1b64b4 100644 --- a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectTraceServiceImpl.java +++ b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectTraceServiceImpl.java @@ -631,6 +631,10 @@ public class ProjectTraceServiceImpl implements ProjectTraceS if(null==resiEventEntity||resiEventEntity.getShiftProject()){ throw new RenException(EpmetErrorCode.RESI_EVENT_SHIFT_PROJECT.getCode(),EpmetErrorCode.RESI_EVENT_SHIFT_PROJECT.getMsg()); } + List 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 staffList = formDTO.getStaffList(); //1.文字内容安全校验 List list = new ArrayList<>(); diff --git a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ResiEventServiceImpl.java b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ResiEventServiceImpl.java index b588736e20..bc013eb0fc 100644 --- a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ResiEventServiceImpl.java +++ b/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 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 + \ No newline at end of file