Commit 35c40108 by 纪旭 韦

人员字典粘贴后人员标签错乱

parent 9dbacb68
...@@ -301,7 +301,7 @@ public ApiResponse GetAprGroupList([FromRoute] int isAudit, [FromBody] AllotIdRe ...@@ -301,7 +301,7 @@ public ApiResponse GetAprGroupList([FromRoute] int isAudit, [FromBody] AllotIdRe
TypeInDepartment = t.Key.TypeInDepartment, TypeInDepartment = t.Key.TypeInDepartment,
CreateDate = t.Key.CreateDate.ToString("yyyy-MM-dd HH:mm:ss"), CreateDate = t.Key.CreateDate.ToString("yyyy-MM-dd HH:mm:ss"),
Amount = t.Sum(s => s.Amount ?? 0), Amount = t.Sum(s => s.Amount ?? 0),
Status = t.Any(s => s.Status == 2) ? 2 : t.Any(s => s.Status == 4) ? 4 : t.FirstOrDefault().Status, Status = t.OrderByDescending(w => w.Id).FirstOrDefault().Status,
PerforType = string.Join("/", t.Select(w => w.PerforType).Distinct()), PerforType = string.Join("/", t.Select(w => w.PerforType).Distinct()),
AuditTime = t.Any(s => s.Status == 2) ? "" : t.Max(w => w.AuditTime)?.ToString("yyyy-MM-dd HH:mm:ss"), AuditTime = t.Any(s => s.Status == 2) ? "" : t.Max(w => w.AuditTime)?.ToString("yyyy-MM-dd HH:mm:ss"),
Remark = t.Any(s => !s.MarkStatus.HasValue) ? "" : $"已审计{t.Max(w => w.MarkTime)?.ToString("(yyyy-MM-dd HH:mm:ss)")}", Remark = t.Any(s => !s.MarkStatus.HasValue) ? "" : $"已审计{t.Max(w => w.MarkTime)?.ToString("(yyyy-MM-dd HH:mm:ss)")}",
...@@ -313,6 +313,20 @@ public ApiResponse GetAprGroupList([FromRoute] int isAudit, [FromBody] AllotIdRe ...@@ -313,6 +313,20 @@ public ApiResponse GetAprGroupList([FromRoute] int isAudit, [FromBody] AllotIdRe
} }
/// <summary> /// <summary>
/// 医院其他绩效提交
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
[Route("apr/submitdeptlist")]
[HttpPost]
public ApiResponse SubmitDeptList([FromBody] SubmitAmountRequest request)
{
if (employeeService.SubmitDeptList(request))
return new ApiResponse(ResponseType.OK,"提交成功");
else
return new ApiResponse(ResponseType.Fail,"提交失败");
}
/// <summary>
/// 医院其他绩效审核详情 /// 医院其他绩效审核详情
/// </summary> /// </summary>
/// <param name="request"></param> /// <param name="request"></param>
...@@ -643,7 +657,7 @@ public ApiResponse GetAprHideGroupList([FromRoute] int isAudit, [FromBody] Allot ...@@ -643,7 +657,7 @@ public ApiResponse GetAprHideGroupList([FromRoute] int isAudit, [FromBody] Allot
TypeInDepartment = t.Key.TypeInDepartment, TypeInDepartment = t.Key.TypeInDepartment,
CreateDate = t.Key.CreateDate.ToString("yyyy-MM-dd HH:mm:ss"), CreateDate = t.Key.CreateDate.ToString("yyyy-MM-dd HH:mm:ss"),
Amount = t.Sum(s => s.Amount ?? 0), Amount = t.Sum(s => s.Amount ?? 0),
Status = t.Any(s => s.Status == 2) ? 2 : t.Any(s => s.Status == 4) ? 4 : t.FirstOrDefault().Status, Status = t.OrderByDescending(w => w.Id).FirstOrDefault().Status,
PerforType = string.Join("/", t.Select(w => w.PerforType).Distinct()), PerforType = string.Join("/", t.Select(w => w.PerforType).Distinct()),
AuditTime = t.Any(s => s.Status == 2) ? "" : t.Max(w => w.AuditTime)?.ToString("yyyy-MM-dd HH:mm:ss"), AuditTime = t.Any(s => s.Status == 2) ? "" : t.Max(w => w.AuditTime)?.ToString("yyyy-MM-dd HH:mm:ss"),
Remark = t.Any(s => !s.MarkStatus.HasValue) ? "" : $"已审计{t.Max(w => w.MarkTime)?.ToString("(yyyy-MM-dd HH:mm:ss)")}", Remark = t.Any(s => !s.MarkStatus.HasValue) ? "" : $"已审计{t.Max(w => w.MarkTime)?.ToString("(yyyy-MM-dd HH:mm:ss)")}",
...@@ -654,6 +668,22 @@ public ApiResponse GetAprHideGroupList([FromRoute] int isAudit, [FromBody] Allot ...@@ -654,6 +668,22 @@ public ApiResponse GetAprHideGroupList([FromRoute] int isAudit, [FromBody] Allot
return new ApiResponse(ResponseType.OK, "ok", result); return new ApiResponse(ResponseType.OK, "ok", result);
} }
/// <summary>
/// 不公示其他绩效提交
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
[Route("apr/submithidegrouplist")]
[HttpPost]
public ApiResponse SubmitHideGroupList([FromBody] SubmitAmountRequest request)
{
if (employeeService.SubmitHideDeptList(request))
return new ApiResponse(ResponseType.OK, "提交成功");
else
return new ApiResponse(ResponseType.Fail, "提交失败");
}
/// <summary> /// <summary>
///不公示其他绩效审核详情 ///不公示其他绩效审核详情
/// </summary> /// </summary>
......
...@@ -1151,6 +1151,13 @@ ...@@ -1151,6 +1151,13 @@
<param name="request"></param> <param name="request"></param>
<returns></returns> <returns></returns>
</member> </member>
<member name="M:Performance.Api.Controllers.EmployeeController.SubmitDeptList(Performance.DtoModels.SubmitAmountRequest)">
<summary>
医院其他绩效提交
</summary>
<param name="request"></param>
<returns></returns>
</member>
<member name="M:Performance.Api.Controllers.EmployeeController.GetAprDetail(Performance.DtoModels.AprAmountAuditRequest)"> <member name="M:Performance.Api.Controllers.EmployeeController.GetAprDetail(Performance.DtoModels.AprAmountAuditRequest)">
<summary> <summary>
医院其他绩效审核详情 医院其他绩效审核详情
...@@ -1263,6 +1270,13 @@ ...@@ -1263,6 +1270,13 @@
<param name="request"></param> <param name="request"></param>
<returns></returns> <returns></returns>
</member> </member>
<member name="M:Performance.Api.Controllers.EmployeeController.SubmitHideGroupList(Performance.DtoModels.SubmitAmountRequest)">
<summary>
不公示其他绩效提交
</summary>
<param name="request"></param>
<returns></returns>
</member>
<member name="M:Performance.Api.Controllers.EmployeeController.GetAprHideDetail(Performance.EntityModels.per_apr_amount)"> <member name="M:Performance.Api.Controllers.EmployeeController.GetAprHideDetail(Performance.EntityModels.per_apr_amount)">
<summary> <summary>
不公示其他绩效审核详情 不公示其他绩效审核详情
......
...@@ -33,4 +33,12 @@ public class Member ...@@ -33,4 +33,12 @@ public class Member
public string PersonnelNumber { get; set; } public string PersonnelNumber { get; set; }
public string DoctorName { get; set; } public string DoctorName { get; set; }
} }
public class SubmitAmountRequest
{
public int AllotId { get; set; }
public string TypeInDepartment { get; set; }
public string PerforType { get; set; }
public string Remark { get; set; }
}
} }
...@@ -449,7 +449,23 @@ public List<per_apr_amount> GetAprList(int allotId, int userId, int isAudit) ...@@ -449,7 +449,23 @@ public List<per_apr_amount> GetAprList(int allotId, int userId, int isAudit)
return list; return list;
} }
/// <summary>
/// 医院其他绩效提交
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
public bool SubmitDeptList(SubmitAmountRequest request)
{
string[] perforTypes = request.PerforType.Split("/");
var result = perapramountRepository.GetEntities(w => w.AllotId == request.AllotId && w.TypeInDepartment == request.TypeInDepartment && perforTypes.Contains(w.PerforType));
result.ForEach(w =>
{
w.Status = 2;
w.Remark = request.Remark;
});
return perapramountRepository.UpdateRange(result.ToArray());
}
/// <summary> /// <summary>
/// 医院其他绩效审核详情 /// 医院其他绩效审核详情
/// </summary> /// </summary>
...@@ -925,6 +941,22 @@ public List<per_apr_amount_hide> GetAprHideList(int allotId, int userId, int isA ...@@ -925,6 +941,22 @@ public List<per_apr_amount_hide> GetAprHideList(int allotId, int userId, int isA
return list; return list;
} }
/// <summary> /// <summary>
/// 不公示其他绩效提交
/// </summary>
/// <returns></returns>
public bool SubmitHideDeptList(SubmitAmountRequest request)
{
string[] perforTypes = request.PerforType.Split("/");
var result = _hideRepository.GetEntities(w => w.AllotId == request.AllotId && w.TypeInDepartment == request.TypeInDepartment && perforTypes.Contains(w.PerforType));
result.ForEach(w =>
{
w.Status = 2;
w.Remark = request.Remark;
});
return _hideRepository.UpdateRange(result.ToArray());
}
/// <summary>
/// 医院其他绩效审核详情 /// 医院其他绩效审核详情
/// </summary> /// </summary>
/// <param name="allotId"></param> /// <param name="allotId"></param>
......
...@@ -984,7 +984,7 @@ public ApiResponse BathSavePerson(int allotId, int HospitalId, SaveCollectData r ...@@ -984,7 +984,7 @@ public ApiResponse BathSavePerson(int allotId, int HospitalId, SaveCollectData r
var backupTab = perforPeremployeeBackupRepository.GetEntities(t => t.AllotId == allotId); var backupTab = perforPeremployeeBackupRepository.GetEntities(t => t.AllotId == allotId);
employees.ForEach(e => employees.ForEach(e =>
{ {
var result = backupTab.FirstOrDefault(d => d.PersonnelNumber.Contains(e.PersonnelNumber) && d.AllotId == e.AllotId && d.HospitalId == e.HospitalId); var result = backupTab.FirstOrDefault(d => d.PersonnelNumber.Replace(" ","") == e.PersonnelNumber.Replace(" ", "") && d.AllotId == e.AllotId && d.HospitalId == e.HospitalId);
if (result != null) if (result != null)
{ {
e.JobNumber = result.JobNumber; e.JobNumber = result.JobNumber;
......
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