|
|
@ -795,10 +795,10 @@ public class ItemServiceImpl extends BaseServiceImpl<ItemDao, ItemEntity> implem |
|
|
|
} |
|
|
|
//居民端项目关闭、结案-短信通知
|
|
|
|
if (ItemHandleCategoryEnum.HANDLE_CLOSE.getValue() == dto.getHandleCategory() || |
|
|
|
ItemHandleCategoryEnum.HANDLE_CLOSING_CASE.getValue() == dto.getHandleCategory()){ |
|
|
|
ItemHandleCategoryEnum.HANDLE_CLOSING_CASE.getValue() == dto.getHandleCategory()) { |
|
|
|
List<String> list = new ArrayList<>(); |
|
|
|
list.add(entity.getMobile()); |
|
|
|
this.projectSmsNotification(dto,list); |
|
|
|
this.projectSmsNotification(dto, list); |
|
|
|
} |
|
|
|
//工作端 根据不同的处理方式,进行短信通知
|
|
|
|
this.workProjectHandle(dto); |
|
|
@ -1305,30 +1305,30 @@ public class ItemServiceImpl extends BaseServiceImpl<ItemDao, ItemEntity> implem |
|
|
|
* @Author: zy |
|
|
|
* @Date: 2020-01-09 |
|
|
|
*/ |
|
|
|
private void workProjectHandle(ItemHandleSubmitFormDTO dto){ |
|
|
|
private void workProjectHandle(ItemHandleSubmitFormDTO dto) { |
|
|
|
UserDetail user = SecurityUser.getUser(); //获取当前登录人信息
|
|
|
|
List<Long> deptId = new ArrayList<>(); |
|
|
|
if(ItemHandleCategoryEnum.HANDLE_CIRCULATION_ASSISTANCE.getValue() == dto.getHandleCategory()){ |
|
|
|
if (ItemHandleCategoryEnum.HANDLE_CIRCULATION_ASSISTANCE.getValue() == dto.getHandleCategory()) { |
|
|
|
List<ItemCirculationDeptResultDTO> deptList = dto.getDeptResultDTOS(); |
|
|
|
for (int i =0; i < deptList.size(); i++) { |
|
|
|
ItemCirculationDeptResultDTO indexDto = (ItemCirculationDeptResultDTO)deptList.get(i); |
|
|
|
for (int i = 0; i < deptList.size(); i++) { |
|
|
|
ItemCirculationDeptResultDTO indexDto = (ItemCirculationDeptResultDTO) deptList.get(i); |
|
|
|
deptId.add(indexDto.getDeptId()); |
|
|
|
} |
|
|
|
issueOverseeResultsTask.getUserPhoneByListDeptId(dto, deptId,user.getTypeKey());//吹哨处理 a吹b 向b部门下的,所有人员发送短信
|
|
|
|
if (user.getTypeKey().equals(OrganizationTypeConstant.ORG_TYPE_STREET_PARTY)){ //如果是街道做吹哨处理, 做回应处理
|
|
|
|
issueOverseeResultsTask.getUserPhoneByListDeptId(dto, deptId, user.getTypeKey());//吹哨处理 a吹b 向b部门下的,所有人员发送短信
|
|
|
|
if (user.getTypeKey().equals(OrganizationTypeConstant.ORG_TYPE_STREET_PARTY)) { //如果是街道做吹哨处理, 做回应处理
|
|
|
|
this.superiorDeptSmsHandle(dto); |
|
|
|
} |
|
|
|
} else if(ItemHandleCategoryEnum.HANDLE_CLOSE.getValue() == dto.getHandleCategory() || |
|
|
|
ItemHandleCategoryEnum.HANDLE_CLOSING_CASE.getValue() == dto.getHandleCategory()){ |
|
|
|
deptId = baseDao.queryDeptIdList(dto.getId(),user.getDeptId()); |
|
|
|
if (deptId != null && deptId.size() > 0){ |
|
|
|
issueOverseeResultsTask.getUserPhoneByListDeptId(dto, deptId,user.getTypeKey());//关闭/结案 当前项目的所有部门ID,下的人员发送短信,且不等于当前部门ID
|
|
|
|
} else if (ItemHandleCategoryEnum.HANDLE_CLOSE.getValue() == dto.getHandleCategory() || |
|
|
|
ItemHandleCategoryEnum.HANDLE_CLOSING_CASE.getValue() == dto.getHandleCategory()) { |
|
|
|
deptId = baseDao.queryDeptIdList(dto.getId(), user.getDeptId()); |
|
|
|
if (deptId != null && deptId.size() > 0) { |
|
|
|
issueOverseeResultsTask.getUserPhoneByListDeptId(dto, deptId, user.getTypeKey());//关闭/结案 当前项目的所有部门ID,下的人员发送短信,且不等于当前部门ID
|
|
|
|
} |
|
|
|
} else if(ItemHandleCategoryEnum.HANDLE_I_HANDLE.getValue() == dto.getHandleCategory()){ |
|
|
|
if (!user.getTypeKey().equals(OrganizationTypeConstant.ORG_TYPE_GRID_PARTY)){//回应
|
|
|
|
} else if (ItemHandleCategoryEnum.HANDLE_I_HANDLE.getValue() == dto.getHandleCategory()) { |
|
|
|
if (!user.getTypeKey().equals(OrganizationTypeConstant.ORG_TYPE_GRID_PARTY)) {//回应
|
|
|
|
this.superiorDeptSmsHandle(dto); |
|
|
|
} |
|
|
|
}else if(ItemHandleCategoryEnum.HANDLE_REPORT.getValue() == dto.getHandleCategory()){ //上报网格化平台
|
|
|
|
} else if (ItemHandleCategoryEnum.HANDLE_REPORT.getValue() == dto.getHandleCategory()) { //上报网格化平台
|
|
|
|
this.superiorDeptSmsHandle(dto); |
|
|
|
} |
|
|
|
} |
|
|
@ -1341,25 +1341,26 @@ public class ItemServiceImpl extends BaseServiceImpl<ItemDao, ItemEntity> implem |
|
|
|
* @Author: zy |
|
|
|
* @Date: 2020-01-14 |
|
|
|
*/ |
|
|
|
private void superiorDeptSmsHandle(ItemHandleSubmitFormDTO dto){ |
|
|
|
private void superiorDeptSmsHandle(ItemHandleSubmitFormDTO dto) { |
|
|
|
UserDetail user = SecurityUser.getUser(); //获取当前登录人信息
|
|
|
|
List<Long> deptId = new ArrayList<>(); |
|
|
|
Long queryDePtId = user.getDeptId(); |
|
|
|
while (true){ |
|
|
|
List<Long> createdDeptId = baseDao.queryParentDeptId(dto.getId(),queryDePtId); |
|
|
|
if (createdDeptId != null && createdDeptId.size() > 0){ |
|
|
|
for(Long ll : createdDeptId){ |
|
|
|
while (true) { |
|
|
|
List<Long> createdDeptId = baseDao.queryParentDeptId(dto.getId(), queryDePtId); |
|
|
|
if (createdDeptId != null && createdDeptId.size() > 0) { |
|
|
|
for (Long ll : createdDeptId) { |
|
|
|
deptId.add(ll); |
|
|
|
queryDePtId = ll; |
|
|
|
} |
|
|
|
}else{ |
|
|
|
} else { |
|
|
|
break; |
|
|
|
} |
|
|
|
} |
|
|
|
if (deptId != null && deptId.size() > 0) { |
|
|
|
issueOverseeResultsTask.getUserPhoneByListDeptId(dto, deptId,user.getTypeKey());//做回应处理,向部门下的所有人员发送短信
|
|
|
|
issueOverseeResultsTask.getUserPhoneByListDeptId(dto, deptId, user.getTypeKey());//做回应处理,向部门下的所有人员发送短信
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* @Description: 居民端:项目处理,发送短信 |
|
|
|
* @Param: [dto] |
|
|
@ -1368,17 +1369,18 @@ public class ItemServiceImpl extends BaseServiceImpl<ItemDao, ItemEntity> implem |
|
|
|
* @Author: zy |
|
|
|
* @Date: 2020-01-08 |
|
|
|
*/ |
|
|
|
public void projectSmsNotification(ItemHandleSubmitFormDTO dto, List<String> userMobiles){ |
|
|
|
public void projectSmsNotification(ItemHandleSubmitFormDTO dto, List<String> userMobiles) { |
|
|
|
// 审核操作发送短信
|
|
|
|
SmsNoticeFormDTO sms = new SmsNoticeFormDTO(); |
|
|
|
sms.setMobiles(userMobiles); |
|
|
|
if (ItemHandleCategoryEnum.HANDLE_CLOSE.getValue() == dto.getHandleCategory()) { // 关闭
|
|
|
|
sms.setSmsTemplateType(SysSmsTemplateConstant.SMS_TEMPLATE_RESIDENTS_ITEM_CLOSED); |
|
|
|
}else if (ItemHandleCategoryEnum.HANDLE_CLOSING_CASE.getValue() == dto.getHandleCategory()){ //结案
|
|
|
|
} else if (ItemHandleCategoryEnum.HANDLE_CLOSING_CASE.getValue() == dto.getHandleCategory()) { //结案
|
|
|
|
sms.setSmsTemplateType(SysSmsTemplateConstant.SMS_TEMPLATE_RESIDENTS_ITEM_SETTLE); |
|
|
|
} |
|
|
|
issueOverseeResultsTask.sendSmsNotice(sms); |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* @param |
|
|
|
* @return com.elink.esua.epdc.commons.tools.utils.Result<java.util.List < com.elink.esua.epdc.dto.item.result.ItemHandleResultDTO>> |
|
|
@ -1457,17 +1459,16 @@ public class ItemServiceImpl extends BaseServiceImpl<ItemDao, ItemEntity> implem |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* 组织机构信息处理 |
|
|
|
* |
|
|
|
* @params [dto, eventsList] |
|
|
|
* @return java.util.List<com.elink.esua.epdc.modules.events.entity.EpdcEventsEntity> |
|
|
|
* @params [dto, eventsList] |
|
|
|
* @author liuchuang |
|
|
|
* @since 2020/3/7 1:17 |
|
|
|
*/ |
|
|
|
private List<ItemEntity> handleOrganizationInfo(OrganizationModifyDTO dto, List<ItemDTO> itemList) { |
|
|
|
List<ItemEntity> entities = new ArrayList<>(); |
|
|
|
for (ItemDTO item: itemList) { |
|
|
|
for (ItemDTO item : itemList) { |
|
|
|
ItemEntity entity = new ItemEntity(); |
|
|
|
if (StringUtils.isNotEmpty(item.getParentDeptIds()) && StringUtils.isNotEmpty(item.getParentDeptNames())) { |
|
|
|
List<String> parentDeptIds = Arrays.asList(item.getParentDeptIds().split(",")); |
|
|
@ -1517,18 +1518,42 @@ public class ItemServiceImpl extends BaseServiceImpl<ItemDao, ItemEntity> implem |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
public List<ItemCirculationDeptResultDTO> listWhistlingDept() { |
|
|
|
UserDetail user = SecurityUser.getUser(); |
|
|
|
Result<List<Long>> roleIdList = adminFeignClient.getRoleIdList(user.getId()); |
|
|
|
if (!roleIdList.success() || roleIdList.getData().isEmpty()) { |
|
|
|
throw new RenException("获取角色Id列表失败"); |
|
|
|
} |
|
|
|
|
|
|
|
//可流转部门
|
|
|
|
List<ItemCirculationDeptResultDTO> deptResultDTOS = handleRoleCategoryService.listItemCirculationDeptResultDTO(roleIdList.getData()); |
|
|
|
return deptResultDTOS; |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
public List<ItemHandleResultDTO> listHandleCategory() { |
|
|
|
UserDetail user = SecurityUser.getUser(); |
|
|
|
Result<List<Long>> roleIdList = adminFeignClient.getRoleIdList(user.getId()); |
|
|
|
if (!roleIdList.success() || roleIdList.getData().isEmpty()) { |
|
|
|
throw new RenException("获取角色Id列表失败"); |
|
|
|
} |
|
|
|
//可处理操作
|
|
|
|
List<ItemHandleResultDTO> handleResultDTOS = handleRoleCategoryService.listItemHandleResultDTO(roleIdList.getData()); |
|
|
|
return handleResultDTOS; |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* 分类信息处理 |
|
|
|
* |
|
|
|
* @params [dto, eventsList] |
|
|
|
* @return java.util.List<com.elink.esua.epdc.modules.events.entity.ItemEntity> |
|
|
|
* @params [dto, eventsList] |
|
|
|
* @author liuchuang |
|
|
|
* @since 2020/3/7 17:00 |
|
|
|
*/ |
|
|
|
private List<ItemEntity> handleCategoryInfo(CategoryModifyDTO dto, List<ItemDTO> itemList) { |
|
|
|
List<ItemEntity> entities = new ArrayList<>(); |
|
|
|
for (ItemDTO item: itemList) { |
|
|
|
for (ItemDTO item : itemList) { |
|
|
|
if (StringUtils.isNotEmpty(item.getCategoryFullName())) { |
|
|
|
List<String> categoryFullName = Arrays.asList(item.getCategoryFullName().split("-")); |
|
|
|
int index = categoryFullName.indexOf(dto.getOldCategoryName()); |
|
|
|