diff --git a/SGGL/BLL/PZHGL/GJSX/GJSXMonitorService.cs b/SGGL/BLL/PZHGL/GJSX/GJSXMonitorService.cs index 737633b6..345270c4 100644 --- a/SGGL/BLL/PZHGL/GJSX/GJSXMonitorService.cs +++ b/SGGL/BLL/PZHGL/GJSX/GJSXMonitorService.cs @@ -184,8 +184,7 @@ namespace BLL " + tbodyStr.ToString() + ""; mail.Body = bodyStr; - - bool send= PushEmail(mail); + bool send = PushEmail(mail); } } } @@ -196,6 +195,7 @@ namespace BLL } catch (Exception ex) { + ErrLogInfo.WriteLog("关键事项邮件预警", ex); } } @@ -216,16 +216,17 @@ namespace BLL client.DeliveryMethod = SmtpDeliveryMethod.Network; client.UseDefaultCredentials = false; client.Credentials = new NetworkCredential(pops.EmailYx, pops.EmailPass);//替换为你的邮箱和服务授权码 - //client.Timeout = 6000; //6秒超时 + //client.Timeout = 6000;//6秒超时 try { client.Send(mail); - client.Dispose(); //释放资源 + client.Dispose();//释放资源 return true; //Console.WriteLine("Email sent successfully."); } catch (Exception ex) { + ErrLogInfo.WriteLog("关键事项发送邮件预警", ex); return false; //Console.WriteLine("Email sending failed: " + ex.Message); } diff --git a/SGGL/Model/NPOIImg.cs b/SGGL/Model/NPOIImg.cs new file mode 100644 index 00000000..d4cbe673 --- /dev/null +++ b/SGGL/Model/NPOIImg.cs @@ -0,0 +1,12 @@ + +namespace Model +{ + public class NPOIImg + { + public string SavePath { get; set; } + + public int Row { get; set; } + + public int Col { get; set; } + } +}