lcl hace 11 meses
padre
commit
d2c45abe10
Se han modificado 1 ficheros con 9 adiciones y 11 borrados
  1. 9 11
      AppStart/Helper/RecommandKingHelper.cs

+ 9 - 11
AppStart/Helper/RecommandKingHelper.cs

@@ -128,10 +128,6 @@ namespace MySystem
                 if(user.Kind == 1)
                 {
                     int uid = user.UserId;
-                    if(uid == 193523)
-                    {
-                        string ss = "123123";
-                    }
                     int ActCount = 0;
                     if(ActCount == 0)
                     {
@@ -155,9 +151,9 @@ namespace MySystem
                     if(ActCount > 0)
                     {
                         user.Op = true;
+                        function.WriteLog(user.UserId.ToString(), "推荐王达标创客名单");
                     }
                 }
-                RedisDbconn.Instance.AddList("userstmp2024", user);
             }
             // users = RedisDbconn.Instance.GetList<RecommandKingItem>("userstmp2024", 1, 99999999);
             users = users.OrderBy(m => m.Level).ToList();
@@ -167,31 +163,33 @@ namespace MySystem
                 int Count = users.Count(m => m.ParentNav.Contains(UserIdStr) && m.Op);
                 user.ActCount = Count;
                 user.ChkActCount = Count;
-                if(user.UserId == 184916)
-                {
-                    var test = users.Where(m => m.ParentNav.Contains(UserIdStr) && m.Op).ToList();
-                }
+                function.WriteLog(user.UserId + ":" + Count, "推荐王总的达标创客数量");
             }
             foreach(RecommandKingItem user in users)
             {
                 string UserIdStr = "," + user.UserId + ",";
-                if(users.Any(m => m.ParentNav.Contains(UserIdStr) && (m.ChkActCount >= 50 || m.PreAmount >= 30000000)))
+                function.WriteLog(user.UserId.ToString(), "推荐王最终的达标创客数量分析");
+                if(users.Any(m => m.ParentNav.Contains(UserIdStr) && (m.ChkActCount >= 50 || m.PreAmount >= 30000000 || Historys.Contains(m.UserId))))
                 {
                     List<RecommandKingItem> subs = users.Where(m => m.ParentUserId == user.UserId).ToList();
                     foreach(RecommandKingItem sub in subs)
                     {
+                        function.WriteLog(sub.UserId + ":" + sub.ActCount, "推荐王最终的达标创客数量分析");
                         string subUserIdStr = "," + sub.UserId + ",";
                         if(sub.ChkActCount >= 50 || sub.PreAmount >= 30000000 || Historys.Contains(sub.UserId))
                         {
                             user.ActCount -= sub.ChkActCount;
+                            function.WriteLog("减去" + sub.ChkActCount, "推荐王最终的达标创客数量分析");
                         }
-                        else if(users.Any(m => m.ParentNav.Contains(subUserIdStr) && (m.ChkActCount >= 50 || m.PreAmount >= 30000000)))
+                        else if(users.Any(m => m.ParentNav.Contains(subUserIdStr) && (m.ChkActCount >= 50 || m.PreAmount >= 30000000 || Historys.Contains(sub.UserId))))
                         {
                             RecommandKingItem tar = users.Where(m => m.ParentNav.Contains(subUserIdStr) && (m.ChkActCount >= 50 || m.PreAmount >= 30000000)).OrderBy(m => m.Level).FirstOrDefault();
                             user.ActCount -= tar.ChkActCount;
+                            function.WriteLog("减去" + tar.UserId + ":" + sub.ChkActCount, "推荐王最终的达标创客数量分析");
                         }
                     }
                 }
+                function.WriteLog("\n\n\n", "推荐王最终的达标创客数量分析");
             }
 
             int num = 0;