Commit afc7aa4e authored by 吴春's avatar 吴春

提交代码

parent d9afbd26
......@@ -487,7 +487,15 @@ namespace Mall.Module.MarketingCenter
try
{
DateTime nowTime = Convert.ToDateTime(item.CreateDate + " 00:00:00");
item.RepurchaseNum = allOrderList.Where(x => x.CreateDate < nowTime).Select(x => x.UserId).Distinct().Count();
foreach (var itemUserIds in item.UserIds.Split(","))
{
int orderNum = allOrderList.Where(x => x.CreateDate < nowTime && x.UserId.ToString() == itemUserIds).Count();
if (orderNum > 0)
{
item.RepurchaseNum +=1;
}
}
}
catch (Exception)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment