Commit d36429b6 authored by liudong1993's avatar liudong1993

OKR提醒

parent d216690f
...@@ -212,6 +212,17 @@ namespace Edu.Education.Helper ...@@ -212,6 +212,17 @@ namespace Edu.Education.Helper
{ {
LogHelper.Write(ex, "CreateOKRPeriod"); LogHelper.Write(ex, "CreateOKRPeriod");
} }
try
{
LogHelper.Write("开始提醒....");
//OKRPeriodModule oKRPeriodModule = new OKRPeriodModule();
//oKRPeriodModule.SendOKRRemid();
}
catch (Exception ex)
{
LogHelper.Write(ex, "SendOKRRemid");
}
return null; return null;
} }
} }
......
This diff is collapsed.
...@@ -54,6 +54,10 @@ namespace Edu.Repository.OKR ...@@ -54,6 +54,10 @@ namespace Edu.Repository.OKR
{ {
where += $@" and {nameof(RB_OKR_Remind_ViewModel.Type)} ={demodel.Type}"; where += $@" and {nameof(RB_OKR_Remind_ViewModel.Type)} ={demodel.Type}";
} }
if (demodel.Enable > 0)
{
where += $@" and {nameof(RB_OKR_Remind_ViewModel.Enable)} ={demodel.Enable}";
}
string sql = $@" select * from RB_OKR_Remind where {where} order by Id desc"; string sql = $@" select * from RB_OKR_Remind where {where} order by Id desc";
return Get<RB_OKR_Remind_ViewModel>(sql).ToList(); return Get<RB_OKR_Remind_ViewModel>(sql).ToList();
......
...@@ -442,5 +442,30 @@ WHERE 1=1 ...@@ -442,5 +442,30 @@ WHERE 1=1
} }
return Get<RB_Account_ViewModel>(builder.ToString(), parameters).ToList(); return Get<RB_Account_ViewModel>(builder.ToString(), parameters).ToList();
} }
/// <summary>
/// 获取OKR未填写目标的用户
/// </summary>
/// <param name="GroupId"></param>
/// <returns></returns>
public List<RB_Employee_Extend> GetOKRUserNotObjectiveList(int GroupId) {
string sql = $@"SELECT e.* FROM rb_employee e
LEFT JOIN rb_okr_objective o on e.EmployeeId = o.CreateBy AND o.`Status` in(1,2)
WHERE e.RB_Group_id ={GroupId} AND e.IsLeave =0 AND o.Id is null";
return Get<RB_Employee_Extend>(sql).ToList();
}
/// <summary>
/// 获取OKR未打分目标的用户
/// </summary>
/// <param name="GroupId"></param>
/// <returns></returns>
public List<RB_Employee_Extend> GetOKRUserNotScoreList(int GroupId)
{
string sql = $@"SELECT e.* FROM rb_employee e
LEFT JOIN rb_okr_objective o on e.EmployeeId = o.CreateBy AND o.`Status` =2
WHERE e.RB_Group_id ={GroupId} AND e.IsLeave =0 AND o.Score =0 GROUP BY e.EmployeeId";
return Get<RB_Employee_Extend>(sql).ToList();
}
} }
} }
\ No newline at end of file
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