fix 74162 分发后提示语有缺失
This commit is contained in:
+8
-3
@@ -205,17 +205,19 @@ public class PayWorkingGroupDistributionRecordServiceImpl extends ServiceImpl<Pa
|
|||||||
throw new JeroBootException("分发失败!");
|
throw new JeroBootException("分发失败!");
|
||||||
}
|
}
|
||||||
// 发送消息
|
// 发送消息
|
||||||
|
int success = list.size();
|
||||||
|
int failed = 0;
|
||||||
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||||
String finalMsg = msg;
|
String finalMsg = msg;
|
||||||
List<String> listMsg = new ArrayList<>();
|
List<String> listMsg = new ArrayList<>();
|
||||||
list.forEach(p->{
|
for (PayContactsManagementTemporary p : list) {
|
||||||
try {
|
try {
|
||||||
List<PayWorkingGroupDistributionRecord> listStr = listPayWorkingGroupDistributionRecord.stream().filter(item->
|
List<PayWorkingGroupDistributionRecord> listStr = listPayWorkingGroupDistributionRecord.stream().filter(item->
|
||||||
(payWorkingGroupDistributionRecord.getProjectType() == PayProjectCommon.PROJECT_TYPE_FILE1) ?
|
(payWorkingGroupDistributionRecord.getProjectType() == PayProjectCommon.PROJECT_TYPE_FILE1) ?
|
||||||
Objects.equals(item.getTemporaryContactsId(),p.getId()) :
|
Objects.equals(item.getTemporaryContactsId(),p.getId()) :
|
||||||
Objects.equals(item.getContactsId(),p.getId())).collect(Collectors.toList());
|
Objects.equals(item.getContactsId(),p.getId())).collect(Collectors.toList());
|
||||||
if(CollectionUtils.isEmpty(listStr)){
|
if(CollectionUtils.isEmpty(listStr)){
|
||||||
return;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 发送消息
|
// 发送消息
|
||||||
@@ -249,10 +251,13 @@ public class PayWorkingGroupDistributionRecordServiceImpl extends ServiceImpl<Pa
|
|||||||
}
|
}
|
||||||
}catch (Exception e){
|
}catch (Exception e){
|
||||||
if(e.getMessage().contains("邮件发送") && !listMsg.contains(p.getName() + "邮件发送失败")){
|
if(e.getMessage().contains("邮件发送") && !listMsg.contains(p.getName() + "邮件发送失败")){
|
||||||
|
success--;
|
||||||
|
failed++;
|
||||||
listMsg.add(p.getCompanyName()+"-"+p.getName() + "邮件发送失败");
|
listMsg.add(p.getCompanyName()+"-"+p.getName() + "邮件发送失败");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
}
|
||||||
|
listMsg.add(0,"成功"+success+"条数据,失败"+failed+"条数据");
|
||||||
return listMsg;
|
return listMsg;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user