|
@@ -39,12 +39,15 @@ public class OrderVisitSmsHandler : INotificationHandler<ReceiveMessageNotify>
|
|
|
.Where(m => m.SendState == ESendState.Success)
|
|
|
.OrderByDescending(m => m.CreationTime)
|
|
|
.FirstAsync(cancellationToken);
|
|
|
- if (msg.SendTime!.Value.AddDays(2) < DateTime.Now)
|
|
|
+ if (msg != null)
|
|
|
{
|
|
|
- _logRepository.Add("短信回访-不处理", notification, "msg.SendTime 已经超过2天, 不处理", "OrderVisitSmsHandler", 0);
|
|
|
- return;
|
|
|
+ if (msg.SendTime!.Value.AddDays(2) < DateTime.Now)
|
|
|
+ {
|
|
|
+ _logRepository.Add("短信回访-不处理", notification, "msg.SendTime 已经超过2天, 不处理", "OrderVisitSmsHandler", 0);
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ await _orderVisitDomainService.UpdateSmsReplyAsync(notification.NotifyDto);
|
|
|
}
|
|
|
- await _orderVisitDomainService.UpdateSmsReplyAsync(notification.NotifyDto);
|
|
|
}
|
|
|
}
|
|
|
|