| | |
| | | config.getCommunityHandlingTime() |
| | | ); |
| | | |
| | | if(!complaintTimeoutList.isEmpty()) { |
| | | // 当前不在发送 |
| | | complaintService.update(new LambdaUpdateWrapper<Complaint>().in(Complaint::getId, complaintTimeoutList.stream().map(ComplaintTimeout::getComplaintId).collect(Collectors.toList())).set(Complaint::getNowLevelSms, 1)); |
| | | |
| | | } |
| | | |
| | | Map<Integer, List<ComplaintTimeout>> timeOutMap = complaintTimeoutList.stream() |
| | | .collect(Collectors.groupingBy(ComplaintTimeout::getNowLevel)); |
| | |
| | | List<String> districtPhoneList1 = districtUserList.stream().filter(e->e.getSystemRoleId()==2).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | collect.forEach(complaintTimeout -> { |
| | | // 发送短信 |
| | | if(!districtPhoneList.isEmpty()){ |
| | | if(!districtPhoneList.isEmpty() && !complaintTimeout.getProblemType().equals("检举控告")){ |
| | | AliSmsUtil.sendTimeoutMessageAdmin(districtPhoneList,complaintTimeout.getSerialNumber()); |
| | | } |
| | | if(!districtPhoneList1.isEmpty()){ |
| | |
| | | List<String> districtPhoneList2 = systemUsers.stream().filter(e->e.getSystemRoleId()==1).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | List<String> districtPhoneList3 = systemUsers.stream().filter(e->e.getSystemRoleId()==2).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | // 发送短信 |
| | | if(!districtPhoneList2.isEmpty()){ |
| | | if(!districtPhoneList2.isEmpty() && !complaintTimeout.getProblemType().equals("检举控告")){ |
| | | AliSmsUtil.sendTimeoutMessageAdmin(districtPhoneList2,complaintTimeout.getSerialNumber()); |
| | | } |
| | | if(!districtPhoneList3.isEmpty()){ |
| | |
| | | } |
| | | }else { |
| | | // 发送短信 |
| | | if(!districtPhoneList.isEmpty()){ |
| | | if(!districtPhoneList.isEmpty() && !complaintTimeout.getProblemType().equals("检举控告")){ |
| | | AliSmsUtil.sendTimeoutMessageAdmin(districtPhoneList,complaintTimeout.getSerialNumber()); |
| | | } |
| | | if(!districtPhoneList1.isEmpty()){ |
| | |
| | | List<String> streetPhoneList = streetUserList.stream().filter(e->e.getSystemRoleId()==1 && e.getStreetId().equals(complaintTimeout.getSuperiorId().toString())).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | List<String> streetPhoneList1 = streetUserList.stream().filter(e->e.getSystemRoleId()==2 && e.getStreetId().equals(complaintTimeout.getSuperiorId().toString())).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | // 发送短信 |
| | | if(!streetPhoneList.isEmpty()){ |
| | | if(!streetPhoneList.isEmpty() && !complaintTimeout.getProblemType().equals("检举控告")){ |
| | | AliSmsUtil.sendTimeoutMessageAdmin(streetPhoneList,complaintTimeout.getSerialNumber()); |
| | | } |
| | | if(!streetPhoneList1.isEmpty()){ |
| | |
| | | List<String> streetPhoneList2 = systemUsers.stream().filter(e->e.getSystemRoleId()==1).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | List<String> streetPhoneList3 = systemUsers.stream().filter(e->e.getSystemRoleId()==2).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | // 发送短信 |
| | | if(!streetPhoneList2.isEmpty()){ |
| | | if(!streetPhoneList2.isEmpty() && !complaintTimeout.getProblemType().equals("检举控告")){ |
| | | AliSmsUtil.sendTimeoutMessageAdmin(streetPhoneList2,complaintTimeout.getSerialNumber()); |
| | | } |
| | | if(!streetPhoneList3.isEmpty()){ |
| | |
| | | List<String> streetPhoneList = streetUserList.stream().filter(e->e.getSystemRoleId()==1 && e.getStreetId().equals(complaintTimeout.getSuperiorId().toString())).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | List<String> streetPhoneList1 = streetUserList.stream().filter(e->e.getSystemRoleId()==2 && e.getStreetId().equals(complaintTimeout.getSuperiorId().toString())).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | // 发送短信 |
| | | if(!streetPhoneList.isEmpty()){ |
| | | if(!streetPhoneList.isEmpty() && !complaintTimeout.getProblemType().equals("检举控告")){ |
| | | AliSmsUtil.sendTimeoutMessageAdmin(streetPhoneList,complaintTimeout.getSerialNumber()); |
| | | } |
| | | if(!streetPhoneList1.isEmpty()){ |
| | |
| | | List<String> communityPhoneList1 = communityUserList.stream().filter(e->e.getSystemRoleId()==2 && e.getCommunityId().equals(complaintTimeout.getSuperiorId())).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | |
| | | // 发送短信 |
| | | if(!communityPhoneList.isEmpty()){ |
| | | if(!communityPhoneList.isEmpty() && !complaintTimeout.getProblemType().equals("检举控告")){ |
| | | AliSmsUtil.sendTimeoutMessageAdmin(communityPhoneList, complaintTimeout.getSerialNumber()); |
| | | } |
| | | if(!communityPhoneList1.isEmpty()){ |
| | |
| | | List<String> communityPhoneList2 = systemUsers.stream().filter(e->e.getSystemRoleId()==1).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | List<String> communityPhoneList3 = systemUsers.stream().filter(e->e.getSystemRoleId()==2).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | // 发送短信 |
| | | if(!communityPhoneList2.isEmpty()){ |
| | | if(!communityPhoneList2.isEmpty() && !complaintTimeout.getProblemType().equals("检举控告")){ |
| | | AliSmsUtil.sendTimeoutMessageAdmin(communityPhoneList2, complaintTimeout.getSerialNumber()); |
| | | } |
| | | if(!communityPhoneList3.isEmpty()){ |
| | |
| | | List<String> communityPhoneList = communityUserList.stream().filter(e->e.getSystemRoleId()==1 && e.getCommunityId().equals(complaintTimeout.getSuperiorId())).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | List<String> communityPhoneList1 = communityUserList.stream().filter(e->e.getSystemRoleId()==2 && e.getCommunityId().equals(complaintTimeout.getSuperiorId())).map(SystemUser::getPhone).collect(Collectors.toList()); |
| | | // 发送短信 |
| | | if(!communityPhoneList.isEmpty()){ |
| | | if(!communityPhoneList.isEmpty() && !complaintTimeout.getProblemType().equals("检举控告")){ |
| | | AliSmsUtil.sendTimeoutMessageAdmin(communityPhoneList, complaintTimeout.getSerialNumber()); |
| | | } |
| | | if(!communityPhoneList1.isEmpty()){ |
| | |
| | | } |
| | | |
| | | |
| | | if(!complaintTimeoutList.isEmpty()) { |
| | | // 短信发送完成 当前不在发送 |
| | | complaintService.update(new LambdaUpdateWrapper<Complaint>().in(Complaint::getId, complaintTimeoutList.stream().map(ComplaintTimeout::getComplaintId).collect(Collectors.toList())).set(Complaint::getNowLevelSms, 1)); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | | |
| | | } |