Commit 1f1aa9fb authored by 黄奎's avatar 黄奎

页面修改

parent 043e0a73
......@@ -1133,12 +1133,71 @@ namespace Edu.Module.Customer
/// <returns></returns>
public object MarketChannelStaticModule(string StartTime, string EndTime)
{
List<object> list = new List<object>();
var channelList = channelRepository.GetChannelListRepository(new RB_Channel_Extend() { });
var dataList = studentRepository.GetStudentChannelStaticRepository(new RB_Student_ViewModel()
{
StartTime = StartTime,
EndTime = EndTime
});
return null;
if (channelList != null && channelList.Count > 0)
{
foreach (var item in channelList)
{
var channelTempList = dataList?.Where(qitem => qitem.CreateType == StuCreateTypeEnum.EmployeeInput && qitem.StuChannel == item.Id)?.ToList();
list.Add(new
{
ChannelName = item.Name,
ChannelId = item.Id,
ClueCount = channelTempList?.Count(),
VisitCount = channelTempList?.Sum(qitem => qitem.VisitCount),
OrderCount = channelTempList?.Sum(qitem => qitem.OrderCount),
OrderIncome = channelTempList?.Sum(qitem => qitem.OrderIncome)
});
}
}
var customerList = dataList?.Where(qitem => qitem.CreateType == StuCreateTypeEnum.CustomerInput)?.ToList();
list.Add(new
{
ChannelName = "同行介绍",
ChannelId = 10001,
ClueCount = customerList?.Count(),
VisitCount = customerList?.Sum(qitem => qitem.VisitCount),
OrderCount = customerList?.Sum(qitem => qitem.OrderCount),
OrderIncome = customerList?.Sum(qitem => qitem.OrderIncome)
});
var innerList = dataList?.Where(qitem => qitem.CreateType == StuCreateTypeEnum.InternalIntroduction)?.ToList();
list.Add(new
{
ChannelName = "内部介绍",
ChannelId = 10002,
ClueCount = innerList?.Count(),
VisitCount = innerList?.Sum(qitem => qitem.VisitCount),
OrderCount = innerList?.Sum(qitem => qitem.OrderCount),
OrderIncome = innerList?.Sum(qitem => qitem.OrderIncome)
});
var transList = dataList?.Where(qitem => qitem.CreateType == StuCreateTypeEnum.TransIntroduction)?.ToList();
list.Add(new
{
ChannelName = "学员转介绍",
ChannelId = 10003,
ClueCount = transList?.Count(),
VisitCount = transList?.Sum(qitem => qitem.VisitCount),
OrderCount = transList?.Sum(qitem => qitem.OrderCount),
OrderIncome = transList?.Sum(qitem => qitem.OrderIncome)
});
list.Add(new
{
ChannelName = "合计",
ChannelId = 10005,
ClueCount = dataList?.Count(),
VisitCount = dataList?.Sum(qitem => qitem.VisitCount),
OrderCount = dataList?.Sum(qitem => qitem.OrderCount),
OrderIncome = dataList?.Sum(qitem => qitem.OrderIncome)
});
return list;
}
#endregion
......
......@@ -73,6 +73,10 @@ namespace Edu.Module.User
/// <returns></returns>
public RB_Group_ViewModel GetGroupEntityModule(string workDomainUrl)
{
if (workDomainUrl.ToLower() == "edu.oytour.com")
{
workDomainUrl = "m.kookaku.com";
}
return GetGroupListModule(new RB_Group_ViewModel() { WorkAppDomain=workDomainUrl })?.FirstOrDefault() ?? new RB_Group_ViewModel();
}
......
......@@ -2833,7 +2833,7 @@ namespace Edu.WebApi.Controllers.User
/// <returns></returns>
[HttpPost]
[AllowRepeatAttribute]
public ApiResult MarketChannelStatic1()
public ApiResult MarketChannelStatic()
{
string startTime = base.ParmJObj.GetStringValue("startTime");
if (string.IsNullOrEmpty(startTime))
......
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