Browse Source

打日志区分环境

lcl 9 months ago
parent
commit
06a2f04af9
2 changed files with 9 additions and 2 deletions
  1. 8 1
      Util/HaoDa/CheckWeChatSignService.cs
  2. 1 1
      Util/LogHelper.cs

+ 8 - 1
Util/HaoDa/CheckWeChatSignService.cs

@@ -60,7 +60,14 @@ namespace MySystem
                     });
                     Thread.Sleep(10000);
                 }
-                Thread.Sleep(3600000);
+                if(Library.ConfigurationManager.EnvironmentFlag == 2)
+                {
+                    Thread.Sleep(300000);
+                }
+                else
+                {
+                    Thread.Sleep(3600000);
+                }
             }
         }
 

+ 1 - 1
Util/LogHelper.cs

@@ -17,7 +17,7 @@ public class LogHelper
 
     public void WriteLog(string Content, string FileName, string BrandId = "0")
     {
-        if(BlackList.Contains(FileName))
+        if(BlackList.Contains(FileName) && Library.ConfigurationManager.EnvironmentFlag == 2)
         {
             string key = function.MD532(Content + FileName);
             if(!string.IsNullOrEmpty(RedisDbconn.Instance.Get<string>(key)))