Commit 32892ee0 by lcx

科主任绩效详情

parent 11ca8929
......@@ -224,7 +224,7 @@ public ApiResponse AllComputeAvg([FromBody] ComputerRequest request)
PositionName = "不含行政高层人均绩效",
TotelNumber = gc.Select(w => new { w.JobNumber, w.EmployeeName }).Distinct().Count(),
TotelValue = Math.Round(gc.Sum(s => s.RealGiveFee) ?? 0),
AvgValue = gc.Select(p => new { p.JobNumber, p.EmployeeName }).Distinct().Count() == 0
AvgValue = gc.Select(p => new { p.JobNumber, p.EmployeeName }).Distinct().Count() == 0
? 0 : Math.Round(gc.Sum(s => s.RealGiveFee) / gc.Select(p => new { p.JobNumber, p.EmployeeName }).Distinct().Count() ?? 0)
});
......@@ -290,5 +290,18 @@ public ApiResponse GetBaiscnorm([FromBody] ComputerRequest request)
var list = _computeService.GetBaiscnorm(request.AllotId);
return new ApiResponse(ResponseType.OK, "ok", list);
}
/// <summary>
/// 医生绩效详情
/// </summary>
/// <param name="computeId"></param>
/// <returns></returns>
[Route("doctordetail/{computeId}")]
[HttpPost]
public ApiResponse DoctorDetail(int computeId)
{
var result = _computeService.GetDoctorDetail(computeId);
return new ApiResponse(ResponseType.OK, result);
}
}
}
\ No newline at end of file
......@@ -387,6 +387,13 @@
<param name="request"></param>
<returns></returns>
</member>
<member name="M:Performance.Api.Controllers.ComputeController.DoctorDetail(System.Int32)">
<summary>
医生绩效详情
</summary>
<param name="computeId"></param>
<returns></returns>
</member>
<member name="M:Performance.Api.Controllers.ConfigController.GetDrugList(Performance.DtoModels.DrugpropRequest)">
<summary>
获取 药占比配置信息列表
......
......@@ -894,6 +894,11 @@
核算单元
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.PermanentStaff">
<summary>
效率绩效人数
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.Number">
<summary>
核算单元医生数量
......@@ -954,16 +959,36 @@
规模绩效系数
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.ScalePerfor">
<summary>
规模绩效
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.Effic">
<summary>
效率绩效系数
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.EfficPerfor">
<summary>
效率绩效
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.Attendance">
<summary>
出勤率
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.Grant">
<summary>
发放系数
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.ShouldGiveFee">
<summary>
应发管理绩效
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.MedicineFactor">
<summary>
药占比系数
......@@ -999,6 +1024,11 @@
人均绩效
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.AvgPerfor">
<summary>
人均核算绩效
</summary>
</member>
<member name="P:Performance.DtoModels.PerDataAccountBaisc.RealGiveFee">
<summary>
实发绩效
......@@ -2604,7 +2634,7 @@
<summary> 收入项名称 </summary>
</member>
<member name="P:Performance.DtoModels.DetailDtos`1.IncomeType">
<summary> 1、收入 2、支出 3、工作量 4、特殊科室 5、科室奖罚 6、科室药占比考核 7、科室材料占比考核 </summary>
<summary> 1、收入 2、支出 3、工作量 4、特殊科室 5、科室奖罚 6、科室药占比考核 7、科室材料占比考核 8、调节后其他绩效 </summary>
</member>
<member name="P:Performance.DtoModels.DetailDtos`1.Amount">
<summary> 金额 </summary>
......
......@@ -28,15 +28,20 @@ public class PerDataAccountBaisc : IPerData
/// </summary>
public string AccountingUnit { get; set; }
/// <summary>
/// 医生姓名
/// </summary>
public string EmployeeName { get; set; }
///// <summary>
///// 科室名称
///// </summary>
//public string Department { get; set; }
///// <summary>
///// 效率绩效人数
///// </summary>
//public decimal PermanentStaff { get; set; }
/// <summary>
/// 效率绩效人数
/// </summary>
public decimal PermanentStaff { get; set; }
///// <summary>
///// 科主任/护士长数量
......@@ -94,6 +99,16 @@ public class PerDataAccountBaisc : IPerData
public decimal ScoringAverage { get; set; }
/// <summary>
/// 考核后管理绩效
/// </summary>
public Nullable<decimal> AssessLaterManagementFee { get; set; }
/// <summary>
/// 管理绩效发放系数
/// </summary>
public Nullable<decimal> Management { get; set; }
/// <summary>
/// 考核后其他绩效
/// </summary>
public Nullable<decimal> AssessLaterOtherFee { get; set; }
......@@ -114,15 +129,35 @@ public class PerDataAccountBaisc : IPerData
public decimal Scale { get; set; }
/// <summary>
/// 规模绩效
/// </summary>
public decimal ScalePerfor { get; set; }
/// <summary>
/// 效率绩效系数
/// </summary>
public decimal Effic { get; set; }
/// <summary>
/// 效率绩效
/// </summary>
public decimal EfficPerfor { get; set; }
/// <summary>
/// 出勤率
/// </summary>
public Nullable<decimal> Attendance { get; set; }
/// <summary>
/// 发放系数
/// </summary>
public decimal Grant { get; set; }
/// <summary>
/// 应发管理绩效
/// </summary>
public decimal ShouldGiveFee { get; set; }
///// <summary>
///// 保底绩效参考标准
///// </summary>
......@@ -183,6 +218,11 @@ public class PerDataAccountBaisc : IPerData
public Nullable<decimal> Avg { get; set; }
/// <summary>
/// 人均核算绩效
/// </summary>
public Nullable<decimal> AvgPerfor { get; set; }
/// <summary>
/// 实发绩效
/// </summary>
public Nullable<decimal> RealGiveFee { get; set; }
......
......@@ -47,7 +47,7 @@ public class DetailDtos<T>
/// <summary> 收入项名称 </summary>
public string ItemName { get; set; }
/// <summary> 1、收入 2、支出 3、工作量 4、特殊科室 5、科室奖罚 6、科室药占比考核 7、科室材料占比考核 </summary>
/// <summary> 1、收入 2、支出 3、工作量 4、特殊科室 5、科室奖罚 6、科室药占比考核 7、科室材料占比考核 8、调节后其他绩效 </summary>
public int IncomeType { get; set; }
/// <summary> 金额 </summary>
......
......@@ -1106,5 +1106,70 @@ public ag_secondallot GetSecondByAccountId(int accountId)
UnitType = UnitType.特殊核算组.ToString()
};
}
public DeptDataDetails GetDoctorDetail(int computeId)
{
var resCompute = _perforRescomputeRepository.GetEntity(t => t.ID == computeId);
if (resCompute == null) return new DeptDataDetails();
var allot = perforPerallotRepository.GetEntity(t => t.ID == resCompute.AllotID);
if (allot == null) return new DeptDataDetails();
var employee = _perforImemployeeclinicRepository.GetEntity(t => t.AllotID == resCompute.AllotID && t.AccountingUnit == resCompute.AccountingUnit && t.UnitType == resCompute.UnitType && t.DoctorName == resCompute.EmployeeName);
DeptDataDetails doctorDetails = new DeptDataDetails
{
ShowFormula = allot.ShowFormula,
Pandect = new PerDataAccountBaisc
{
AccountingUnit = resCompute.AccountingUnit,
EmployeeName = resCompute.EmployeeName,
PerforTotal = resCompute.PerforTotal, //科室考核前绩效
Number = resCompute.Number ?? 0, //核算人数
AvgPerfor = (resCompute.Number ?? 0) == 0 ? 0 : resCompute.PerforTotal / resCompute.Number, //人均绩效
BasicFactor = employee?.Basics ?? 0, //基础绩效系数
Attendance = resCompute.Attendance, //出勤率
Avg = resCompute.Avg, //实际人均
PermanentStaff = resCompute.PermanentStaff ?? 0, //效率绩效人数
Effic = employee.Efficiency ?? 0, //效率绩效系数
EfficPerfor = resCompute.Efficiency ?? 0, //效率绩效
Scale = employee.Scale ?? 0, //规模绩效系数
ScalePerfor = resCompute.Scale ?? 0, //规模绩效
Management = employee.Management,//管理绩效发放系数
ShouldGiveFee = resCompute.ShouldGiveFee ?? 0, //考核前管理绩效
ScoringAverage = resCompute.ScoreAverageRate ?? 0, //考核得分率
AssessLaterManagementFee = Math.Round(resCompute.ShouldGiveFee * resCompute.ScoreAverageRate * resCompute.Attendance + resCompute.Punishment ?? 0), //考核后管理绩效
AdjustFactor = employee?.Adjust ?? 0, //调节系数
AdjustLaterOtherFee = employee.AdjustLaterOtherFee, //调节后其他绩效
RealGiveFee = resCompute.RealGiveFee //绩效合计
},
Detail = new List<DetailDtos>()
};
var sheets = _perforPerSheetRepository.GetEntities(t => t.AllotID == resCompute.AllotID && new int[] { (int)SheetType.PersonExtra, (int)SheetType.PersonAdjustLaterOtherFee }.Contains(t.SheetType.Value));
if (sheets == null || !sheets.Any()) return doctorDetails;
var data = _perforImDataRepository.GetEntities(t => t.AllotID == resCompute.AllotID && sheets.Select(s => s.ID).Contains(t.SheetID.Value) && t.JobNumber == (resCompute.JobNumber ?? "") && t.EmployeeName == resCompute.EmployeeName && t.AccountingUnit == resCompute.AccountingUnit);
if (data == null || !data.Any()) return doctorDetails;
foreach (var sheet in sheets)
{
var sheetData = data.Where(t => t.SheetID == sheet.ID);
if (sheetData == null || !sheetData.Any()) continue;
var detail = new DetailDtos
{
ItemName = sheet.SheetName,
IncomeType = sheet.SheetType == (int)SheetType.PersonExtra ? 5 : 8,
Amount = sheetData.Where(t => t.IsTotal == 1)?.Sum(t => t.CellValue) ?? 0,
Items = sheetData.Where(t => t.IsTotal != 1)?.Select(t => new DetailModule
{
ItemName = t.TypeName,
ItemValue = t.CellValue
}).ToList()
};
doctorDetails.Detail.Add(detail);
}
return doctorDetails;
}
}
}
\ 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