Commit d4da3063 authored by liudong1993's avatar liudong1993

1

parent 914858a2
...@@ -1141,7 +1141,7 @@ namespace Edu.Module.Course ...@@ -1141,7 +1141,7 @@ namespace Edu.Module.Course
decimal bdCommission = bdList.Where(x => x.OrderId == qitem.OrderId).Sum(x => x.CommissionMoeny); decimal bdCommission = bdList.Where(x => x.OrderId == qitem.OrderId).Sum(x => x.CommissionMoeny);
//decimal tCommission = AchEmpList.Where(x => x.Type == 3 && x.OrderId == qitem.OrderId).Sum(x => x.PushMoney); //decimal tCommission = AchEmpList.Where(x => x.Type == 3 && x.OrderId == qitem.OrderId).Sum(x => x.PushMoney);
decimal orderYj = qitem.PreferPrice - qitem.DiscountMoney - qitem.PlatformTax - qitem.TextbookFee - bdCommission; decimal orderYj = qitem.PreferPrice - qitem.DiscountMoney - qitem.PlatformTax - qitem.TextbookFee - bdCommission;
if (qitem.HelpEnterId > 0) { orderYj = orderYj / 2; } //if (qitem.HelpEnterId > 0) { orderYj = orderYj / 2; }
AchEmpList.Add(new RB_Sell_Achievements_Emp_ViewModel() AchEmpList.Add(new RB_Sell_Achievements_Emp_ViewModel()
{ {
EmpId = qitem.EnterID, EmpId = qitem.EnterID,
...@@ -1160,8 +1160,9 @@ namespace Edu.Module.Course ...@@ -1160,8 +1160,9 @@ namespace Edu.Module.Course
PeopleNumMoney = qitem.Refund <= 0 ? awardModel?.Rate ?? 0 : 0, PeopleNumMoney = qitem.Refund <= 0 ? awardModel?.Rate ?? 0 : 0,
Type = 1, Type = 1,
IsCommonDept = item.IsDeptAward, IsCommonDept = item.IsDeptAward,
Remark = "当月业绩:" + TotalYj + (TRefund != 0 ? "(其中退费:" + TRefund + ")" : "") + ";订单b2b返佣:" + bdCommission + ";订单业绩:" + orderYj + (qitem.HelpEnterId > 0 ? ";此单由试听转化,销售额减半计算" : "") + ";当月部门人头:" + PeopleNum + "人,人头奖励:" + (awardModel?.Rate ?? 0) Remark = "当月业绩:" + TotalYj + (TRefund != 0 ? "(其中退费:" + TRefund + ")" : "") + ";订单b2b返佣:" + bdCommission + ";订单业绩:" + orderYj + ";当月部门人头:" + PeopleNum + "人,人头奖励:" + (awardModel?.Rate ?? 0)
}); });//(qitem.HelpEnterId > 0 ? ";此单由试听转化,销售额减半计算" : "")
} }
} }
else if((awardModel?.Rate ?? 0) > 0) else if((awardModel?.Rate ?? 0) > 0)
...@@ -1172,7 +1173,7 @@ namespace Edu.Module.Course ...@@ -1172,7 +1173,7 @@ namespace Edu.Module.Course
//当前订单的业绩 //当前订单的业绩
decimal bdCommission = bdList.Where(x => x.OrderId == qitem.OrderId).Sum(x => x.CommissionMoeny); decimal bdCommission = bdList.Where(x => x.OrderId == qitem.OrderId).Sum(x => x.CommissionMoeny);
decimal orderYj = qitem.PreferPrice - qitem.DiscountMoney - qitem.PlatformTax - qitem.TextbookFee - bdCommission; decimal orderYj = qitem.PreferPrice - qitem.DiscountMoney - qitem.PlatformTax - qitem.TextbookFee - bdCommission;
if (qitem.HelpEnterId > 0) { orderYj = orderYj / 2; } //if (qitem.HelpEnterId > 0) { orderYj = orderYj / 2; }
AchEmpList.Add(new RB_Sell_Achievements_Emp_ViewModel() AchEmpList.Add(new RB_Sell_Achievements_Emp_ViewModel()
{ {
EmpId = qitem.EnterID, EmpId = qitem.EnterID,
...@@ -1191,8 +1192,8 @@ namespace Edu.Module.Course ...@@ -1191,8 +1192,8 @@ namespace Edu.Module.Course
PeopleNumMoney = qitem.Refund <= 0 ? awardModel?.Rate ?? 0 : 0, PeopleNumMoney = qitem.Refund <= 0 ? awardModel?.Rate ?? 0 : 0,
Type = 1, Type = 1,
IsCommonDept = item.IsDeptAward, IsCommonDept = item.IsDeptAward,
Remark = "当月业绩:" + TotalYj + (TRefund != 0 ? "(其中退费:" + TRefund + ")" : "") + ";订单b2b返佣:" + bdCommission + ";订单业绩:" + orderYj + (qitem.HelpEnterId > 0 ? ";此单由试听转化,销售额减半计算" : "") + ";当月部门人头:" + PeopleNum + "人,人头奖励:" + (awardModel?.Rate ?? 0)+",业绩不达标,只发放人头奖励" Remark = "当月业绩:" + TotalYj + (TRefund != 0 ? "(其中退费:" + TRefund + ")" : "") + ";订单b2b返佣:" + bdCommission + ";订单业绩:" + orderYj + ";当月部门人头:" + PeopleNum + "人,人头奖励:" + (awardModel?.Rate ?? 0)+",业绩不达标,只发放人头奖励"
}); });//+ (qitem.HelpEnterId > 0 ? ";此单由试听转化,销售额减半计算" : "")
} }
} }
} }
...@@ -1721,7 +1722,7 @@ namespace Edu.Module.Course ...@@ -1721,7 +1722,7 @@ namespace Edu.Module.Course
#region 计算课时 #region 计算课时
var g3list = glist.Where(x => x.OrderId == item.OrderId).ToList(); var g3list = glist.Where(x => x.OrderId == item.OrderId).ToList();
//查询这几个学生累计课时 //查询这几个学生累计课时
decimal TotalLearn = CheckList.Where(x => x.OrderId == item.OrderId && x.MonthDate <= Convert.ToDateTime(EDate)).Sum(x => x.CurrentDeductionHours);//累计消费课时 (要查询当前发放提成日期) ld 07-02调整 decimal TotalLearn = CheckList.Where(x => x.OrderId == item.OrderId).Sum(x => x.CurrentDeductionHours);//累计消费课时 (要查询当前发放提成日期) ld 07-02调整
decimal TotalHours = g3list.Sum(x => x.TotalHours);// 直接根据学生表 总课时计算 (必须签到课时 = 总课时 才发完最后一个月的) decimal TotalHours = g3list.Sum(x => x.TotalHours);// 直接根据学生表 总课时计算 (必须签到课时 = 总课时 才发完最后一个月的)
#endregion #endregion
......
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