Commit dc6dedd5 by Licx

二次绩效审核详情接口报错

parent a8584dff
...@@ -428,6 +428,7 @@ public void RowsExpand(per_allot allot, List<SecondColumnDictionary> dic, List<D ...@@ -428,6 +428,7 @@ public void RowsExpand(per_allot allot, List<SecondColumnDictionary> dic, List<D
/// <returns></returns> /// <returns></returns>
private Dictionary<string, object> LoadHead(ComputeMode computeMode, per_allot allot, ag_secondallot second, EmployeeSource overrideMode = 0) private Dictionary<string, object> LoadHead(ComputeMode computeMode, per_allot allot, ag_secondallot second, EmployeeSource overrideMode = 0)
{ {
prevSecondAllot = _secondAllotDetails.GetPreviousSecondAllot(allot.HospitalId, second);
/* /*
此处数据需要额外注意,前端显示规则:接口返回则显示 此处数据需要额外注意,前端显示规则:接口返回则显示
避免额外返回造成前端错误显示 避免额外返回造成前端错误显示
...@@ -462,7 +463,7 @@ public void RowsExpand(per_allot allot, List<SecondColumnDictionary> dic, List<D ...@@ -462,7 +463,7 @@ public void RowsExpand(per_allot allot, List<SecondColumnDictionary> dic, List<D
{ {
int secondId = overrideMode == EmployeeSource.PrevSecondAllot ? prevSecondAllot.Id : second.Id; int secondId = overrideMode == EmployeeSource.PrevSecondAllot ? prevSecondAllot.Id : second.Id;
var history = _agheadsourceRepository.GetEntity(t => t.SecondId == secondId); var history = _agheadsourceRepository.GetEntity(t => t.SecondId == secondId);
if (history == null && secondId != prevSecondAllot.Id) if (history == null && secondId != (prevSecondAllot?.Id ?? 0))
history = _agheadsourceRepository.GetEntity(t => t.SecondId == prevSecondAllot.Id); history = _agheadsourceRepository.GetEntity(t => t.SecondId == prevSecondAllot.Id);
head.AddOrUpdate(nameof(ag_headsource.SeniorityTitlesAccountedPerformance), history?.SeniorityTitlesAccountedPerformance ?? 0.2m); head.AddOrUpdate(nameof(ag_headsource.SeniorityTitlesAccountedPerformance), history?.SeniorityTitlesAccountedPerformance ?? 0.2m);
...@@ -473,7 +474,7 @@ public void RowsExpand(per_allot allot, List<SecondColumnDictionary> dic, List<D ...@@ -473,7 +474,7 @@ public void RowsExpand(per_allot allot, List<SecondColumnDictionary> dic, List<D
var status = (new int[] { (int)SecondAllotStatus.WaitReview, (int)SecondAllotStatus.PassAudit }); var status = (new int[] { (int)SecondAllotStatus.WaitReview, (int)SecondAllotStatus.PassAudit });
var headDynamic = _agworktypesourceRepository.GetEntities(t => t.SecondId == secondId) ?? new List<ag_worktype_source>(); var headDynamic = _agworktypesourceRepository.GetEntities(t => t.SecondId == secondId) ?? new List<ag_worktype_source>();
if (!headDynamic.Any() && secondId != prevSecondAllot.Id) if (!headDynamic.Any() && secondId != (prevSecondAllot?.Id ?? 0))
headDynamic = _agworktypesourceRepository.GetEntities(t => t.SecondId == prevSecondAllot.Id) ?? new List<ag_worktype_source>(); headDynamic = _agworktypesourceRepository.GetEntities(t => t.SecondId == prevSecondAllot.Id) ?? new List<ag_worktype_source>();
// 已提交 // 已提交
......
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