Commit b22f966d authored by liudong1993's avatar liudong1993

返佣调整

parent 61ed4acc
...@@ -3704,9 +3704,9 @@ namespace Mall.Module.Product ...@@ -3704,9 +3704,9 @@ namespace Mall.Module.Product
int MaxGrade = fxNumList.Max(x => x.Grade); int MaxGrade = fxNumList.Max(x => x.Grade);
if (FXGModel.Grade < MaxGrade) if (FXGModel.Grade < MaxGrade)
{ {
//后面的全部不返佣 //后面的全部不返佣 2020-08-06 刘东 继续找下一级返佣
UserId = 0; UserId = numodel.SuperiorId ?? 0;
break; continue;
} }
int MaxGradeNum = fxNumList.Where(x => x.Grade == FXGModel.Grade).Count(); int MaxGradeNum = fxNumList.Where(x => x.Grade == FXGModel.Grade).Count();
int MaxGradeId = fxNumList.Where(x => x.Grade == MaxGrade).FirstOrDefault()?.GradeId ?? 0; int MaxGradeId = fxNumList.Where(x => x.Grade == MaxGrade).FirstOrDefault()?.GradeId ?? 0;
...@@ -3803,7 +3803,7 @@ namespace Mall.Module.Product ...@@ -3803,7 +3803,7 @@ namespace Mall.Module.Product
{ {
//后面的全部不返佣 //后面的全部不返佣
UserId = 0; UserId = 0;
break; numodel = n1umodel;//继续查找下一级 2020-08-06 刘东
} }
else if (FXG2Model.Grade > MaxGrade) else if (FXG2Model.Grade > MaxGrade)
{ {
...@@ -4437,7 +4437,7 @@ namespace Mall.Module.Product ...@@ -4437,7 +4437,7 @@ namespace Mall.Module.Product
MallBaseId = demodel.MallBaseId, MallBaseId = demodel.MallBaseId,
OrderDetailId = item.Id, OrderDetailId = item.Id,
OrderId = OrderId, OrderId = OrderId,
Remark = "商品总额:" + (item.Final_Price ?? 0) * (item.Number ?? 0) + ",总成本:" + (item.CostMoney ?? 0) * (item.Number ?? 0) + ",总返佣:" + item.TCommissionMoney + ",总利润:" + Profit, Remark = "商品总额:" + (item.Final_Price ?? 0) + ",总成本:" + (item.CostMoney ?? 0) * (item.Number ?? 0) + ",总返佣:" + item.TCommissionMoney + ",总利润:" + Profit,
RemitStatus = 2, RemitStatus = 2,
TenantId = demodel.TenantId, TenantId = demodel.TenantId,
Type = 1, Type = 1,
......
This diff is collapsed.
...@@ -103,7 +103,7 @@ namespace Mall.Repository.User ...@@ -103,7 +103,7 @@ namespace Mall.Repository.User
builder.Append($@" SELECT a.*,b.`Name` as UserName builder.Append($@" SELECT a.*,b.`Name` as UserName
FROM rb_vip_buy as a FROM rb_vip_buy as a
INNER JOIN rb_member_user as b on a.UserId=b.Id INNER JOIN rb_member_user as b on a.UserId=b.Id
INNER JOIN rb_vipbuy_commission c on a.Id = c.OrderId Left JOIN rb_vipbuy_commission c on a.Id = c.OrderId
WHERE a.{nameof(RB_Vip_Buy_Extend.Status)}=0 "); WHERE a.{nameof(RB_Vip_Buy_Extend.Status)}=0 ");
if (query != null) if (query != null)
{ {
......
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