mirror of
				https://gitee.com/hhyykk/ipms-sjy.git
				synced 2025-11-04 12:18:42 +08:00 
			
		
		
		
	master代码错误
This commit is contained in:
		@@ -11,6 +11,7 @@ import org.springframework.stereotype.Service;
 | 
			
		||||
import org.springframework.validation.annotation.Validated;
 | 
			
		||||
 | 
			
		||||
import javax.annotation.Resource;
 | 
			
		||||
import java.time.LocalDateTime;
 | 
			
		||||
import java.util.Date;
 | 
			
		||||
import java.util.Map;
 | 
			
		||||
import java.util.Objects;
 | 
			
		||||
@@ -65,12 +66,12 @@ public class MailLogServiceImpl implements MailLogService {
 | 
			
		||||
    public void updateMailSendResult(Long logId, String messageId, Exception exception) {
 | 
			
		||||
        // 1. 成功
 | 
			
		||||
        if (exception == null) {
 | 
			
		||||
            mailLogMapper.updateById(new MailLogDO().setId(logId).setSendTime(new Date())
 | 
			
		||||
            mailLogMapper.updateById(new MailLogDO().setId(logId).setSendTime(LocalDateTime.now())
 | 
			
		||||
                    .setSendStatus(MailSendStatusEnum.SUCCESS.getStatus()).setSendMessageId(messageId));
 | 
			
		||||
            return;
 | 
			
		||||
        }
 | 
			
		||||
        // 2. 失败
 | 
			
		||||
        mailLogMapper.updateById(new MailLogDO().setId(logId).setSendTime(new Date())
 | 
			
		||||
        mailLogMapper.updateById(new MailLogDO().setId(logId).setSendTime(LocalDateTime.now())
 | 
			
		||||
                .setSendStatus(MailSendStatusEnum.FAILURE.getStatus()).setSendException(getRootCauseMessage(exception)));
 | 
			
		||||
 | 
			
		||||
    }
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user