Commit ffcba34f authored by liudong1993's avatar liudong1993

Merge branch 'master' of http://gitlab.oytour.com/Kui2/education

parents 5243a577 209ed13d
...@@ -45,5 +45,11 @@ namespace Edu.Common.Enum.StudyAbroad ...@@ -45,5 +45,11 @@ namespace Edu.Common.Enum.StudyAbroad
/// </summary> /// </summary>
[EnumField("日本初高中常规产品")] [EnumField("日本初高中常规产品")]
RBCGZCGCP = 7, RBCGZCGCP = 7,
/// <summary>
/// 日本初高中常规产品
/// </summary>
[EnumField("日本语言学校项目")]
RBYYXXXM =8,
} }
} }
...@@ -166,6 +166,22 @@ namespace Edu.Model.CacheModel ...@@ -166,6 +166,22 @@ namespace Edu.Model.CacheModel
/// <summary> /// <summary>
/// 客服Token /// 客服Token
/// </summary> /// </summary>
public object TenCccToken { get; set; } public TenCccTokenItem TenCccToken { get; set; }
}
/// <summary>
/// 腾讯客户Token
/// </summary>
public class TenCccTokenItem
{
/// <summary>
/// SDKURL
/// </summary>
public string SdkURL { get; set; }
/// <summary>
/// Token
/// </summary>
public string Token { get; set; }
} }
} }
\ No newline at end of file
...@@ -211,5 +211,10 @@ namespace Edu.Model.Entity.User ...@@ -211,5 +211,10 @@ namespace Edu.Model.Entity.User
/// 客户需求 /// 客户需求
/// </summary> /// </summary>
public int StuNeeds { get; set; } public int StuNeeds { get; set; }
/// <summary>
/// 学员真实电话号码
/// </summary>
public string StuRealMobile { get; set; }
} }
} }
...@@ -164,5 +164,15 @@ namespace Edu.Model.ViewModel.Sell ...@@ -164,5 +164,15 @@ namespace Edu.Model.ViewModel.Sell
/// 课程等级 /// 课程等级
/// </summary> /// </summary>
public CourseRateEnum CourseRate { get; set; } public CourseRateEnum CourseRate { get; set; }
/// <summary>
/// 学员手机号码【显示135****6755】
/// </summary>
public string StuTel { get; set; }
/// <summary>
/// 学员真实手机号码【13551126755】
/// </summary>
public string StuRealMobile { get; set; }
} }
} }
...@@ -289,5 +289,15 @@ namespace Edu.Model.ViewModel.Sell ...@@ -289,5 +289,15 @@ namespace Edu.Model.ViewModel.Sell
/// 用户头像 /// 用户头像
/// </summary> /// </summary>
public string UserIcon { get; set; } public string UserIcon { get; set; }
/// <summary>
/// 学员手机号码【显示135****6755】
/// </summary>
public string StuTel { get; set; }
/// <summary>
/// 学员真实手机号码【13551126755】
/// </summary>
public string StuRealMobile { get; set; }
} }
} }
\ No newline at end of file
...@@ -1826,7 +1826,7 @@ namespace Edu.Module.Course ...@@ -1826,7 +1826,7 @@ namespace Edu.Module.Course
item.GuestName, item.GuestName,
item.Age, item.Age,
CreateTimeStr = Common.ConvertHelper.FormatTime(item.CreateTime), CreateTimeStr = Common.ConvertHelper.FormatTime(item.CreateTime),
item.Mobile, Mobile=item.StuTel,
item.OrderId, item.OrderId,
EnterName = UserReidsCache.GetUserLoginInfo(item.EnterID)?.AccountName ?? "", EnterName = UserReidsCache.GetUserLoginInfo(item.EnterID)?.AccountName ?? "",
item.ContractTotalHours, item.ContractTotalHours,
......
...@@ -429,7 +429,7 @@ namespace Edu.Module.Course ...@@ -429,7 +429,7 @@ namespace Edu.Module.Course
Profession = item?.StuProfession ?? "", Profession = item?.StuProfession ?? "",
Sex = (item?.StuSex ?? 1) + 1, Sex = (item?.StuSex ?? 1) + 1,
Age = item.StuBirth.HasValue ? DateTime.Now.Year - item.StuBirth.Value.Year : 18, Age = item.StuBirth.HasValue ? DateTime.Now.Year - item.StuBirth.Value.Year : 18,
Mobile = item?.StuTel ?? "", Mobile = item?.StuRealMobile ?? "",
Basics = "", Basics = "",
Education = item?.StuEducation ?? GuestEducationEnum.N2, Education = item?.StuEducation ?? GuestEducationEnum.N2,
GuestSource = orderModel.OrderSource, GuestSource = orderModel.OrderSource,
......
...@@ -1765,7 +1765,7 @@ namespace Edu.Module.Course ...@@ -1765,7 +1765,7 @@ namespace Edu.Module.Course
string orderIds = string.Join(",", orderList.Select(x => x.OrderId)); string orderIds = string.Join(",", orderList.Select(x => x.OrderId));
var bdList = customer_BalanceDetailRepository.GetCustomerBalanceDetailListRepository(new Model.ViewModel.Customer.RB_Customer_BalanceDetail_ViewModel() { Group_Id = userInfo.Group_Id, QOrderIds = orderIds }); var bdList = customer_BalanceDetailRepository.GetCustomerBalanceDetailListRepository(new Model.ViewModel.Customer.RB_Customer_BalanceDetail_ViewModel() { Group_Id = userInfo.Group_Id, QOrderIds = orderIds });
if (RuleModel.Type == 3) if (RuleModel!=null&&RuleModel.Type == 3)
{ {
//当前匹配教师规则 只查询老师的业绩 //当前匹配教师规则 只查询老师的业绩
foreach (var item in rulelist.Where(x => x.Id == RuleModel.Id)) foreach (var item in rulelist.Where(x => x.Id == RuleModel.Id))
...@@ -1879,7 +1879,7 @@ namespace Edu.Module.Course ...@@ -1879,7 +1879,7 @@ namespace Edu.Module.Course
} }
} }
//再查询当前用户的 //再查询当前用户的
foreach (var item in rulelist.Where(x => x.Id == RuleModel.Id)) foreach (var item in rulelist.Where(x => x.Id == (RuleModel?.Id??0)))
{ {
if (string.IsNullOrEmpty(item.ChildEmpIds)) if (string.IsNullOrEmpty(item.ChildEmpIds))
{ {
......
...@@ -775,5 +775,18 @@ namespace Edu.Module.User ...@@ -775,5 +775,18 @@ namespace Edu.Module.User
} }
#endregion #endregion
public void UpdateTel()
{
var list= studentRepository.GetStudentListRepository(new RB_Student_ViewModel());
foreach (var item in list)
{
Dictionary<string, object> fileds = new Dictionary<string, object>()
{
{nameof(RB_Student_ViewModel.StuTel),Common.Plugin.StringHelper.ReplaceMobile(item.StuTel) }
};
studentRepository.Update(fileds, new WhereHelper(nameof(RB_Student_ViewModel.StuId), item.StuId));
}
}
} }
} }
...@@ -40,6 +40,11 @@ WHERE 1=1 ...@@ -40,6 +40,11 @@ WHERE 1=1
{ {
builder.AppendFormat(" AND A.{0}={1} ", nameof(RB_Student_Appointment_Extend.StuId), query.StuId); builder.AppendFormat(" AND A.{0}={1} ", nameof(RB_Student_Appointment_Extend.StuId), query.StuId);
} }
if (query.Id > 0)
{
builder.AppendFormat(" AND A.{0}={1} ", nameof(RB_Student_Appointment_Extend.Id), query.Id);
}
} }
builder.AppendFormat(" ORDER BY A.{0} DESC ", nameof(RB_Student_Appointment_Extend.Id)); builder.AppendFormat(" ORDER BY A.{0} DESC ", nameof(RB_Student_Appointment_Extend.Id));
......
...@@ -40,6 +40,10 @@ WHERE 1=1 ...@@ -40,6 +40,10 @@ WHERE 1=1
{ {
builder.AppendFormat(" AND A.{0}={1} ", nameof(RB_Student_Visit_Extend.StuId), query.StuId); builder.AppendFormat(" AND A.{0}={1} ", nameof(RB_Student_Visit_Extend.StuId), query.StuId);
} }
if (query.Id > 0)
{
builder.AppendFormat(" AND A.{0}={1} ", nameof(RB_Student_Visit_Extend.Id), query.Id);
}
} }
builder.AppendFormat(" ORDER BY A.{0} DESC ", nameof(RB_Student_Visit_Extend.Id)); builder.AppendFormat(" ORDER BY A.{0} DESC ", nameof(RB_Student_Visit_Extend.Id));
return GetPage<RB_Student_Visit_Extend>(pageIndex, pageSize, out rowsCount, builder.ToString()).ToList(); return GetPage<RB_Student_Visit_Extend>(pageIndex, pageSize, out rowsCount, builder.ToString()).ToList();
......
...@@ -134,7 +134,7 @@ namespace Edu.Repository.Sell ...@@ -134,7 +134,7 @@ namespace Edu.Repository.Sell
SELECT sog.Student_Id as StudentId,A.*,cs.ClassName,cs.Teacher_Id,cs.ClassNo,IFNULL(B.JoinType,0) AS JoinType,IFNULL(B.TargetJoinType,0) AS TargetJoinType,IFNULL(B.StartClassHours,0) AS StartClassHours SELECT sog.Student_Id as StudentId,A.*,cs.ClassName,cs.Teacher_Id,cs.ClassNo,IFNULL(B.JoinType,0) AS JoinType,IFNULL(B.TargetJoinType,0) AS TargetJoinType,IFNULL(B.StartClassHours,0) AS StartClassHours
,IFNULL(C.CourseName,'') AS CourseName,B.EffectStatus,B.EffectTime,B.UpOrderId,B.OrderType,B.CourseId,B.IsRenewOrder,B.RenewOrderId,B.EnterID ,IFNULL(C.CourseName,'') AS CourseName,B.EffectStatus,B.EffectTime,B.UpOrderId,B.OrderType,B.CourseId,B.IsRenewOrder,B.RenewOrderId,B.EnterID
,sc.StopClassEffectTime,B.SourceOrderId,B.TargetOrderId,IFNULL(D.FirstClassHours,0)+IFNULL(D.SecondClassHours,0)+IFNULL(D.ThirdClassHours,0) AS ContractTotalHours ,sc.StopClassEffectTime,B.SourceOrderId,B.TargetOrderId,IFNULL(D.FirstClassHours,0)+IFNULL(D.SecondClassHours,0)+IFNULL(D.ThirdClassHours,0) AS ContractTotalHours
,IFNULL(stu.StuIcon,'') AS UserIcon ,IFNULL(stu.StuIcon,'') AS UserIcon,stu.StuTel,stu.StuRealMobile
FROM RB_Order_Guest AS A LEFT JOIN rb_order AS B ON A.OrderId=B.OrderId FROM RB_Order_Guest AS A LEFT JOIN rb_order AS B ON A.OrderId=B.OrderId
LEFT JOIN rb_class AS cs ON B.ClassId=cs.ClassId LEFT JOIN rb_class AS cs ON B.ClassId=cs.ClassId
LEFT JOIN rb_student_orderguest as sog on sog.GuestId=a.Id LEFT JOIN rb_student_orderguest as sog on sog.GuestId=a.Id
...@@ -163,9 +163,12 @@ WHERE 1=1 and A.Status=0 AND B.OrderState<>3 {where}"; ...@@ -163,9 +163,12 @@ WHERE 1=1 and A.Status=0 AND B.OrderState<>3 {where}";
SELECT A.*,IFNULL(course.CourseName,'') AS CourseName,tOrder.CourseId,tOrder.OrderType,tOrder.StartClassHours SELECT A.*,IFNULL(course.CourseName,'') AS CourseName,tOrder.CourseId,tOrder.OrderType,tOrder.StartClassHours
,IFNULL(tOrder.JoinType,0) AS JoinType,IFNULL(tOrder.TargetJoinType,0) AS TargetJoinType,tOrder.EffectTime ,IFNULL(tOrder.JoinType,0) AS JoinType,IFNULL(tOrder.TargetJoinType,0) AS TargetJoinType,tOrder.EffectTime
,tOrder.EffectStatus,tOrder.UpOrderId,sc.StopClassEffectTime,tOrder.SourceOrderId,tOrder.TargetOrderId ,tOrder.EffectStatus,tOrder.UpOrderId,sc.StopClassEffectTime,tOrder.SourceOrderId,tOrder.TargetOrderId
,st.StuTel,st.StuRealMobile
FROM RB_Order_Guest AS A LEFT JOIN RB_Order as tOrder ON A.OrderId=tOrder.OrderId FROM RB_Order_Guest AS A LEFT JOIN RB_Order as tOrder ON A.OrderId=tOrder.OrderId
LEFT JOIN rb_course AS course ON (tOrder.CourseId=course.CourseId AND tOrder.CourseId>0 AND tOrder.OrderType=1) LEFT JOIN rb_course AS course ON (tOrder.CourseId=course.CourseId AND tOrder.CourseId>0 AND tOrder.OrderType=1)
LEFT JOIN (SELECT OrderGuestId,MAX(TakeEffectTime) as StopClassEffectTime from rb_student_stopclass where IsAuditThrough=1 GROUP BY OrderGuestId) as sc on sc.OrderGuestId=a.Id LEFT JOIN rb_student_orderguest AS og ON (A.Id=og.GuestId AND A.OrderId=og.OrderId)
LEFT JOIN rb_student as st ON og.Student_Id=st.StuId
LEFT JOIN (SELECT OrderGuestId,MAX(TakeEffectTime) as StopClassEffectTime from rb_student_stopclass where IsAuditThrough=1 GROUP BY OrderGuestId) as sc on sc.OrderGuestId=a.Id
WHERE 1=1 AND A.Status=0 WHERE 1=1 AND A.Status=0
"); ");
if (demodel.Group_Id > 0) if (demodel.Group_Id > 0)
...@@ -342,13 +345,15 @@ WHERE {where}"; ...@@ -342,13 +345,15 @@ WHERE {where}";
builder.AppendFormat(@" builder.AppendFormat(@"
SELECT A.*,IFNULL(B.JoinType,0) AS JoinType,IFNULL(B.TargetJoinType,0) AS TargetJoinType,IFNULL(B.StartClassHours,0) AS StartClassHours,IFNULL(C.CourseName,'') AS CourseName SELECT A.*,IFNULL(B.JoinType,0) AS JoinType,IFNULL(B.TargetJoinType,0) AS TargetJoinType,IFNULL(B.StartClassHours,0) AS StartClassHours,IFNULL(C.CourseName,'') AS CourseName
,class.ClassName,b.EnterID,plan.TotalPlanNum,planr.Ranks ,B.EffectStatus,B.EffectTime,B.UpOrderId,B.OrderType,B.CourseId,B.IsRenewOrder,B.RenewOrderId ,class.ClassName,b.EnterID,plan.TotalPlanNum,planr.Ranks ,B.EffectStatus,B.EffectTime,B.UpOrderId,B.OrderType,B.CourseId,B.IsRenewOrder,B.RenewOrderId
,sc.StopClassEffectTime,B.SourceOrderId,B.TargetOrderId ,sc.StopClassEffectTime,B.SourceOrderId,B.TargetOrderId,stu.StuTel,stu.StuRealMobile
FROM RB_Order_Guest AS A LEFT JOIN rb_order AS B ON A.OrderId=B.OrderId FROM RB_Order_Guest AS A LEFT JOIN rb_order AS B ON A.OrderId=B.OrderId
LEFT JOIN rb_class as class on class.ClassId=a.ClassId LEFT JOIN rb_class as class on class.ClassId=a.ClassId
LEFT JOIN rb_student_orderguest as sog on sog.GuestId=a.Id
LEFT JOIN rb_student AS stu ON sog.Student_Id=stu.StuId
LEFT JOIN rb_course AS C ON (B.CourseId=C.CourseId AND B.CourseId>0 AND B.OrderType=1) LEFT JOIN rb_course AS C ON (B.CourseId=C.CourseId AND B.CourseId>0 AND B.OrderType=1)
LEFT JOIN (SELECT ClassId,COUNT(*) TotalPlanNum from rb_class_plan where `Status`=0 GROUP BY ClassId) as plan on plan.ClassId=class.ClassId LEFT JOIN (SELECT ClassId,COUNT(*) TotalPlanNum from rb_class_plan where `Status`=0 GROUP BY ClassId) as plan on plan.ClassId=class.ClassId
LEFT JOIN (SELECT ClassId,COUNT(*) Ranks from rb_class_plan where `Status`=0 and DATE_FORMAT(ClassDate,'%Y-%m-%d') <=DATE_FORMAT(NOW(),'%Y-%m-%d') GROUP BY ClassId) as planr on planr.ClassId=class.ClassId LEFT JOIN (SELECT ClassId,COUNT(*) Ranks from rb_class_plan where `Status`=0 and DATE_FORMAT(ClassDate,'%Y-%m-%d') <=DATE_FORMAT(NOW(),'%Y-%m-%d') GROUP BY ClassId) as planr on planr.ClassId=class.ClassId
LEFT JOIN (SELECT OrderGuestId,MAX(TakeEffectTime) as StopClassEffectTime from rb_student_stopclass where IsAuditThrough=1 GROUP BY OrderGuestId) as sc on sc.OrderGuestId=a.Id LEFT JOIN (SELECT OrderGuestId,MAX(TakeEffectTime) as StopClassEffectTime from rb_student_stopclass where IsAuditThrough=1 GROUP BY OrderGuestId) as sc on sc.OrderGuestId=a.Id
WHERE 1=1 and A.Status=0 and class.Status=0 and b.OrderState<>3 WHERE 1=1 and A.Status=0 and class.Status=0 and b.OrderState<>3
"); ");
if (demodel.Group_Id > 0) if (demodel.Group_Id > 0)
...@@ -682,10 +687,11 @@ WHERE {where}"; ...@@ -682,10 +687,11 @@ WHERE {where}";
builder.AppendFormat(@" builder.AppendFormat(@"
SELECT a.*,contract.ContractNo,contract.Id as ContractId,b.CourseId,IFNULL(C.CourseName,'') AS CourseName,C.CourseRate,class.ClassName,class.ClassNo SELECT a.*,contract.ContractNo,contract.Id as ContractId,b.CourseId,IFNULL(C.CourseName,'') AS CourseName,C.CourseRate,class.ClassName,class.ClassNo
,class.Teacher_Id,teacher.TeacherName,b.CreateTime as OrderTime,b.EnterID,b.PreferPrice,b.Income,b.Refund,b.PlatformTax ,class.Teacher_Id,teacher.TeacherName,b.CreateTime as OrderTime,b.EnterID,b.PreferPrice,b.Income,b.Refund,b.PlatformTax
,(a.TotalHours-a.CompleteHours) as SurplusHours,gc.AbsenceNum,gc.LeaveNum,eventlog.EventlogNum,b.EffectStatus,b.JoinType,sog.Student_Id ,(a.TotalHours-a.CompleteHours) as SurplusHours,gc.AbsenceNum,gc.LeaveNum,eventlog.EventlogNum,b.EffectStatus,b.JoinType,sog.Student_Id,st.StuTel,st.StuRealMobile
FROM RB_Order_Guest AS A LEFT JOIN rb_order AS B ON A.OrderId=B.OrderId FROM RB_Order_Guest AS A LEFT JOIN rb_order AS B ON A.OrderId=B.OrderId
LEFT JOIN rb_education_contract as contract on contract.GuestId=a.Id AND contract.`Status`=0 LEFT JOIN rb_education_contract as contract on contract.GuestId=a.Id AND contract.`Status`=0
LEFT JOIN rb_student_orderguest as sog on sog.GuestId=a.Id AND sog.`Status`=0 LEFT JOIN rb_student_orderguest as sog on sog.GuestId=a.Id AND sog.`Status`=0
LEFT JOIN rb_student as st ON sog.Student_Id=st.StuId
LEFT JOIN rb_class as class on class.ClassId=b.ClassId LEFT JOIN rb_class as class on class.ClassId=b.ClassId
LEFT JOIN rb_course AS C ON (B.CourseId=C.CourseId AND B.CourseId>0 AND B.OrderType=1) LEFT JOIN rb_course AS C ON (B.CourseId=C.CourseId AND B.CourseId>0 AND B.OrderType=1)
LEFT JOIN rb_teacher as teacher on teacher.TId=class.Teacher_Id LEFT JOIN rb_teacher as teacher on teacher.TId=class.Teacher_Id
......
...@@ -58,6 +58,14 @@ WHERE 1=1 ...@@ -58,6 +58,14 @@ WHERE 1=1
{ {
builder.AppendFormat(" AND A.{0}={1}", nameof(RB_StudyAbroad_ViewModel.SaleState),(int)query.SaleState); builder.AppendFormat(" AND A.{0}={1}", nameof(RB_StudyAbroad_ViewModel.SaleState),(int)query.SaleState);
} }
if (query.ProductType > 0)
{
builder.AppendFormat(" AND A.{0}={1}", nameof(RB_StudyAbroad_ViewModel.ProductType), (int)query.ProductType);
}
if (query.StudyCountryId > 0)
{
builder.AppendFormat(" AND A.{0}={1}", nameof(RB_StudyAbroad_ViewModel.StudyCountryId), query.StudyCountryId);
}
return GetPage<RB_StudyAbroad_ViewModel>(pageIndex, pageSize, out rowsCount, builder.ToString(), parameters).ToList(); return GetPage<RB_StudyAbroad_ViewModel>(pageIndex, pageSize, out rowsCount, builder.ToString(), parameters).ToList();
} }
} }
......
...@@ -363,6 +363,7 @@ WHERE o.OrderState=1 and og.`Status`=0 and sog.`Status`=0 and og.GuestState <>2 ...@@ -363,6 +363,7 @@ WHERE o.OrderState=1 and og.`Status`=0 and sog.`Status`=0 and og.GuestState <>2
{ {
model.StuSourceId = 0; model.StuSourceId = 0;
} }
model.StuTel = Common.Plugin.StringHelper.ReplaceMobile(model.StuRealMobile);
if (model.StuId > 0) if (model.StuId > 0)
{ {
logTitle = "修改客户"; logTitle = "修改客户";
...@@ -497,6 +498,7 @@ WHERE o.OrderState=1 and og.`Status`=0 and sog.`Status`=0 and og.GuestState <>2 ...@@ -497,6 +498,7 @@ WHERE o.OrderState=1 and og.`Status`=0 and sog.`Status`=0 and og.GuestState <>2
{nameof(RB_Student_ViewModel.QQ),model.QQ}, {nameof(RB_Student_ViewModel.QQ),model.QQ},
{nameof(RB_Student_ViewModel.WeChatNo),model.WeChatNo}, {nameof(RB_Student_ViewModel.WeChatNo),model.WeChatNo},
{nameof(RB_Student_ViewModel.StuType),model.StuType}, {nameof(RB_Student_ViewModel.StuType),model.StuType},
{nameof(RB_Student_ViewModel.StuRealMobile),model.StuRealMobile},
}; };
//教育后台操作 //教育后台操作
if (model.OperateType == 1) if (model.OperateType == 1)
...@@ -545,13 +547,26 @@ WHERE o.OrderState=1 and og.`Status`=0 and sog.`Status`=0 and og.GuestState <>2 ...@@ -545,13 +547,26 @@ WHERE o.OrderState=1 and og.`Status`=0 and sog.`Status`=0 and og.GuestState <>2
#region 处理学员账号信息 #region 处理学员账号信息
var accountModel= accountRepository.GetAccountListRepository(new RB_Account_ViewModel() { Group_Id = model.Group_Id, AccountType = Common.Enum.User.AccountTypeEnum.Student, AccountId = model.StuId }).FirstOrDefault(); var accountModel= accountRepository.GetAccountListRepository(new RB_Account_ViewModel() { Group_Id = model.Group_Id, AccountType = Common.Enum.User.AccountTypeEnum.Student, AccountId = model.StuId }).FirstOrDefault();
string account = "";
if (!string.IsNullOrEmpty(model.WeChatNo))
{
account = model.WeChatNo;
}
if (!string.IsNullOrEmpty(model.QQ))
{
account = model.QQ;
}
if (!string.IsNullOrEmpty(model.StuRealMobile))
{
account = model.StuRealMobile;
}
if (accountModel == null) if (accountModel == null)
{ {
//创建学生账号 //创建学生账号
model.Account_Id = accountRepository.Insert(new RB_Account() model.Account_Id = accountRepository.Insert(new RB_Account()
{ {
Id = 0, Id = 0,
Account = model.StuTel, Account = account,
AccountId = model.StuId, AccountId = model.StuId,
AccountType = Common.Enum.User.AccountTypeEnum.Student, AccountType = Common.Enum.User.AccountTypeEnum.Student,
AnnualLeaveDay = 0, AnnualLeaveDay = 0,
...@@ -567,11 +582,11 @@ WHERE o.OrderState=1 and og.`Status`=0 and sog.`Status`=0 and og.GuestState <>2 ...@@ -567,11 +582,11 @@ WHERE o.OrderState=1 and og.`Status`=0 and sog.`Status`=0 and og.GuestState <>2
} }
else else
{ {
if (model.StuTel != accountModel.Account) if (account != accountModel.Account)
{ {
Dictionary<string, object> accountFileds = new Dictionary<string, object>() Dictionary<string, object> accountFileds = new Dictionary<string, object>()
{ {
{nameof(RB_Account.Account),model.StuTel} {nameof(RB_Account.Account),account}
}; };
accountRepository.Update(accountFileds, new WhereHelper(nameof(RB_Account.Id), accountModel.Id)); accountRepository.Update(accountFileds, new WhereHelper(nameof(RB_Account.Id), accountModel.Id));
} }
...@@ -740,6 +755,11 @@ WHERE 1=1 ...@@ -740,6 +755,11 @@ WHERE 1=1
builder.AppendFormat(" AND t.{0}=@StuTel ", nameof(RB_Student_ViewModel.StuTel)); builder.AppendFormat(" AND t.{0}=@StuTel ", nameof(RB_Student_ViewModel.StuTel));
parameters.Add("StuTel", query.StuTel.Trim()); parameters.Add("StuTel", query.StuTel.Trim());
} }
if (!string.IsNullOrWhiteSpace(query.StuRealMobile))
{
builder.AppendFormat(" AND t.{0}=@StuRealMobile ", nameof(RB_Student_ViewModel.StuRealMobile));
parameters.Add("StuRealMobile", query.StuRealMobile.Trim());
}
if (!string.IsNullOrWhiteSpace(query.QQ)) if (!string.IsNullOrWhiteSpace(query.QQ))
{ {
builder.AppendFormat(" AND t.{0}=@QQ ", nameof(RB_Student_ViewModel.QQ)); builder.AppendFormat(" AND t.{0}=@QQ ", nameof(RB_Student_ViewModel.QQ));
......
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
// 运行时版本:4.0.30319.42000
//
// 对此文件的更改可能会导致不正确的行为,并且如果
// 重新生成代码,这些更改将会丢失。
// </auto-generated>
//------------------------------------------------------------------------------
using System;
using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("Edu.Repository")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")]
[assembly: System.Reflection.AssemblyProductAttribute("Edu.Repository")]
[assembly: System.Reflection.AssemblyTitleAttribute("Edu.Repository")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
// 由 MSBuild WriteCodeFragment 类生成。
...@@ -1128,7 +1128,7 @@ namespace Edu.WebApi.Controllers.Course ...@@ -1128,7 +1128,7 @@ namespace Edu.WebApi.Controllers.Course
SexStr = x.Sex == 1 ? "男" : "女", SexStr = x.Sex == 1 ? "男" : "女",
x.Age, x.Age,
BirthDate = Common.ConvertHelper.FormatDate(x.BirthDate), BirthDate = Common.ConvertHelper.FormatDate(x.BirthDate),
x.Mobile, Mobile=x.StuTel,
x.Basics, x.Basics,
x.Education, x.Education,
EducationName = x.Education.ToName(), EducationName = x.Education.ToName(),
......
...@@ -349,7 +349,7 @@ namespace Edu.WebApi.Controllers.Course ...@@ -349,7 +349,7 @@ namespace Edu.WebApi.Controllers.Course
{ {
item.Id, item.Id,
item.GuestName, item.GuestName,
item.Mobile, Mobile=item.StuTel,
item.ContractId, item.ContractId,
item.ContractNo, item.ContractNo,
item.ClassId, item.ClassId,
...@@ -359,7 +359,7 @@ namespace Edu.WebApi.Controllers.Course ...@@ -359,7 +359,7 @@ namespace Edu.WebApi.Controllers.Course
item.Teacher_Id, item.Teacher_Id,
item.TeacherName, item.TeacherName,
item.OrderId, item.OrderId,
OrderTime = item.OrderTime.HasValue ? item.OrderTime.Value.ToString("yyyy-MM-dd HH:mm:ss") : "", OrderTime =Common.ConvertHelper.FormatTime(item.OrderTime),
item.EnterID, item.EnterID,
item.EnterName, item.EnterName,
item.PreferPrice, item.PreferPrice,
......
...@@ -246,7 +246,7 @@ namespace Edu.WebApi.Controllers.Course ...@@ -246,7 +246,7 @@ namespace Edu.WebApi.Controllers.Course
{ {
item.Id, item.Id,
item.GuestName, item.GuestName,
item.Mobile, Mobile=item.StuTel,
item.ClassId, item.ClassId,
item.ClassName, item.ClassName,
item.CourseId, item.CourseId,
......
...@@ -40,6 +40,7 @@ namespace Edu.WebApi.Controllers.Customer ...@@ -40,6 +40,7 @@ namespace Edu.WebApi.Controllers.Customer
var query = new RB_Student_Appointment_Extend() var query = new RB_Student_Appointment_Extend()
{ {
StuId = base.ParmJObj.GetInt("StuId"), StuId = base.ParmJObj.GetInt("StuId"),
Id=base.ParmJObj.GetInt("Id"),
}; };
query.Group_Id = base.UserInfo.Group_Id; query.Group_Id = base.UserInfo.Group_Id;
var data = customerStudentModule.GetStudentAppointmentPageModule(pageModel.PageIndex, pageModel.PageSize, out long rowsCount, query); var data = customerStudentModule.GetStudentAppointmentPageModule(pageModel.PageIndex, pageModel.PageSize, out long rowsCount, query);
...@@ -216,6 +217,7 @@ namespace Edu.WebApi.Controllers.Customer ...@@ -216,6 +217,7 @@ namespace Edu.WebApi.Controllers.Customer
var query = new RB_Student_Visit_Extend() var query = new RB_Student_Visit_Extend()
{ {
StuId = base.ParmJObj.GetInt("StuId"), StuId = base.ParmJObj.GetInt("StuId"),
Id=base.ParmJObj.GetInt("Id"),
}; };
query.Group_Id = base.UserInfo.Group_Id; query.Group_Id = base.UserInfo.Group_Id;
var data = customerStudentModule.GetStudentVisitPageModule(pageModel.PageIndex, pageModel.PageSize, out long rowsCount, query); var data = customerStudentModule.GetStudentVisitPageModule(pageModel.PageIndex, pageModel.PageSize, out long rowsCount, query);
......
...@@ -223,6 +223,8 @@ namespace Edu.WebApi.Controllers.StudyAbroad ...@@ -223,6 +223,8 @@ namespace Edu.WebApi.Controllers.StudyAbroad
AuditType=base.ParmJObj.GetInt("AuditType"), AuditType=base.ParmJObj.GetInt("AuditType"),
SaleState=(SaleStateEnum)base.ParmJObj.GetInt("SaleState"), SaleState=(SaleStateEnum)base.ParmJObj.GetInt("SaleState"),
AuditState=base.ParmJObj.GetInt("AuditState"), AuditState=base.ParmJObj.GetInt("AuditState"),
ProductType=(StudyAbroadProductTypeEnum)base.ParmJObj.GetInt("ProductType"),
StudyCountryId=base.ParmJObj.GetInt("StudyCountryId"),
}; };
query.Group_Id = base.UserInfo.Group_Id; query.Group_Id = base.UserInfo.Group_Id;
List<object> result = new List<object>(); List<object> result = new List<object>();
......
...@@ -53,11 +53,14 @@ namespace Edu.WebApi.Controllers.User ...@@ -53,11 +53,14 @@ namespace Edu.WebApi.Controllers.User
private readonly EmployeeBonusModule employeeBonusModule = new EmployeeBonusModule(); private readonly EmployeeBonusModule employeeBonusModule = new EmployeeBonusModule();
private readonly StudentModule studentModule = new StudentModule();
[HttpGet] [HttpGet]
[HttpPost] [HttpPost]
[AllowAnonymous] [AllowAnonymous]
public ApiResult Test() public ApiResult Test()
{ {
studentModule.UpdateTel();
return ApiResult.Success(); return ApiResult.Success();
} }
...@@ -239,7 +242,13 @@ namespace Edu.WebApi.Controllers.User ...@@ -239,7 +242,13 @@ namespace Edu.WebApi.Controllers.User
}; };
if (model.IsTenCccUser == 1) if (model.IsTenCccUser == 1)
{ {
obj.TenCccToken = new TenCloudCCCHelper().GetTenCccUserToken(model.Email).Result; var tObj = new TenCloudCCCHelper().GetTenCccUserToken(model.Email).Result;
JObject jsobj = JObject.Parse(tObj.ToString());
obj.TenCccToken = new TenCccTokenItem()
{
SdkURL=jsobj.GetStringValue("SdkURL"),
Token=jsobj.GetStringValue("Token")
};
} }
UserReidsCache.UserInfoSet(Cache.CacheKey.User_Login_Key + model.Id, obj, Common.Config.JwtExpirTime); UserReidsCache.UserInfoSet(Cache.CacheKey.User_Login_Key + model.Id, obj, Common.Config.JwtExpirTime);
return ApiResult.Success(data: obj); return ApiResult.Success(data: obj);
......
...@@ -757,6 +757,7 @@ namespace Edu.WebApi.Controllers.User ...@@ -757,6 +757,7 @@ namespace Edu.WebApi.Controllers.User
item.StuTypeName, item.StuTypeName,
item.StuNeeds, item.StuNeeds,
item.StuNeedsName, item.StuNeedsName,
item.StuRealMobile,
}); });
} }
pageModel.Count = rowsCount; pageModel.Count = rowsCount;
...@@ -832,12 +833,13 @@ namespace Edu.WebApi.Controllers.User ...@@ -832,12 +833,13 @@ namespace Edu.WebApi.Controllers.User
QQ = base.ParmJObj.GetStringValue("QQ"), QQ = base.ParmJObj.GetStringValue("QQ"),
StuType = base.ParmJObj.GetInt("StuType"), StuType = base.ParmJObj.GetInt("StuType"),
StuNeeds=base.ParmJObj.GetInt("StuNeeds"), StuNeeds=base.ParmJObj.GetInt("StuNeeds"),
StuRealMobile=base.ParmJObj.GetStringValue("StuRealMobile"),
}; };
if (string.IsNullOrEmpty(extModel.StuTel) && string.IsNullOrEmpty(extModel.QQ) && string.IsNullOrEmpty(extModel.WeChatNo)) if (string.IsNullOrEmpty(extModel.StuRealMobile) && string.IsNullOrEmpty(extModel.QQ) && string.IsNullOrEmpty(extModel.WeChatNo))
{ {
return ApiResult.Failed("手机号码、QQ号码、微信号码至少填写一项!"); return ApiResult.Failed("手机号码、QQ号码、微信号码至少填写一项!");
} }
if (!string.IsNullOrEmpty(extModel.StuTel) && !Common.Plugin.StringHelper.IsMobilePhone(extModel.StuTel)) if (!string.IsNullOrEmpty(extModel.StuRealMobile) && !Common.Plugin.StringHelper.IsMobilePhone(extModel.StuRealMobile))
{ {
return ApiResult.Failed("手机号码不正确,请重新填写!"); return ApiResult.Failed("手机号码不正确,请重新填写!");
} }
...@@ -896,7 +898,7 @@ namespace Edu.WebApi.Controllers.User ...@@ -896,7 +898,7 @@ namespace Edu.WebApi.Controllers.User
var query = new RB_Student_ViewModel() var query = new RB_Student_ViewModel()
{ {
StuId = base.ParmJObj.GetInt("StuId"), StuId = base.ParmJObj.GetInt("StuId"),
StuTel = base.ParmJObj.GetStringValue("StuTel"), StuRealMobile = base.ParmJObj.GetStringValue("StuRealMobile"),
QQ = base.ParmJObj.GetStringValue("QQ"), QQ = base.ParmJObj.GetStringValue("QQ"),
WeChatNo = base.ParmJObj.GetStringValue("WeChatNo") WeChatNo = base.ParmJObj.GetStringValue("WeChatNo")
}; };
...@@ -914,9 +916,9 @@ namespace Edu.WebApi.Controllers.User ...@@ -914,9 +916,9 @@ namespace Edu.WebApi.Controllers.User
query.Group_Id = base.UserInfo.Group_Id; query.Group_Id = base.UserInfo.Group_Id;
} }
if (!string.IsNullOrEmpty(query.StuTel)) if (!string.IsNullOrEmpty(query.StuRealMobile))
{ {
var model = studentModule.CheckExistsStuModule(new RB_Student_ViewModel() { Group_Id = query.Group_Id, StuTel = query.StuTel }); var model = studentModule.CheckExistsStuModule(new RB_Student_ViewModel() { Group_Id = query.Group_Id, StuRealMobile = query.StuRealMobile });
string name = UserReidsCache.GetUserLoginInfo((model?.CreateBy ?? 0))?.AccountName ?? ""; string name = UserReidsCache.GetUserLoginInfo((model?.CreateBy ?? 0))?.AccountName ?? "";
if (model != null && model.StuId > 0) if (model != null && model.StuId > 0)
{ {
...@@ -1076,6 +1078,7 @@ namespace Edu.WebApi.Controllers.User ...@@ -1076,6 +1078,7 @@ namespace Edu.WebApi.Controllers.User
WeChatNo = base.ParmJObj.GetStringValue("WeChatNo"), WeChatNo = base.ParmJObj.GetStringValue("WeChatNo"),
QQ = base.ParmJObj.GetStringValue("QQ"), QQ = base.ParmJObj.GetStringValue("QQ"),
StuType = base.ParmJObj.GetInt("StuType"), StuType = base.ParmJObj.GetInt("StuType"),
StuRealMobile=base.ParmJObj.GetStringValue("StuRealMobile"),
}; };
extModel.CreateType = StuCreateTypeEnum.CustomerInput; extModel.CreateType = StuCreateTypeEnum.CustomerInput;
extModel.Status = DateStateEnum.Normal; extModel.Status = DateStateEnum.Normal;
...@@ -1226,6 +1229,7 @@ namespace Edu.WebApi.Controllers.User ...@@ -1226,6 +1229,7 @@ namespace Edu.WebApi.Controllers.User
extModel.StuTypeName, extModel.StuTypeName,
extModel.StuNeeds, extModel.StuNeeds,
extModel.StuNeedsName, extModel.StuNeedsName,
extModel.StuRealMobile,
}; };
return ApiResult.Success(data: obj); return ApiResult.Success(data: obj);
} }
...@@ -1241,16 +1245,18 @@ namespace Edu.WebApi.Controllers.User ...@@ -1241,16 +1245,18 @@ namespace Edu.WebApi.Controllers.User
var customer = base.AppletCustomerInfo; var customer = base.AppletCustomerInfo;
var query = new RB_Student_ViewModel() var query = new RB_Student_ViewModel()
{ {
StuTel = base.ParmJObj.GetStringValue("StuTel"),
QQ = base.ParmJObj.GetStringValue("QQ"), QQ = base.ParmJObj.GetStringValue("QQ"),
WeChatNo = base.ParmJObj.GetStringValue("WeChatNo") WeChatNo = base.ParmJObj.GetStringValue("WeChatNo")
}; };
if (customer != null && customer.GroupId > 0) if (customer != null && customer.GroupId > 0)
{ {
query.StuRealMobile = base.ParmJObj.GetStringValue("StuTel");
query.Group_Id = customer.GroupId; query.Group_Id = customer.GroupId;
} }
if (query.Group_Id <= 0) if (query.Group_Id <= 0)
{ {
query.StuRealMobile = base.ParmJObj.GetStringValue("StuRealMobile");
query.Group_Id = base.UserInfo.Group_Id; query.Group_Id = base.UserInfo.Group_Id;
} }
var extModel = studentModule.CheckExistsStuModule(query); var extModel = studentModule.CheckExistsStuModule(query);
......
...@@ -105,7 +105,7 @@ ...@@ -105,7 +105,7 @@
//是否是本地服务 //是否是本地服务
"IsLocal": "1", "IsLocal": "1",
//临时Token //临时Token
"TempToken": "47_oXN2xrKRE9InhFMtcCuFx_8Psl2i9TgCYhdHIsvuii5TweFkXvM1J0miUS1sLiRO5GggPOSQqCL1mfVK_ZR9HzV0JAn12TUKctzrBf2p6cFN0gzSUP88Q-iEA3yNgVkL9-DtNpzPL2stAfD7GTRaAIAANL", "TempToken": "52_qHSqAI2gO0U9vrM7VAHkZ9dK-sR3RlQDGYJsvxypmPut16Hs7CvtoUGp2I3vYfQyehH1nrn1CDscWbBf4gN9-n9g45PAbqau4OTsj19pATUEYIOyAPl4xU_tHX7H2LsErkGYOV9dY7cwOHB-HRRfAAABLL",
//学生请假流程编号 //学生请假流程编号
"StudentLeaveFlowId": 7, "StudentLeaveFlowId": 7,
//组卷审批流程编号 //组卷审批流程编号
......
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