|
@@ -105,10 +105,10 @@ namespace MySystem
|
|
|
{
|
|
|
TradeAmount += mpmaindb.UserAmountSummary.Where(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 1).Sum(m => m.TotalAmount) * 4;
|
|
|
}
|
|
|
- check = mpmaindb.UserAmountSummary.Any(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 1);
|
|
|
+ check = mpmaindb.UserAmountSummary.Any(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 0);
|
|
|
if (check)
|
|
|
{
|
|
|
- TradeAmount += mpmaindb.UserAmountSummary.Where(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 1).Sum(m => m.TotalAmount);
|
|
|
+ TradeAmount += mpmaindb.UserAmountSummary.Where(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 0).Sum(m => m.TotalAmount);
|
|
|
}
|
|
|
//码牌团队交易额(银联)
|
|
|
check = mpmaindb2.UserAmountSummary.Any(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 1);
|
|
@@ -116,10 +116,10 @@ namespace MySystem
|
|
|
{
|
|
|
TradeAmount += mpmaindb2.UserAmountSummary.Where(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 1).Sum(m => m.TotalAmount) * 4;
|
|
|
}
|
|
|
- check = mpmaindb2.UserAmountSummary.Any(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 1);
|
|
|
+ check = mpmaindb2.UserAmountSummary.Any(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 0);
|
|
|
if (check)
|
|
|
{
|
|
|
- TradeAmount += mpmaindb2.UserAmountSummary.Where(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 1).Sum(m => m.TotalAmount);
|
|
|
+ TradeAmount += mpmaindb2.UserAmountSummary.Where(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.IsAct == 0).Sum(m => m.TotalAmount);
|
|
|
}
|
|
|
//广电卡扶持期按1万/张计入职级
|
|
|
check = readdb.UserTradeMonthSummary.Any(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.BrandId == 14);
|
|
@@ -127,10 +127,10 @@ namespace MySystem
|
|
|
{
|
|
|
int ActCount = readdb.UserTradeMonthSummary.Where(m => m.UserId == UserId && m.TradeMonth == month && m.SeoTitle == "team" && m.BrandId == 14).Sum(m => m.ActiveBuddyMerStatus);
|
|
|
ActCount += UserDataDbconn.Instance.GetSimActTradeAmt(UserId, month, "Team");
|
|
|
- if(readdb.UserSimActSummary.Any(m => m.UserId == UserId && m.Kind == 1))
|
|
|
- {
|
|
|
- ActCount -= readdb.UserSimActSummary.Where(m => m.UserId == UserId && m.Kind == 1).Sum(m => m.ActCount);
|
|
|
- }
|
|
|
+ // if(readdb.UserSimActSummary.Any(m => m.UserId == UserId && m.Kind == 1))
|
|
|
+ // {
|
|
|
+ // ActCount -= readdb.UserSimActSummary.Where(m => m.UserId == UserId && m.Kind == 1).Sum(m => m.ActCount);
|
|
|
+ // }
|
|
|
TradeAmount += ActCount * 10000;
|
|
|
}
|
|
|
sql += "insert into LeaderCompTradeStat (CreateDate,UserId,StatMonth,TradeAmount) values (now(), " + UserId + ", '" + month + "-" + checkMonth + "', " + TradeAmount + ");\n";
|