Browse Source

升级交易额,广电卡减去注销的用户

lcl 1 year ago
parent
commit
fc4cf3b4ae
1 changed files with 3 additions and 1 deletions
  1. 3 1
      AppStart/Helper/StatService.cs

+ 3 - 1
AppStart/Helper/StatService.cs

@@ -2061,7 +2061,9 @@ namespace MySystem
                                 check = rdb.UserTradeMonthSummary.Any(m => m.UserId == user.Id && m.TradeMonth == TradeMonth && m.SeoTitle == "team" && m.BrandId == 14);
                                 if (check)
                                 {
-                                    TradeAmount += rdb.UserTradeMonthSummary.Where(m => m.UserId == user.Id && m.TradeMonth == TradeMonth && m.SeoTitle == "team" && m.BrandId == 14).Sum(m => m.ActiveBuddyMerStatus) * 10000;
+                                    int ActCount = rdb.UserTradeMonthSummary.Where(m => m.UserId == user.Id && m.TradeMonth == TradeMonth && m.SeoTitle == "team" && m.BrandId == 14).Sum(m => m.ActiveBuddyMerStatus);
+                                    ActCount -= rdb.SimposMerchantInfo.Count(m => m.UserId == user.Id && m.Status == -1); //减去注销的用户
+                                    TradeAmount += ActCount * 10000;
                                 }
                                 ReadModels.UserLevelSet set = sets.FirstOrDefault(m => m.UpLevelGrowth <= TradeAmount && m.UpLevelIntegral > TradeAmount);
                                 if (set != null)