Commit c96be038 by 799284587@qq.com

绩效科室绩效大动版,修改了很多,需详细测试

parent 2f1759de
...@@ -81,29 +81,29 @@ public AutoMapperConfigs() ...@@ -81,29 +81,29 @@ public AutoMapperConfigs()
CreateMap<PerDataEmployee, im_employee>(); CreateMap<PerDataEmployee, im_employee>();
CreateMap<im_employee, PerDataEmployee>(); CreateMap<im_employee, PerDataEmployee>();
CreateMap<PerDataAccountBaisc, PerDataAccountDoctor>() //CreateMap<PerDataAccountBaisc, PerDataAccount>()
.ForMember(dest => dest.AccountingUnit, opt => opt.MapFrom(src => src.AccountingUnit)) // .ForMember(dest => dest.AccountingUnit, opt => opt.MapFrom(src => src.AccountingUnit))
.ForMember(dest => dest.Department, opt => opt.MapFrom(src => src.Department)) // .ForMember(dest => dest.Department, opt => opt.MapFrom(src => src.Department))
.ForMember(dest => dest.Number, opt => opt.MapFrom(src => src.Number)) // .ForMember(dest => dest.Number, opt => opt.MapFrom(src => src.Number))
.ForMember(dest => dest.BasicFactor, opt => opt.MapFrom(src => src.BasicFactor)) // .ForMember(dest => dest.BasicFactor, opt => opt.MapFrom(src => src.BasicFactor))
.ForMember(dest => dest.SlopeFactor, opt => opt.MapFrom(src => src.SlopeFactor)) // .ForMember(dest => dest.SlopeFactor, opt => opt.MapFrom(src => src.SlopeFactor))
.ForMember(dest => dest.OtherPerfor1, opt => opt.MapFrom(src => src.OtherPerfor1)) // .ForMember(dest => dest.OtherPerfor1, opt => opt.MapFrom(src => src.OtherPerfor1))
.ForMember(dest => dest.OtherPerfor2, opt => opt.MapFrom(src => src.OtherPerfor2)) // .ForMember(dest => dest.OtherPerfor2, opt => opt.MapFrom(src => src.OtherPerfor2))
.ForMember(dest => dest.Extra, opt => opt.MapFrom(src => src.Extra)) // .ForMember(dest => dest.Extra, opt => opt.MapFrom(src => src.Extra))
.ForMember(dest => dest.ScoringAverage, opt => opt.MapFrom(src => src.ScoringAverage)) // .ForMember(dest => dest.ScoringAverage, opt => opt.MapFrom(src => src.ScoringAverage))
.ForMember(dest => dest.AdjustFactor, opt => opt.MapFrom(src => src.AdjustFactor)); // .ForMember(dest => dest.AdjustFactor, opt => opt.MapFrom(src => src.AdjustFactor));
CreateMap<PerDataAccountBaisc, PerDataAccount>() //CreateMap<PerDataAccountBaisc, PerDataAccount>()
.ForMember(dest => dest.AccountingUnit, opt => opt.MapFrom(src => src.AccountingUnit)) // .ForMember(dest => dest.AccountingUnit, opt => opt.MapFrom(src => src.AccountingUnit))
.ForMember(dest => dest.Department, opt => opt.MapFrom(src => src.Department)) // .ForMember(dest => dest.Department, opt => opt.MapFrom(src => src.Department))
.ForMember(dest => dest.Number, opt => opt.MapFrom(src => src.Number)) // .ForMember(dest => dest.Number, opt => opt.MapFrom(src => src.Number))
.ForMember(dest => dest.BasicFactor, opt => opt.MapFrom(src => src.BasicFactor)) // .ForMember(dest => dest.BasicFactor, opt => opt.MapFrom(src => src.BasicFactor))
.ForMember(dest => dest.SlopeFactor, opt => opt.MapFrom(src => src.SlopeFactor)) // .ForMember(dest => dest.SlopeFactor, opt => opt.MapFrom(src => src.SlopeFactor))
.ForMember(dest => dest.OtherPerfor1, opt => opt.MapFrom(src => src.OtherPerfor1)) // .ForMember(dest => dest.OtherPerfor1, opt => opt.MapFrom(src => src.OtherPerfor1))
.ForMember(dest => dest.OtherPerfor2, opt => opt.MapFrom(src => src.OtherPerfor2)) // .ForMember(dest => dest.OtherPerfor2, opt => opt.MapFrom(src => src.OtherPerfor2))
.ForMember(dest => dest.Extra, opt => opt.MapFrom(src => src.Extra)) // .ForMember(dest => dest.Extra, opt => opt.MapFrom(src => src.Extra))
.ForMember(dest => dest.ScoringAverage, opt => opt.MapFrom(src => src.ScoringAverage)) // .ForMember(dest => dest.ScoringAverage, opt => opt.MapFrom(src => src.ScoringAverage))
.ForMember(dest => dest.AdjustFactor, opt => opt.MapFrom(src => src.AdjustFactor)); // .ForMember(dest => dest.AdjustFactor, opt => opt.MapFrom(src => src.AdjustFactor));
//CreateMap<PerDataAccountBaisc, im_accountbasic>(); //CreateMap<PerDataAccountBaisc, im_accountbasic>();
//CreateMap<im_accountbasic, PerDataAccountBaisc>(); //CreateMap<im_accountbasic, PerDataAccountBaisc>();
...@@ -143,18 +143,20 @@ public AutoMapperConfigs() ...@@ -143,18 +143,20 @@ public AutoMapperConfigs()
.ForMember(dest => dest.Grant, opt => opt.MapFrom(src => src.DoctorGrant)); .ForMember(dest => dest.Grant, opt => opt.MapFrom(src => src.DoctorGrant));
CreateMap<PerDataSpecialUnit, im_specialunit>(); CreateMap<PerDataSpecialUnit, im_specialunit>();
CreateMap<PerDataAccountDoctor, res_accountdoctor>(); //CreateMap<PerDataAccountDoctor, res_accountdoctor>();
CreateMap<res_accountdoctor, PerDataAccount>(); //CreateMap<PerDataAccountNurse, res_accountnurse>();
CreateMap<PerDataAccountNurse, res_accountnurse>(); //CreateMap<res_accountdoctor, PerDataAccountBaisc>();
CreateMap<res_accountnurse, PerDataAccount>(); CreateMap<res_account, PerDataAccountBaisc>();
CreateMap<PerDataAccountBaisc, res_account>();
CreateMap<res_accountdoctor, ComputeSource>(); //CreateMap<PerDataAccountBaisc, res_accountnurse>();
CreateMap<res_accountnurse, ComputeSource>();
//CreateMap<res_accountdoctor, ComputeSource>();
//CreateMap<res_accountnurse, ComputeSource>();
CreateMap<im_employee, ComputeEmployee>(); CreateMap<im_employee, ComputeEmployee>();
CreateMap<ComputeResult, res_compute>(); CreateMap<ComputeResult, res_compute>();
CreateMap<res_accountdoctor, DoctorResponse>(); CreateMap<res_account, DoctorResponse>();
CreateMap<res_accountnurse, NurseResponse>(); CreateMap<res_account, NurseResponse>();
//二次绩效 //二次绩效
......
using System; //using System;
using System.Collections.Generic; //using System.Collections.Generic;
using System.Text; //using System.Text;
namespace Performance.DtoModels //namespace Performance.DtoModels
{ //{
public class ComputeSource // public class ComputeSource
{ // {
/// <summary> // /// <summary>
/// 核算单元 // /// 核算单元
/// </summary> // /// </summary>
public string AccountingUnit { get; set; } // public string AccountingUnit { get; set; }
/// <summary> // /// <summary>
/// 核算单元医生数量 // /// 核算单元医生数量
/// </summary> // /// </summary>
public Nullable<decimal> Number { get; set; } // public Nullable<decimal> Number { get; set; }
/// <summary> // /// <summary>
/// 医生基础系数 // /// 医生基础系数
/// </summary> // /// </summary>
public Nullable<decimal> BasicFactor { get; set; } // public Nullable<decimal> BasicFactor { get; set; }
/// <summary> // /// <summary>
/// 倾斜系数 // /// 倾斜系数
/// </summary> // /// </summary>
public Nullable<decimal> SlopeFactor { get; set; } // public Nullable<decimal> SlopeFactor { get; set; }
/// <summary> // /// <summary>
/// 其他绩效1 // /// 其他绩效1
/// </summary> // /// </summary>
public Nullable<decimal> OtherPerfor1 { get; set; } // public Nullable<decimal> OtherPerfor1 { get; set; }
/// <summary> // /// <summary>
/// 其他绩效2 // /// 其他绩效2
/// </summary> // /// </summary>
public Nullable<decimal> OtherPerfor2 { get; set; } // public Nullable<decimal> OtherPerfor2 { get; set; }
/// <summary> // /// <summary>
/// 医院奖罚 // /// 医院奖罚
/// </summary> // /// </summary>
public Nullable<decimal> Extra { get; set; } // public Nullable<decimal> Extra { get; set; }
/// <summary> // /// <summary>
/// 考核对分率 // /// 考核对分率
/// </summary> // /// </summary>
public Nullable<decimal> ScoringAverage { get; set; } // public Nullable<decimal> ScoringAverage { get; set; }
/// <summary> // /// <summary>
/// 调节系数 // /// 调节系数
/// </summary> // /// </summary>
public Nullable<decimal> AdjustFactor { get; set; } // public Nullable<decimal> AdjustFactor { get; set; }
/// <summary> // /// <summary>
/// 科室业绩 // /// 科室业绩
/// </summary> // /// </summary>
public Nullable<decimal> Income { get; set; } // public Nullable<decimal> Income { get; set; }
/// <summary> // /// <summary>
/// 业绩绩效 // /// 业绩绩效
/// </summary> // /// </summary>
public Nullable<decimal> PerforFee { get; set; } // public Nullable<decimal> PerforFee { get; set; }
/// <summary> // /// <summary>
/// 工作量绩效 // /// 工作量绩效
/// </summary> // /// </summary>
public Nullable<decimal> WorkloadFee { get; set; } // public Nullable<decimal> WorkloadFee { get; set; }
/// <summary> // /// <summary>
/// 绩效合计 // /// 绩效合计
/// </summary> // /// </summary>
public Nullable<decimal> PerforTotal { get; set; } // public Nullable<decimal> PerforTotal { get; set; }
/// <summary> // /// <summary>
/// 人均绩效 // /// 人均绩效
/// </summary> // /// </summary>
public Nullable<decimal> Avg { get; set; } // public Nullable<decimal> Avg { get; set; }
/// <summary> // /// <summary>
/// 实发绩效 // /// 实发绩效
/// </summary> // /// </summary>
public Nullable<decimal> GiveFee { get; set; } // public Nullable<decimal> GiveFee { get; set; }
} // }
} //}
using System; //using System;
using System.Collections.Generic; //using System.Collections.Generic;
using System.Text; //using System.Text;
namespace Performance.DtoModels //namespace Performance.DtoModels
{ //{
public class PerDataAccount : IPerData // public class PerDataAccount : IPerData
{ // {
/// <summary> // public int UnitType;
/// 核算单元
/// </summary> // /// <summary>
public string AccountingUnit { get; set; } // /// 核算单元
// /// </summary>
/// <summary> // public string AccountingUnit { get; set; }
/// 科室
/// </summary> // /// <summary>
public string Department { get; set; } // /// 科室
// /// </summary>
/// <summary> // public string Department { get; set; }
/// 核算单元医生数量
/// </summary> // /// <summary>
public Nullable<decimal> Number { get; set; } // /// 核算单元医生数量
// /// </summary>
/// <summary> // public Nullable<decimal> Number { get; set; }
/// 医生基础系数
/// </summary> // /// <summary>
public Nullable<decimal> BasicFactor { get; set; } // /// 医生基础系数
// /// </summary>
/// <summary> // public Nullable<decimal> BasicFactor { get; set; }
/// 倾斜系数
/// </summary> // /// <summary>
public Nullable<decimal> SlopeFactor { get; set; } // /// 倾斜系数
// /// </summary>
/// <summary> // public Nullable<decimal> SlopeFactor { get; set; }
/// 其他绩效1
/// </summary> // /// <summary>
public Nullable<decimal> OtherPerfor1 { get; set; } // /// 其他绩效1
// /// </summary>
/// <summary> // public Nullable<decimal> OtherPerfor1 { get; set; }
/// 其他绩效2
/// </summary> // /// <summary>
public Nullable<decimal> OtherPerfor2 { get; set; } // /// 其他绩效2
// /// </summary>
/// <summary> // public Nullable<decimal> OtherPerfor2 { get; set; }
/// 医院奖罚
/// </summary> // /// <summary>
public Nullable<decimal> Extra { get; set; } // /// 医院奖罚
// /// </summary>
/// <summary> // public Nullable<decimal> Extra { get; set; }
/// 考核对分率
/// </summary> // /// <summary>
public Nullable<decimal> ScoringAverage { get; set; } // /// 考核对分率
// /// </summary>
/// <summary> // public Nullable<decimal> ScoringAverage { get; set; }
/// 调节系数
/// </summary> // /// <summary>
public Nullable<decimal> AdjustFactor { get; set; } // /// 调节系数
// /// </summary>
/// <summary> // public Nullable<decimal> AdjustFactor { get; set; }
/// 科室业绩
/// </summary> // /// <summary>
public Nullable<decimal> Income { get; set; } // /// 科室业绩
// /// </summary>
/// <summary> // public Nullable<decimal> Income { get; set; }
/// 业绩绩效
/// </summary> // /// <summary>
public Nullable<decimal> PerforFee { get; set; } // /// 业绩绩效
// /// </summary>
/// <summary> // public Nullable<decimal> PerforFee { get; set; }
/// 工作量绩效
/// </summary> // /// <summary>
public Nullable<decimal> WorkloadFee { get; set; } // /// 工作量绩效
// /// </summary>
/// <summary> // public Nullable<decimal> WorkloadFee { get; set; }
/// 绩效合计
/// </summary> // /// <summary>
public Nullable<decimal> PerforTotal { get; set; } // /// 绩效合计
// /// </summary>
/// <summary> // public Nullable<decimal> PerforTotal { get; set; }
/// 人均绩效
/// </summary> // /// <summary>
public Nullable<decimal> Avg { get; set; } // /// 人均绩效
// /// </summary>
/// <summary> // public Nullable<decimal> Avg { get; set; }
/// 实发绩效
/// </summary> // /// <summary>
public Nullable<decimal> RealGiveFee { get; set; } // /// 实发绩效
} // /// </summary>
} // public Nullable<decimal> RealGiveFee { get; set; }
// }
//}
...@@ -6,6 +6,17 @@ namespace Performance.DtoModels ...@@ -6,6 +6,17 @@ namespace Performance.DtoModels
{ {
public class PerDataAccountBaisc : IPerData public class PerDataAccountBaisc : IPerData
{ {
/// <summary>
/// 行号
/// </summary>
public int RowNumber { get; set; }
/// <summary>
/// 备注
/// </summary>
public string Remark { get; set; }
#region EXCEL读取
/// <summary> /// <summary>
/// 核算单元类别 1 医生组 2护理组 3医技组 /// 核算单元类别 1 医生组 2护理组 3医技组
...@@ -61,29 +72,61 @@ public class PerDataAccountBaisc : IPerData ...@@ -61,29 +72,61 @@ public class PerDataAccountBaisc : IPerData
/// 考核对分率 /// 考核对分率
/// </summary> /// </summary>
public decimal ScoringAverage { get; set; } public decimal ScoringAverage { get; set; }
/// <summary> /// <summary>
/// 调节系数 /// 调节系数
/// </summary> /// </summary>
public decimal AdjustFactor { get; set; } public decimal AdjustFactor { get; set; }
/// <summary> /// <summary>
/// 行号
/// </summary>
public int RowNumber { get; set; }
/// <summary>
/// 规模绩效系数 /// 规模绩效系数
/// </summary> /// </summary>
public Nullable<decimal> Scale { get; set; } public decimal Scale { get; set; }
/// <summary> /// <summary>
/// 效率绩效系数 /// 效率绩效系数
/// </summary> /// </summary>
public Nullable<decimal> Effic { get; set; } public decimal Effic { get; set; }
/// <summary> /// <summary>
/// 发放系数 /// 发放系数
/// </summary> /// </summary>
public Nullable<decimal> Grant { get; set; } public decimal Grant { get; set; }
#endregion
#region 由计算得出
/// <summary>
/// 科室业绩
/// </summary>
public Nullable<decimal> Income { get; set; }
/// <summary>
/// 业绩绩效
/// </summary>
public Nullable<decimal> PerforFee { get; set; }
/// <summary>
/// 工作量绩效
/// </summary>
public Nullable<decimal> WorkloadFee { get; set; }
/// <summary>
/// 绩效合计
/// </summary>
public Nullable<decimal> PerforTotal { get; set; }
/// <summary>
/// 人均绩效
/// </summary>
public Nullable<decimal> Avg { get; set; }
/// <summary>
/// 实发绩效
/// </summary>
public Nullable<decimal> RealGiveFee { get; set; }
#endregion
} }
} }
using System; //using System;
using System.Collections.Generic; //using System.Collections.Generic;
using System.Text; //using System.Text;
namespace Performance.DtoModels //namespace Performance.DtoModels
{ //{
public class PerDataAccountDoctor : IPerData // public class PerDataAccountDoctor : IPerData
{ // {
public int UnitType { get; set; } // public int UnitType { get; set; }
/// <summary> // /// <summary>
/// 核算单元 // /// 核算单元
/// </summary> // /// </summary>
public string AccountingUnit { get; set; } // public string AccountingUnit { get; set; }
/// <summary> // /// <summary>
/// 科室名称 // /// 科室名称
/// </summary> // /// </summary>
public string Department { get; set; } // public string Department { get; set; }
/// <summary> // /// <summary>
/// 核算单元医生数量 // /// 核算单元医生数量
/// </summary> // /// </summary>
public decimal Number { get; set; } // public decimal Number { get; set; }
/// <summary> // /// <summary>
/// 医生基础系数 // /// 医生基础系数
/// </summary> // /// </summary>
public decimal BasicFactor { get; set; } // public decimal BasicFactor { get; set; }
/// <summary> // /// <summary>
/// 倾斜系数 // /// 倾斜系数
/// </summary> // /// </summary>
public decimal SlopeFactor { get; set; } // public decimal SlopeFactor { get; set; }
/// <summary> // /// <summary>
/// 其他绩效1 // /// 其他绩效1
/// </summary> // /// </summary>
public decimal OtherPerfor1 { get; set; } // public decimal OtherPerfor1 { get; set; }
/// <summary> // /// <summary>
/// 其他绩效2 // /// 其他绩效2
/// </summary> // /// </summary>
public decimal OtherPerfor2 { get; set; } // public decimal OtherPerfor2 { get; set; }
/// <summary> // /// <summary>
/// 医院奖罚 // /// 医院奖罚
/// </summary> // /// </summary>
public decimal Extra { get; set; } // public decimal Extra { get; set; }
/// <summary> // /// <summary>
/// 考核对分率 // /// 考核对分率
/// </summary> // /// </summary>
public decimal ScoringAverage { get; set; } // public decimal ScoringAverage { get; set; }
/// <summary> // /// <summary>
/// 调节系数 // /// 调节系数
/// </summary> // /// </summary>
public decimal AdjustFactor { get; set; } // public decimal AdjustFactor { get; set; }
/// <summary> // /// <summary>
/// 科室业绩 // /// 科室业绩
/// </summary> // /// </summary>
public decimal Income { get; set; } // public decimal Income { get; set; }
/// <summary> // /// <summary>
/// 工作量绩效 // /// 工作量绩效
/// </summary> // /// </summary>
public decimal WorkloadFee { get; set; } // public decimal WorkloadFee { get; set; }
/// <summary> // /// <summary>
/// 绩效合计 // /// 绩效合计
/// </summary> // /// </summary>
public decimal PerforTotal { get; set; } // public decimal PerforTotal { get; set; }
/// <summary> // /// <summary>
/// 业绩绩效 // /// 业绩绩效
/// </summary> // /// </summary>
public decimal PerforFee { get; set; } // public decimal PerforFee { get; set; }
/// <summary> // /// <summary>
/// 实发绩效 // /// 实发绩效
/// </summary> // /// </summary>
public decimal RealGiveFee { get; set; } // public decimal RealGiveFee { get; set; }
/// <summary> // /// <summary>
/// 人均绩效 // /// 人均绩效
/// </summary> // /// </summary>
public decimal Avg { get; set; } // public decimal Avg { get; set; }
} // }
} //}
using System; //using System;
using System.Collections.Generic; //using System.Collections.Generic;
using System.Text; //using System.Text;
namespace Performance.DtoModels //namespace Performance.DtoModels
{ //{
public class PerDataAccountNurse : IPerData // public class PerDataAccountNurse : IPerData
{ // {
public int UnitType { get; set; } // public int UnitType { get; set; }
/// <summary> // /// <summary>
/// 核算单元 // /// 核算单元
/// </summary> // /// </summary>
public string AccountingUnit { get; set; } // public string AccountingUnit { get; set; }
/// <summary> // /// <summary>
/// 科室名称 // /// 科室名称
/// </summary> // /// </summary>
public string Department { get; set; } // public string Department { get; set; }
/// <summary> // /// <summary>
/// 核算单元护士数量 // /// 核算单元护士数量
/// </summary> // /// </summary>
public decimal Number { get; set; } // public decimal Number { get; set; }
/// <summary> // /// <summary>
/// 护理基础系数 // /// 护理基础系数
/// </summary> // /// </summary>
public decimal BasicFactor { get; set; } // public decimal BasicFactor { get; set; }
/// <summary> // /// <summary>
/// 护理倾斜系数 // /// 护理倾斜系数
/// </summary> // /// </summary>
public decimal SlopeFactor { get; set; } // public decimal SlopeFactor { get; set; }
/// <summary> // /// <summary>
/// 其他绩效1 // /// 其他绩效1
/// </summary> // /// </summary>
public decimal OtherPerfor1 { get; set; } // public decimal OtherPerfor1 { get; set; }
/// <summary> // /// <summary>
/// 其他绩效2 // /// 其他绩效2
/// </summary> // /// </summary>
public decimal OtherPerfor2 { get; set; } // public decimal OtherPerfor2 { get; set; }
/// <summary> // /// <summary>
/// 医院奖罚 // /// 医院奖罚
/// </summary> // /// </summary>
public decimal Extra { get; set; } // public decimal Extra { get; set; }
/// <summary> // /// <summary>
/// 考核对分率 // /// 考核对分率
/// </summary> // /// </summary>
public decimal ScoringAverage { get; set; } // public decimal ScoringAverage { get; set; }
/// <summary> // /// <summary>
/// 调节系数 // /// 调节系数
/// </summary> // /// </summary>
public decimal AdjustFactor { get; set; } // public decimal AdjustFactor { get; set; }
/// <summary> // /// <summary>
/// 科室业绩 // /// 科室业绩
/// </summary> // /// </summary>
public decimal Income { get; set; } // public decimal Income { get; set; }
/// <summary> // /// <summary>
/// 工作量绩效 // /// 工作量绩效
/// </summary> // /// </summary>
public decimal WorkloadFee { get; set; } // public decimal WorkloadFee { get; set; }
/// <summary> // /// <summary>
/// 绩效合计 // /// 绩效合计
/// </summary> // /// </summary>
public decimal PerforTotal { get; set; } // public decimal PerforTotal { get; set; }
/// <summary> // /// <summary>
/// 业绩绩效 // /// 业绩绩效
/// </summary> // /// </summary>
public decimal PerforFee { get; set; } // public decimal PerforFee { get; set; }
/// <summary> // /// <summary>
/// 实发绩效 // /// 实发绩效
/// </summary> // /// </summary>
public decimal RealGiveFee { get; set; } // public decimal RealGiveFee { get; set; }
/// <summary> // /// <summary>
/// 人均绩效 // /// 人均绩效
/// </summary> // /// </summary>
public decimal Avg { get; set; } // public decimal Avg { get; set; }
} // }
} //}
...@@ -6,7 +6,7 @@ namespace Performance.DtoModels ...@@ -6,7 +6,7 @@ namespace Performance.DtoModels
{ {
public class DeptDetailResponse public class DeptDetailResponse
{ {
public PerDataAccount Pandect { get; set; } public PerDataAccountBaisc Pandect { get; set; }
public List<DeptDetail> Economic { get; set; } public List<DeptDetail> Economic { get; set; }
public List<DeptDetail> Workload { get; set; } public List<DeptDetail> Workload { get; set; }
} }
......
...@@ -78,10 +78,12 @@ public PerformanceDbContext(DbContextOptions<PerformanceDbContext> options) ...@@ -78,10 +78,12 @@ public PerformanceDbContext(DbContextOptions<PerformanceDbContext> options)
public virtual DbSet<per_first> per_first { get; set; } public virtual DbSet<per_first> per_first { get; set; }
/// <summary> 上传数据解析 <summary> /// <summary> 上传数据解析 <summary>
public virtual DbSet<per_sheet> per_sheet { get; set; } public virtual DbSet<per_sheet> per_sheet { get; set; }
/// <summary> 科室核算结果 <summary>
public virtual DbSet<res_account> res_account { get; set; }
/// <summary> 医生科室核算结果 <summary> /// <summary> 医生科室核算结果 <summary>
public virtual DbSet<res_accountdoctor> res_accountdoctor { get; set; } // public virtual DbSet<res_accountdoctor> res_accountdoctor { get; set; }
/// <summary> 护理科室核算结果 <summary> ///// <summary> 护理科室核算结果 <summary>
public virtual DbSet<res_accountnurse> res_accountnurse { get; set; } // public virtual DbSet<res_accountnurse> res_accountnurse { get; set; }
/// <summary> 核算基础标准 <summary> /// <summary> 核算基础标准 <summary>
public virtual DbSet<res_baiscnorm> res_baiscnorm { get; set; } public virtual DbSet<res_baiscnorm> res_baiscnorm { get; set; }
/// <summary> <summary> /// <summary> <summary>
......
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
// <copyright file=" mod_module.cs"> // <copyright file=" mod_module.cs">
// * FileName: .cs // * FileName: .cs
// </copyright> // </copyright>
...@@ -45,5 +45,15 @@ public class mod_module ...@@ -45,5 +45,15 @@ public class mod_module
/// 提取脚本ID /// 提取脚本ID
/// </summary> /// </summary>
public Nullable<int> ExtractId { get; set; } public Nullable<int> ExtractId { get; set; }
/// <summary>
/// 只读 0、否 1、是
/// </summary>
public Nullable<int> ReadOnly { get; set; }
/// <summary>
/// 是否生成Item 0、否 1、是
/// </summary>
public Nullable<int> IsGenerated { get; set; }
} }
} }
//-----------------------------------------------------------------------
// <copyright file=" res_account.cs">
// * FileName: 科室核算结果.cs
// </copyright>
//-----------------------------------------------------------------------
using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Performance.EntityModels
{
/// <summary>
/// 科室核算结果
/// </summary>
[Table("res_account")]
public class res_account
{
/// <summary>
///
/// </summary>
[Key]
public int ID { get; set; }
/// <summary>
///
/// </summary>
public Nullable<int> AllotID { get; set; }
/// <summary>
///
/// </summary>
public Nullable<int> SheetID { get; set; }
/// <summary>
/// 核算单元类型 1 医生组 2 护理组 3 医技组
/// </summary>
public Nullable<int> UnitType { get; set; }
/// <summary>
/// 核算单元
/// </summary>
public string AccountingUnit { get; set; }
/// <summary>
/// 科室
/// </summary>
public string Department { get; set; }
/// <summary>
/// 科主任/护士长数量
/// </summary>
public Nullable<int> ManagerNumber { get; set; }
/// <summary>
/// 核算单元医生数量
/// </summary>
public Nullable<decimal> Number { get; set; }
/// <summary>
/// 医生基础系数
/// </summary>
public Nullable<decimal> BasicFactor { get; set; }
/// <summary>
/// 倾斜系数
/// </summary>
public Nullable<decimal> SlopeFactor { get; set; }
/// <summary>
/// 其他绩效1
/// </summary>
public Nullable<decimal> OtherPerfor1 { get; set; }
/// <summary>
/// 其他绩效2
/// </summary>
public Nullable<decimal> OtherPerfor2 { get; set; }
/// <summary>
/// 医院奖罚
/// </summary>
public Nullable<decimal> Extra { get; set; }
/// <summary>
/// 考核对分率
/// </summary>
public Nullable<decimal> ScoringAverage { get; set; }
/// <summary>
/// 调节系数
/// </summary>
public Nullable<decimal> AdjustFactor { get; set; }
/// <summary>
/// 科室业绩
/// </summary>
public Nullable<decimal> Income { get; set; }
/// <summary>
/// 业绩绩效
/// </summary>
public Nullable<decimal> PerforFee { get; set; }
/// <summary>
/// 工作量绩效
/// </summary>
public Nullable<decimal> WorkloadFee { get; set; }
/// <summary>
/// 绩效合计
/// </summary>
public Nullable<decimal> PerforTotal { get; set; }
/// <summary>
/// 人均绩效
/// </summary>
public Nullable<decimal> Avg { get; set; }
/// <summary>
/// 实发绩效
/// </summary>
public Nullable<decimal> RealGiveFee { get; set; }
/// <summary>
/// 备注
/// </summary>
public string Remark { get; set; }
/// <summary>
/// 变更日志
/// </summary>
public string ChangeLog { get; set; }
}
}
//----------------------------------------------------------------------- ////-----------------------------------------------------------------------
// <copyright file=" res_accountdoctor.cs"> //// <copyright file=" res_accountdoctor.cs">
// * FileName: 医生科室核算结果.cs //// * FileName: 医生科室核算结果.cs
// </copyright> //// </copyright>
//----------------------------------------------------------------------- ////-----------------------------------------------------------------------
using System; //using System;
using System.ComponentModel.DataAnnotations; //using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; //using System.ComponentModel.DataAnnotations.Schema;
namespace Performance.EntityModels //namespace Performance.EntityModels
{ //{
/// <summary> // /// <summary>
/// 医生科室核算结果 // /// 医生科室核算结果
/// </summary> // /// </summary>
[Table("res_accountdoctor")] // [Table("res_accountdoctor")]
public class res_accountdoctor // public class res_accountdoctor
{ // {
/// <summary> // /// <summary>
/// // ///
/// </summary> // /// </summary>
[Key] // [Key]
public int ID { get; set; } // public int ID { get; set; }
/// <summary> // /// <summary>
/// // ///
/// </summary> // /// </summary>
public Nullable<int> AllotID { get; set; } // public Nullable<int> AllotID { get; set; }
/// <summary> // /// <summary>
/// // ///
/// </summary> // /// </summary>
public Nullable<int> SheetID { get; set; } // public Nullable<int> SheetID { get; set; }
/// <summary> // /// <summary>
/// 核算单元 // /// 核算单元
/// </summary> // /// </summary>
public string AccountingUnit { get; set; } // public string AccountingUnit { get; set; }
/// <summary> // /// <summary>
/// 科室 // /// 科室
/// </summary> // /// </summary>
public string Department { get; set; } // public string Department { get; set; }
/// <summary> // /// <summary>
/// 核算单元医生数量 // /// 科主任/护士长数量
/// </summary> // /// </summary>
public Nullable<decimal> Number { get; set; } // public Nullable<int> ManagerNumber { get; set; }
/// <summary> // /// <summary>
/// 医生基础系数 // /// 核算单元医生数量
/// </summary> // /// </summary>
public Nullable<decimal> BasicFactor { get; set; } // public Nullable<decimal> Number { get; set; }
/// <summary> // /// <summary>
/// 倾斜系数 // /// 医生基础系数
/// </summary> // /// </summary>
public Nullable<decimal> SlopeFactor { get; set; } // public Nullable<decimal> BasicFactor { get; set; }
/// <summary> // /// <summary>
/// 其他绩效1 // /// 倾斜系数
/// </summary> // /// </summary>
public Nullable<decimal> OtherPerfor1 { get; set; } // public Nullable<decimal> SlopeFactor { get; set; }
/// <summary> // /// <summary>
/// 其他绩效2 // /// 其他绩效1
/// </summary> // /// </summary>
public Nullable<decimal> OtherPerfor2 { get; set; } // public Nullable<decimal> OtherPerfor1 { get; set; }
/// <summary> // /// <summary>
/// 医院奖罚 // /// 其他绩效2
/// </summary> // /// </summary>
public Nullable<decimal> Extra { get; set; } // public Nullable<decimal> OtherPerfor2 { get; set; }
/// <summary> // /// <summary>
/// 考核对分率 // /// 医院奖罚
/// </summary> // /// </summary>
public Nullable<decimal> ScoringAverage { get; set; } // public Nullable<decimal> Extra { get; set; }
/// <summary> // /// <summary>
/// 调节系数 // /// 考核对分率
/// </summary> // /// </summary>
public Nullable<decimal> AdjustFactor { get; set; } // public Nullable<decimal> ScoringAverage { get; set; }
/// <summary> // /// <summary>
/// 科室业绩 // /// 调节系数
/// </summary> // /// </summary>
public Nullable<decimal> Income { get; set; } // public Nullable<decimal> AdjustFactor { get; set; }
/// <summary> // /// <summary>
/// 业绩绩效 // /// 科室业绩
/// </summary> // /// </summary>
public Nullable<decimal> PerforFee { get; set; } // public Nullable<decimal> Income { get; set; }
/// <summary> // /// <summary>
/// 工作量绩效 // /// 业绩绩效
/// </summary> // /// </summary>
public Nullable<decimal> WorkloadFee { get; set; } // public Nullable<decimal> PerforFee { get; set; }
/// <summary> // /// <summary>
/// 绩效合计 // /// 工作量绩效
/// </summary> // /// </summary>
public Nullable<decimal> PerforTotal { get; set; } // public Nullable<decimal> WorkloadFee { get; set; }
/// <summary> // /// <summary>
/// 人均绩效 // /// 绩效合计
/// </summary> // /// </summary>
public Nullable<decimal> Avg { get; set; } // public Nullable<decimal> PerforTotal { get; set; }
/// <summary> // /// <summary>
/// 实发绩效 // /// 人均绩效
/// </summary> // /// </summary>
public Nullable<decimal> RealGiveFee { get; set; } // public Nullable<decimal> Avg { get; set; }
/// <summary> // /// <summary>
/// 变更日志 // /// 实发绩效
/// </summary> // /// </summary>
public string ChangeLog { get; set; } // public Nullable<decimal> RealGiveFee { get; set; }
}
} // /// <summary>
// /// 变更日志
// /// </summary>
// public string ChangeLog { get; set; }
// }
//}
//----------------------------------------------------------------------- ////-----------------------------------------------------------------------
// <copyright file=" res_accountnurse.cs"> //// <copyright file=" res_accountnurse.cs">
// * FileName: 护理科室核算结果.cs //// * FileName: 护理科室核算结果.cs
// </copyright> //// </copyright>
//----------------------------------------------------------------------- ////-----------------------------------------------------------------------
using System; //using System;
using System.ComponentModel.DataAnnotations; //using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; //using System.ComponentModel.DataAnnotations.Schema;
namespace Performance.EntityModels //namespace Performance.EntityModels
{ //{
/// <summary> // /// <summary>
/// 护理科室核算结果 // /// 护理科室核算结果
/// </summary> // /// </summary>
[Table("res_accountnurse")] // [Table("res_accountnurse")]
public class res_accountnurse // public class res_accountnurse
{ // {
/// <summary> // /// <summary>
/// // ///
/// </summary> // /// </summary>
[Key] // [Key]
public int ID { get; set; } // public int ID { get; set; }
/// <summary> // /// <summary>
/// // ///
/// </summary> // /// </summary>
public Nullable<int> AllotID { get; set; } // public Nullable<int> AllotID { get; set; }
/// <summary> // /// <summary>
/// // ///
/// </summary> // /// </summary>
public Nullable<int> SheetID { get; set; } // public Nullable<int> SheetID { get; set; }
/// <summary> // /// <summary>
/// 核算单元 // /// 核算单元
/// </summary> // /// </summary>
public string AccountingUnit { get; set; } // public string AccountingUnit { get; set; }
/// <summary> // /// <summary>
/// 科室 // /// 科室
/// </summary> // /// </summary>
public string Department { get; set; } // public string Department { get; set; }
/// <summary> // /// <summary>
/// 护士人数 // /// 科主任/护士长数量
/// </summary> // /// </summary>
public Nullable<decimal> Number { get; set; } // public Nullable<int> ManagerNumber { get; set; }
/// <summary> // /// <summary>
/// 护理基础系数 // /// 护士人数
/// </summary> // /// </summary>
public Nullable<decimal> BasicFactor { get; set; } // public Nullable<decimal> Number { get; set; }
/// <summary> // /// <summary>
/// 倾斜系数 // /// 护理基础系数
/// </summary> // /// </summary>
public Nullable<decimal> SlopeFactor { get; set; } // public Nullable<decimal> BasicFactor { get; set; }
/// <summary> // /// <summary>
/// 其他绩效1 // /// 倾斜系数
/// </summary> // /// </summary>
public Nullable<decimal> OtherPerfor1 { get; set; } // public Nullable<decimal> SlopeFactor { get; set; }
/// <summary> // /// <summary>
/// 其他绩效2 // /// 其他绩效1
/// </summary> // /// </summary>
public Nullable<decimal> OtherPerfor2 { get; set; } // public Nullable<decimal> OtherPerfor1 { get; set; }
/// <summary> // /// <summary>
/// 医院奖罚 // /// 其他绩效2
/// </summary> // /// </summary>
public Nullable<decimal> Extra { get; set; } // public Nullable<decimal> OtherPerfor2 { get; set; }
/// <summary> // /// <summary>
/// 考核对分率 // /// 医院奖罚
/// </summary> // /// </summary>
public Nullable<decimal> ScoringAverage { get; set; } // public Nullable<decimal> Extra { get; set; }
/// <summary> // /// <summary>
/// 调节系数 // /// 考核对分率
/// </summary> // /// </summary>
public Nullable<decimal> AdjustFactor { get; set; } // public Nullable<decimal> ScoringAverage { get; set; }
/// <summary> // /// <summary>
/// 科室业绩 // /// 调节系数
/// </summary> // /// </summary>
public Nullable<decimal> Income { get; set; } // public Nullable<decimal> AdjustFactor { get; set; }
/// <summary> // /// <summary>
/// 业绩绩效 // /// 科室业绩
/// </summary> // /// </summary>
public Nullable<decimal> PerforFee { get; set; } // public Nullable<decimal> Income { get; set; }
/// <summary> // /// <summary>
/// 工作量绩效 // /// 业绩绩效
/// </summary> // /// </summary>
public Nullable<decimal> WorkloadFee { get; set; } // public Nullable<decimal> PerforFee { get; set; }
/// <summary> // /// <summary>
/// 绩效合计 // /// 工作量绩效
/// </summary> // /// </summary>
public Nullable<decimal> PerforTotal { get; set; } // public Nullable<decimal> WorkloadFee { get; set; }
/// <summary> // /// <summary>
/// 人均绩效 // /// 绩效合计
/// </summary> // /// </summary>
public Nullable<decimal> Avg { get; set; } // public Nullable<decimal> PerforTotal { get; set; }
/// <summary> // /// <summary>
/// 实发绩效 // /// 人均绩效
/// </summary> // /// </summary>
public Nullable<decimal> RealGiveFee { get; set; } // public Nullable<decimal> Avg { get; set; }
}
} // /// <summary>
// /// 实发绩效
// /// </summary>
// public Nullable<decimal> RealGiveFee { get; set; }
// }
//}
//-----------------------------------------------------------------------
// <copyright file=" im_data.cs">
// * FileName: im_data.cs
// </copyright>
//-----------------------------------------------------------------------
using Performance.EntityModels;
using System;
using System.Collections.Generic;
namespace Performance.Repository
{
/// <summary>
/// im_data Repository
/// </summary>
public partial class PerforImdataRepository : PerforRepository<im_data>
{
/// <summary>
/// 获取核算单元
/// </summary>
/// <param name="deptList">科室列表</param>
/// <param name="hospitalid">医院id</param>
/// <param name="sheetType">sheet模板类型</param>
/// <returns></returns>
public IEnumerable<im_data> GetAccountingUnit(int hospitalid, int sheettype, List<string> deptList)
{
string sql = "select distinct im.accountingUnit,im.department,im.unittype from im_data im " +
"inner join per_allot allot on im.AllotID = allot.ID " +
"inner join per_sheet sheet on im.SheetID = sheet.ID " +
"where allot.hospitalid = @hospitalid and sheet.sheettype = @sheettype and im.department in @deptList";
return DapperQuery(sql, new { hospitalid, sheettype, deptList }, 1000 * 60 * 5);
}
}
}
...@@ -4,7 +4,6 @@ ...@@ -4,7 +4,6 @@
// </copyright> // </copyright>
//----------------------------------------------------------------------- //-----------------------------------------------------------------------
using System; using System;
using System.Collections.Generic;
using Performance.EntityModels; using Performance.EntityModels;
namespace Performance.Repository namespace Performance.Repository
...@@ -17,21 +16,5 @@ public partial class PerforImdataRepository : PerforRepository<im_data> ...@@ -17,21 +16,5 @@ public partial class PerforImdataRepository : PerforRepository<im_data>
public PerforImdataRepository(PerformanceDbContext context) : base(context) public PerforImdataRepository(PerformanceDbContext context) : base(context)
{ {
} }
/// <summary>
/// 获取核算单元
/// </summary>
/// <param name="deptList">科室列表</param>
/// <param name="hospitalid">医院id</param>
/// <param name="sheetType">sheet模板类型</param>
/// <returns></returns>
public IEnumerable<im_data> GetAccountingUnit(int hospitalid, int sheettype, List<string> deptList)
{
string sql = "select distinct im.accountingUnit,im.department,im.unittype from im_data im " +
"inner join per_allot allot on im.AllotID = allot.ID " +
"inner join per_sheet sheet on im.SheetID = sheet.ID " +
"where allot.hospitalid = @hospitalid and sheet.sheettype = @sheettype and im.department in @deptList";
return DapperQuery(sql, new { hospitalid, sheettype, deptList }, 1000 * 60 * 5);
}
} }
} }
//-----------------------------------------------------------------------
// <copyright file=" res_account.cs">
// * FileName: res_account.cs
// </copyright>
//-----------------------------------------------------------------------
using System;
using Performance.EntityModels;
namespace Performance.Repository
{
/// <summary>
/// res_account Repository
/// </summary>
public partial class PerforResaccountRepository : PerforRepository<res_account>
{
public PerforResaccountRepository(PerformanceDbContext context) : base(context)
{
}
}
}
//----------------------------------------------------------------------- ////-----------------------------------------------------------------------
// <copyright file=" res_accountdoctor.cs"> //// <copyright file=" res_accountdoctor.cs">
// * FileName: res_accountdoctor.cs //// * FileName: res_accountdoctor.cs
// </copyright> //// </copyright>
//----------------------------------------------------------------------- ////-----------------------------------------------------------------------
using System; //using System;
using Performance.EntityModels; //using Performance.EntityModels;
namespace Performance.Repository //namespace Performance.Repository
{ //{
/// <summary> // /// <summary>
/// res_accountdoctor Repository // /// res_accountdoctor Repository
/// </summary> // /// </summary>
public partial class PerforResaccountdoctorRepository : PerforRepository<res_accountdoctor> // public partial class PerforResaccountdoctorRepository : PerforRepository<res_accountdoctor>
{ // {
public PerforResaccountdoctorRepository(PerformanceDbContext context) : base(context) // public PerforResaccountdoctorRepository(PerformanceDbContext context) : base(context)
{ // {
} // }
} // }
} //}
//----------------------------------------------------------------------- ////-----------------------------------------------------------------------
// <copyright file=" res_accountnurse.cs"> //// <copyright file=" res_accountnurse.cs">
// * FileName: res_accountnurse.cs //// * FileName: res_accountnurse.cs
// </copyright> //// </copyright>
//----------------------------------------------------------------------- ////-----------------------------------------------------------------------
using System; //using System;
using Performance.EntityModels; //using Performance.EntityModels;
namespace Performance.Repository //namespace Performance.Repository
{ //{
/// <summary> // /// <summary>
/// res_accountnurse Repository // /// res_accountnurse Repository
/// </summary> // /// </summary>
public partial class PerforResaccountnurseRepository : PerforRepository<res_accountnurse> // public partial class PerforResaccountnurseRepository : PerforRepository<res_accountnurse>
{ // {
public PerforResaccountnurseRepository(PerformanceDbContext context) : base(context) // public PerforResaccountnurseRepository(PerformanceDbContext context) : base(context)
{ // {
} // }
} // }
} //}
...@@ -19,8 +19,8 @@ public class AgainAllotService : IAutoInjection ...@@ -19,8 +19,8 @@ public class AgainAllotService : IAutoInjection
private ConfigService configService; private ConfigService configService;
private PerforCofagainRepository perforCofagainRepository; private PerforCofagainRepository perforCofagainRepository;
private PerforPeragainallotRepository perforPeragainallotRepository; private PerforPeragainallotRepository perforPeragainallotRepository;
private PerforResaccountdoctorRepository perforResaccountdoctorRepository; private PerforResaccountRepository perforResaccountRepository;
private PerforResaccountnurseRepository perforResaccountnurseRepository; //private PerforResaccountnurseRepository perforResaccountnurseRepository;
private PerforUserRepository perforUserRepository; private PerforUserRepository perforUserRepository;
private PerforUserhospitalRepository perforUserhospitalRepository; private PerforUserhospitalRepository perforUserhospitalRepository;
private PerforPerallotRepository perforPerallotRepository; private PerforPerallotRepository perforPerallotRepository;
...@@ -34,8 +34,8 @@ public class AgainAllotService : IAutoInjection ...@@ -34,8 +34,8 @@ public class AgainAllotService : IAutoInjection
RoleService roleService, RoleService roleService,
PerforCofagainRepository perforCofagainRepository, PerforCofagainRepository perforCofagainRepository,
PerforPeragainallotRepository perforPeragainallotRepository, PerforPeragainallotRepository perforPeragainallotRepository,
PerforResaccountdoctorRepository perforResaccountdoctorRepository, PerforResaccountRepository perforResaccountRepository,
PerforResaccountnurseRepository perforResaccountnurseRepository, //PerforResaccountnurseRepository perforResaccountnurseRepository,
PerforUserRepository perforUserRepository, PerforUserRepository perforUserRepository,
PerforUserhospitalRepository perforUserhospitalRepository, PerforUserhospitalRepository perforUserhospitalRepository,
PerforPerallotRepository perforPerallotRepository, PerforPerallotRepository perforPerallotRepository,
...@@ -50,8 +50,8 @@ public class AgainAllotService : IAutoInjection ...@@ -50,8 +50,8 @@ public class AgainAllotService : IAutoInjection
this.roleService = roleService; this.roleService = roleService;
this.perforCofagainRepository = perforCofagainRepository; this.perforCofagainRepository = perforCofagainRepository;
this.perforPeragainallotRepository = perforPeragainallotRepository; this.perforPeragainallotRepository = perforPeragainallotRepository;
this.perforResaccountdoctorRepository = perforResaccountdoctorRepository; this.perforResaccountRepository = perforResaccountRepository;
this.perforResaccountnurseRepository = perforResaccountnurseRepository; //this.perforResaccountnurseRepository = perforResaccountnurseRepository;
this.perforUserRepository = perforUserRepository; this.perforUserRepository = perforUserRepository;
this.perforUserhospitalRepository = perforUserhospitalRepository; this.perforUserhospitalRepository = perforUserhospitalRepository;
this.perforPerallotRepository = perforPerallotRepository; this.perforPerallotRepository = perforPerallotRepository;
...@@ -97,9 +97,9 @@ public bool Generate(AgainAllotRequest request, int userId, string department) ...@@ -97,9 +97,9 @@ public bool Generate(AgainAllotRequest request, int userId, string department)
if (role != null) if (role != null)
{ {
if (application.NurseRole == role.ID) if (application.NurseRole == role.ID)
basicnumber = perforResaccountnurseRepository.GetEntity(t => t.AllotID == againAllot.AllotID && t.AccountingUnit == department)?.RealGiveFee; basicnumber = perforResaccountRepository.GetEntity(t => t.UnitType == (int)UnitType.护理组 && t.AllotID == againAllot.AllotID && t.AccountingUnit == department)?.RealGiveFee;
else if (application.DirectorRole == role.ID) else if (application.DirectorRole == role.ID)
basicnumber = perforResaccountdoctorRepository.GetEntity(t => t.AllotID == againAllot.AllotID && t.AccountingUnit == department)?.RealGiveFee; basicnumber = perforResaccountRepository.GetEntity(t => t.UnitType != (int)UnitType.护理组 && t.AllotID == againAllot.AllotID && t.AccountingUnit == department)?.RealGiveFee;
} }
} }
#endregion #endregion
......
...@@ -110,43 +110,30 @@ public List<res_baiscnorm> ComputeOtherAvg(List<res_baiscnorm> baiscnormList, Li ...@@ -110,43 +110,30 @@ public List<res_baiscnorm> ComputeOtherAvg(List<res_baiscnorm> baiscnormList, Li
/// <returns></returns> /// <returns></returns>
public List<res_baiscnorm> DocterNurseBaiscnorm(List<res_baiscnorm> baiscnormList, List<im_accountbasic> accountbasicList, List<PerSheet> list) public List<res_baiscnorm> DocterNurseBaiscnorm(List<res_baiscnorm> baiscnormList, List<im_accountbasic> accountbasicList, List<PerSheet> list)
{ {
// 护士 var pairs = new[]
var sheetNurse = list.FirstOrDefault(t => t.SheetType == SheetType.ComputeNurseAccount); {
var perdataNurse = sheetNurse.PerData.Select(t => (PerDataAccountNurse)t); new { SheetType = SheetType.ComputeDoctorAccount, UnitType = UnitType.医生组, PerforType = PerforType.临床医生 },
perdataNurse = perdataNurse.GroupBy(t => t.AccountingUnit) new { SheetType = SheetType.ComputeDoctorAccount, UnitType = UnitType.医技组, PerforType = PerforType.医技医生 },
.Select(t => new PerDataAccountNurse new { SheetType = SheetType.ComputeNurseAccount, UnitType = UnitType.护理组, PerforType = PerforType.护士 },
{
AccountingUnit = t.Key,
Number = t.Sum(p => p.Number),
PerforTotal = t.Max(p => p.PerforTotal)
});
var baiscnormNurse = new res_baiscnorm
{
PositionName = EnumHelper.GetDescription(PerforType.护士),
TotelNumber = perdataNurse.Sum(t => t.Number),
TotelValue = perdataNurse.Sum(t => t.PerforTotal),
AvgValue = perdataNurse.Sum(t => t.PerforTotal) / perdataNurse.Sum(t => t.Number)
}; };
baiscnormList.Add(baiscnormNurse); foreach (var info in pairs)
{
// 医生 var sheet = list.FirstOrDefault(t => t.SheetType == info.SheetType);
var count = accountbasicList.Where(t => t.UnitType == (int)UnitType.医生组).Sum(t => t.DoctorNumber + t.DoctorDirectorNumber); var perData = sheet.PerData.Select(t => (PerDataAccountBaisc)t);
var sheetDocter = list.FirstOrDefault(t => t.SheetType == SheetType.ComputeDoctorAccount);
var perdataDocter = sheetDocter.PerData.Select(t => (PerDataAccountDoctor)t);
//剔除不同科室相同核算单元 //剔除不同科室相同核算单元
perdataDocter = perdataDocter.Where(t => t.UnitType == (int)UnitType.医生组).GroupBy(t => t.AccountingUnit) var groupData = perData.Where(t => t.UnitType == (int)info.UnitType)
.Select(t => new PerDataAccountDoctor { AccountingUnit = t.Key, PerforTotal = t.Max(p => p.PerforTotal) }); .GroupBy(t => t.AccountingUnit)
.Select(t => new { AccountingUnit = t.Key, Number = t.Sum(p => p.ManagerNumber + p.Number), PerforTotal = t.Max(p => p.PerforTotal) });
var baiscnormDocter = new res_baiscnorm var baiscnorm = new res_baiscnorm
{ {
PositionName = EnumHelper.GetDescription(PerforType.临床医生), PositionName = EnumHelper.GetDescription(info.PerforType),
TotelNumber = count, TotelNumber = groupData.Sum(t => t.Number),
TotelValue = perdataDocter.Sum(t => t.PerforTotal), TotelValue = groupData.Sum(t => t.PerforTotal),
AvgValue = perdataDocter.Sum(t => t.PerforTotal) / count AvgValue = groupData.Sum(t => t.PerforTotal) / groupData.Sum(t => t.Number)
}; };
baiscnormList.Add(baiscnormDocter); baiscnormList.Add(baiscnorm);
}
return baiscnormList; return baiscnormList;
} }
} }
......
...@@ -12,8 +12,8 @@ namespace Performance.Services ...@@ -12,8 +12,8 @@ namespace Performance.Services
{ {
public class ComputeService : IAutoInjection public class ComputeService : IAutoInjection
{ {
private readonly PerforResaccountdoctorRepository _perforResAccountdoctorRepository; private readonly PerforResaccountRepository perforResaccountRepository;
private readonly PerforResaccountnurseRepository _perforResAccountnurseRepository; //private readonly PerforResaccountnurseRepository _perforResAccountnurseRepository;
private readonly PerforPersheetRepository _perforPerSheetRepository; private readonly PerforPersheetRepository _perforPerSheetRepository;
private readonly PerforImdataRepository _perforImDataRepository; private readonly PerforImdataRepository _perforImDataRepository;
private readonly PerforRescomputeRepository _perforRescomputeRepository; private readonly PerforRescomputeRepository _perforRescomputeRepository;
...@@ -23,8 +23,8 @@ public class ComputeService : IAutoInjection ...@@ -23,8 +23,8 @@ public class ComputeService : IAutoInjection
private readonly PerforAgemployeeRepository _perforAgemployeeRepository; private readonly PerforAgemployeeRepository _perforAgemployeeRepository;
private readonly PerforResbaiscnormRepository perforResbaiscnormRepository; private readonly PerforResbaiscnormRepository perforResbaiscnormRepository;
public ComputeService(PerforResaccountdoctorRepository perforResAccountdoctorRepository, public ComputeService(PerforResaccountRepository perforResaccountRepository,
PerforResaccountnurseRepository perforResAccountnurseRepository, //PerforResaccountnurseRepository perforResAccountnurseRepository,
PerforPersheetRepository perforPerSheetRepository, PerforPersheetRepository perforPerSheetRepository,
PerforImdataRepository perforImDataRepository, PerforImdataRepository perforImDataRepository,
PerforRescomputeRepository perforRescomputeRepository, PerforRescomputeRepository perforRescomputeRepository,
...@@ -34,8 +34,8 @@ public class ComputeService : IAutoInjection ...@@ -34,8 +34,8 @@ public class ComputeService : IAutoInjection
PerforAgemployeeRepository perforAgemployeeRepository, PerforAgemployeeRepository perforAgemployeeRepository,
PerforResbaiscnormRepository perforResbaiscnormRepository) PerforResbaiscnormRepository perforResbaiscnormRepository)
{ {
this._perforResAccountdoctorRepository = perforResAccountdoctorRepository; this.perforResaccountRepository = perforResaccountRepository;
this._perforResAccountnurseRepository = perforResAccountnurseRepository; //this._perforResAccountnurseRepository = perforResAccountnurseRepository;
this._perforPerSheetRepository = perforPerSheetRepository; this._perforPerSheetRepository = perforPerSheetRepository;
this._perforImDataRepository = perforImDataRepository; this._perforImDataRepository = perforImDataRepository;
this._perforRescomputeRepository = perforRescomputeRepository; this._perforRescomputeRepository = perforRescomputeRepository;
...@@ -115,7 +115,7 @@ public List<res_specialunit> GetSpecial(int allotId) ...@@ -115,7 +115,7 @@ public List<res_specialunit> GetSpecial(int allotId)
/// <returns></returns> /// <returns></returns>
public List<DoctorResponse> GetDoctorPerformance(int allotId) public List<DoctorResponse> GetDoctorPerformance(int allotId)
{ {
var list = _perforResAccountdoctorRepository.GetEntities(t => t.AllotID == allotId)?.OrderByDescending(t => t.AccountingUnit); var list = perforResaccountRepository.GetEntities(t => t.UnitType != (int)UnitType.护理组 && t.AllotID == allotId)?.OrderByDescending(t => t.AccountingUnit);
List<DoctorResponse> doctor = Mapper.Map<List<DoctorResponse>>(list); List<DoctorResponse> doctor = Mapper.Map<List<DoctorResponse>>(list);
doctor?.ForEach(t => t.UnitName = "医生组"); doctor?.ForEach(t => t.UnitName = "医生组");
return doctor; return doctor;
...@@ -128,7 +128,7 @@ public List<DoctorResponse> GetDoctorPerformance(int allotId) ...@@ -128,7 +128,7 @@ public List<DoctorResponse> GetDoctorPerformance(int allotId)
/// <returns></returns> /// <returns></returns>
public List<NurseResponse> GetNursePerformance(int allotId) public List<NurseResponse> GetNursePerformance(int allotId)
{ {
var list = _perforResAccountnurseRepository.GetEntities(t => t.AllotID == allotId)?.OrderByDescending(t => t.AccountingUnit); var list = perforResaccountRepository.GetEntities(t => t.UnitType == (int)UnitType.护理组 && t.AllotID == allotId)?.OrderByDescending(t => t.AccountingUnit);
List<NurseResponse> nurse = Mapper.Map<List<NurseResponse>>(list); List<NurseResponse> nurse = Mapper.Map<List<NurseResponse>>(list);
nurse?.ForEach(t => t.UnitName = "护理组"); nurse?.ForEach(t => t.UnitName = "护理组");
return nurse; return nurse;
...@@ -145,13 +145,13 @@ public DeptDetailResponse GetDepartmentDetail(int allotId, string department, in ...@@ -145,13 +145,13 @@ public DeptDetailResponse GetDepartmentDetail(int allotId, string department, in
{ {
if (type == 1) if (type == 1)
{ {
var accountList = _perforResAccountdoctorRepository.GetEntities(t => t.AllotID == allotId && t.AccountingUnit == department); var accountList = perforResaccountRepository.GetEntities(t => t.UnitType != (int)UnitType.护理组 && t.AllotID == allotId && t.AccountingUnit == department);
if (accountList != null) if (accountList != null)
return GetDepartmentDetail(allotId, accountList.First().ID, type); return GetDepartmentDetail(allotId, accountList.First().ID, type);
} }
else if (type == 2) else if (type == 2)
{ {
var accountList = _perforResAccountnurseRepository.GetEntities(t => t.AllotID == allotId && t.AccountingUnit == department); var accountList = perforResaccountRepository.GetEntities(t => t.UnitType == (int)UnitType.护理组 && t.AllotID == allotId && t.AccountingUnit == department);
if (accountList != null) if (accountList != null)
return GetDepartmentDetail(allotId, accountList.First().ID, type); return GetDepartmentDetail(allotId, accountList.First().ID, type);
} }
...@@ -171,11 +171,11 @@ public DeptDetailResponse GetDepartmentDetail(int allotId, int accountId, int ty ...@@ -171,11 +171,11 @@ public DeptDetailResponse GetDepartmentDetail(int allotId, int accountId, int ty
var sheetList = _perforPerSheetRepository.GetEntities(t => t.AllotID == allotId); var sheetList = _perforPerSheetRepository.GetEntities(t => t.AllotID == allotId);
if (type == 1) if (type == 1)
{ {
var doctor = _perforResAccountdoctorRepository.GetEntity(t => t.AllotID == allotId && t.ID == accountId); var doctor = perforResaccountRepository.GetEntity(t => t.UnitType != (int)UnitType.护理组 && t.AllotID == allotId && t.ID == accountId);
DeptDetailResponse response = new DeptDetailResponse() DeptDetailResponse response = new DeptDetailResponse()
{ {
Pandect = Mapper.Map<PerDataAccount>(doctor), Pandect = Mapper.Map<PerDataAccountBaisc>(doctor),
Economic = new List<DeptDetail>(), Economic = new List<DeptDetail>(),
Workload = new List<DeptDetail>() Workload = new List<DeptDetail>()
}; };
...@@ -198,10 +198,10 @@ public DeptDetailResponse GetDepartmentDetail(int allotId, int accountId, int ty ...@@ -198,10 +198,10 @@ public DeptDetailResponse GetDepartmentDetail(int allotId, int accountId, int ty
} }
else if (type == 2) else if (type == 2)
{ {
var nurse = _perforResAccountnurseRepository.GetEntity(t => t.AllotID == allotId && t.ID == accountId); var nurse = perforResaccountRepository.GetEntity(t => t.UnitType == (int)UnitType.护理组 && t.AllotID == allotId && t.ID == accountId);
DeptDetailResponse response = new DeptDetailResponse() DeptDetailResponse response = new DeptDetailResponse()
{ {
Pandect = Mapper.Map<PerDataAccount>(nurse), Pandect = Mapper.Map<PerDataAccountBaisc>(nurse),
Economic = new List<DeptDetail>(), Economic = new List<DeptDetail>(),
Workload = new List<DeptDetail>() Workload = new List<DeptDetail>()
}; };
......
...@@ -18,20 +18,18 @@ public class ComputeDirector : IAutoInjection ...@@ -18,20 +18,18 @@ public class ComputeDirector : IAutoInjection
private readonly BaiscNormService baiscNormService; private readonly BaiscNormService baiscNormService;
private readonly PerforCofdirectorRepository perforCofdirectorRepository; private readonly PerforCofdirectorRepository perforCofdirectorRepository;
private readonly PerforCofworkyearRepository perforCofworkyearRepository; private readonly PerforCofworkyearRepository perforCofworkyearRepository;
private readonly PerforResaccountnurseRepository perforResAccountnurseRepository; private readonly PerforResaccountRepository perforResaccountRepository;
private readonly PerforResaccountdoctorRepository perforResAccountdoctorRepository; //private readonly PerforResaccountdoctorRepository perforResAccountdoctorRepository;
public ComputeDirector(BaiscNormService baiscNormService, public ComputeDirector(BaiscNormService baiscNormService,
PerforCofdirectorRepository perforCofdirectorRepository, PerforCofdirectorRepository perforCofdirectorRepository,
PerforCofworkyearRepository perforCofworkyearRepository, PerforCofworkyearRepository perforCofworkyearRepository,
PerforResaccountnurseRepository perforResAccountnurseRepository, PerforResaccountRepository perforResaccountRepository)
PerforResaccountdoctorRepository perforResAccountdoctorRepository)
{ {
this.baiscNormService = baiscNormService; this.baiscNormService = baiscNormService;
this.perforCofdirectorRepository = perforCofdirectorRepository; this.perforCofdirectorRepository = perforCofdirectorRepository;
this.perforCofworkyearRepository = perforCofworkyearRepository; this.perforCofworkyearRepository = perforCofworkyearRepository;
this.perforResAccountnurseRepository = perforResAccountnurseRepository; this.perforResaccountRepository = perforResaccountRepository;
this.perforResAccountdoctorRepository = perforResAccountdoctorRepository;
} }
#region 老版计算 #region 老版计算
...@@ -147,10 +145,8 @@ public List<ComputeResult> Compute(List<ComputeEmployee> empolyeeList, List<im_a ...@@ -147,10 +145,8 @@ public List<ComputeResult> Compute(List<ComputeEmployee> empolyeeList, List<im_a
new { AccountUnitType = AccountUnitType.临床科室, PerforType = PerforType.护士长, UnitType = UnitType.护理组 }, new { AccountUnitType = AccountUnitType.临床科室, PerforType = PerforType.护士长, UnitType = UnitType.护理组 },
new { AccountUnitType = AccountUnitType.医技科室, PerforType = PerforType.医技主任, UnitType = UnitType.医技组 }, new { AccountUnitType = AccountUnitType.医技科室, PerforType = PerforType.医技主任, UnitType = UnitType.医技组 },
}; };
//取出医生科室 //取出科室
var doctorList = perforResAccountdoctorRepository.GetEntities(t => t.AllotID == allot.ID); var dataList = perforResaccountRepository.GetEntities(t => t.AllotID == allot.ID);
//取出护士科室
var nurseList = perforResAccountnurseRepository.GetEntities(t => t.AllotID == allot.ID);
List<ComputeResult> computeList = new List<ComputeResult>(); List<ComputeResult> computeList = new List<ComputeResult>();
foreach (var accountbasic in accountbasicList) foreach (var accountbasic in accountbasicList)
...@@ -160,21 +156,11 @@ public List<ComputeResult> Compute(List<ComputeEmployee> empolyeeList, List<im_a ...@@ -160,21 +156,11 @@ public List<ComputeResult> Compute(List<ComputeEmployee> empolyeeList, List<im_a
if (!accountbasic.DoctorDirectorNumber.HasValue || accountbasic.DoctorDirectorNumber.Value == 0) if (!accountbasic.DoctorDirectorNumber.HasValue || accountbasic.DoctorDirectorNumber.Value == 0)
continue; continue;
//分别取出对应的 计算 人员 平均值等信息 //分别取出对应的 计算 人员 平均值等信息
decimal? number, perforTotal, avg; var resAccount = dataList.Where(t => t.UnitType == accountbasic.UnitType && t.AccountingUnit == accountbasic.DoctorAccountingUnit);
if (accountbasic.UnitType == (int)UnitType.护理组) var number = resAccount.OrderByDescending(t => t.ManagerNumber).Sum(t => t.ManagerNumber + t.Number);
{ var perforTotal = resAccount.Max(t => t.PerforTotal);
var resAccount = nurseList.Where(t => t.AccountingUnit == accountbasic.DoctorAccountingUnit); var avg = resAccount.Max(t => t.Avg);
number = resAccount.Max(t => t.Number);
perforTotal = resAccount.Max(t => t.PerforTotal);
avg = resAccount.Max(t => t.PerforTotal);
}
else
{
var resAccount = doctorList.Where(t => t.AccountingUnit == accountbasic.DoctorAccountingUnit);
number = resAccount.Max(t => t.Number);
perforTotal = resAccount.Max(t => t.PerforTotal);
avg = resAccount.Max(t => t.PerforTotal);
}
var basicRule = basicRuleList.FirstOrDefault(t => t.UnitType == (UnitType)accountbasic.UnitType); var basicRule = basicRuleList.FirstOrDefault(t => t.UnitType == (UnitType)accountbasic.UnitType);
var empolyee = empolyeeList.FirstOrDefault(t => var empolyee = empolyeeList.FirstOrDefault(t =>
t.AccountType == basicRule.AccountUnitType.ToString() t.AccountType == basicRule.AccountUnitType.ToString()
......
...@@ -15,22 +15,22 @@ public class ReportService : IAutoInjection ...@@ -15,22 +15,22 @@ public class ReportService : IAutoInjection
private PerforPerallotRepository perforPerallotRepository; private PerforPerallotRepository perforPerallotRepository;
private PerforResbaiscnormRepository perforResbaiscnormRepository; private PerforResbaiscnormRepository perforResbaiscnormRepository;
private PerforHospersonfeeRepository perforHospersonfeeRepository; private PerforHospersonfeeRepository perforHospersonfeeRepository;
private PerforResaccountdoctorRepository perforResaccountdoctorRepository; private PerforResaccountRepository perforResaccountRepository;
private PerforResaccountnurseRepository perforResaccountnurseRepository; //private PerforResaccountnurseRepository perforResaccountnurseRepository;
public ReportService(PerforReportRepository perforReportRepository, public ReportService(PerforReportRepository perforReportRepository,
PerforPerallotRepository perforPerallotRepository, PerforPerallotRepository perforPerallotRepository,
PerforResbaiscnormRepository perforResbaiscnormRepository, PerforResbaiscnormRepository perforResbaiscnormRepository,
PerforHospersonfeeRepository perforHospersonfeeRepository, PerforHospersonfeeRepository perforHospersonfeeRepository,
PerforResaccountdoctorRepository perforResaccountdoctorRepository, //PerforResaccountdoctorRepository perforResaccountdoctorRepository,
PerforResaccountnurseRepository perforResaccountnurseRepository) PerforResaccountRepository perforResaccountRepository)
{ {
this.perforReportRepository = perforReportRepository; this.perforReportRepository = perforReportRepository;
this.perforPerallotRepository = perforPerallotRepository; this.perforPerallotRepository = perforPerallotRepository;
this.perforResbaiscnormRepository = perforResbaiscnormRepository; this.perforResbaiscnormRepository = perforResbaiscnormRepository;
this.perforHospersonfeeRepository = perforHospersonfeeRepository; this.perforHospersonfeeRepository = perforHospersonfeeRepository;
this.perforResaccountdoctorRepository = perforResaccountdoctorRepository; this.perforResaccountRepository = perforResaccountRepository;
this.perforResaccountnurseRepository = perforResaccountnurseRepository; //this.perforResaccountnurseRepository = perforResaccountnurseRepository;
} }
/// <summary> /// <summary>
...@@ -102,11 +102,11 @@ public List<PerReport> DoctorAvg(int hospitalId, int isIndex) ...@@ -102,11 +102,11 @@ public List<PerReport> DoctorAvg(int hospitalId, int isIndex)
throw new PerformanceException("用户未创建绩效!"); throw new PerformanceException("用户未创建绩效!");
var result = new List<PerReport>(); var result = new List<PerReport>();
var doctorList = perforResaccountdoctorRepository.GetEntities(t => allotList.Select(a => a.ID).Contains(t.AllotID.Value)); var doctorList = perforResaccountRepository.GetEntities(t => t.UnitType != (int)UnitType.护理组 && allotList.Select(a => a.ID).Contains(t.AllotID.Value));
if (isIndex == 1) if (isIndex == 1)
{ {
var allot = allotList.OrderByDescending(t => t.Year).ThenByDescending(t => t.Month).FirstOrDefault(); var allot = allotList.OrderByDescending(t => t.Year).ThenByDescending(t => t.Month).FirstOrDefault();
doctorList = perforResaccountdoctorRepository.GetEntities(t => t.AllotID == allot.ID); doctorList = perforResaccountRepository.GetEntities(t => t.UnitType != (int)UnitType.护理组 && t.AllotID == allot.ID);
} }
if (doctorList == null) if (doctorList == null)
return result; return result;
...@@ -134,11 +134,11 @@ public List<PerReport> NurseAvg(int hospitalId, int isIndex) ...@@ -134,11 +134,11 @@ public List<PerReport> NurseAvg(int hospitalId, int isIndex)
throw new PerformanceException("用户未创建绩效!"); throw new PerformanceException("用户未创建绩效!");
var result = new List<PerReport>(); var result = new List<PerReport>();
var doctorList = perforResaccountnurseRepository.GetEntities(t => allotList.Select(a => a.ID).Contains(t.AllotID.Value)); var doctorList = perforResaccountRepository.GetEntities(t => t.UnitType == (int)UnitType.护理组 && allotList.Select(a => a.ID).Contains(t.AllotID.Value));
if (isIndex == 1) if (isIndex == 1)
{ {
var allot = allotList.OrderByDescending(t => t.Year).ThenByDescending(t => t.Month).FirstOrDefault(); var allot = allotList.OrderByDescending(t => t.Year).ThenByDescending(t => t.Month).FirstOrDefault();
doctorList = perforResaccountnurseRepository.GetEntities(t => t.AllotID == allot.ID); doctorList = perforResaccountRepository.GetEntities(t => t.UnitType == (int)UnitType.护理组 && t.AllotID == allot.ID);
} }
if (doctorList == null) if (doctorList == null)
return result; return result;
......
...@@ -21,8 +21,8 @@ public class SheetSevice : IAutoInjection ...@@ -21,8 +21,8 @@ public class SheetSevice : IAutoInjection
private PerforImheaderRepository _perforImHeaderRepository; private PerforImheaderRepository _perforImHeaderRepository;
private PerforImemployeeRepository _perforImEmployeeRepository; private PerforImemployeeRepository _perforImEmployeeRepository;
private PerforImaccountbasicRepository _perforImaccountbasicRepository; private PerforImaccountbasicRepository _perforImaccountbasicRepository;
private PerforResaccountdoctorRepository _perforImaccountdoctorRepository; private PerforResaccountRepository _perforResaccountRepository;
private PerforResaccountnurseRepository _perforImaccountnurseRepository; //private PerforResaccountnurseRepository _perforImaccountnurseRepository;
private PerforImspecialunitRepository _perforImspecialunitRepository; private PerforImspecialunitRepository _perforImspecialunitRepository;
public SheetSevice(PerforPerallotRepository perforAllotRepository, public SheetSevice(PerforPerallotRepository perforAllotRepository,
...@@ -31,8 +31,8 @@ public class SheetSevice : IAutoInjection ...@@ -31,8 +31,8 @@ public class SheetSevice : IAutoInjection
PerforImheaderRepository perforImHeaderRepository, PerforImheaderRepository perforImHeaderRepository,
PerforImemployeeRepository perforImEmployeeRepository, PerforImemployeeRepository perforImEmployeeRepository,
PerforImaccountbasicRepository perforImaccountbasicRepository, PerforImaccountbasicRepository perforImaccountbasicRepository,
PerforResaccountdoctorRepository perforImaccountdoctorRepository, PerforResaccountRepository perforResaccountRepository,
PerforResaccountnurseRepository perforImaccountnurseRepository, //PerforResaccountnurseRepository perforImaccountnurseRepository,
PerforImspecialunitRepository perforImspecialunitRepository) PerforImspecialunitRepository perforImspecialunitRepository)
{ {
_perforAllotRepository = perforAllotRepository; _perforAllotRepository = perforAllotRepository;
...@@ -40,8 +40,8 @@ public class SheetSevice : IAutoInjection ...@@ -40,8 +40,8 @@ public class SheetSevice : IAutoInjection
_perforImDataRepository = perforImDataRepository; _perforImDataRepository = perforImDataRepository;
_perforImHeaderRepository = perforImHeaderRepository; _perforImHeaderRepository = perforImHeaderRepository;
_perforImEmployeeRepository = perforImEmployeeRepository; _perforImEmployeeRepository = perforImEmployeeRepository;
_perforImaccountdoctorRepository = perforImaccountdoctorRepository; _perforResaccountRepository = perforResaccountRepository;
_perforImaccountnurseRepository = perforImaccountnurseRepository; //_perforImaccountnurseRepository = perforImaccountnurseRepository;
_perforImaccountbasicRepository = perforImaccountbasicRepository; _perforImaccountbasicRepository = perforImaccountbasicRepository;
_perforImspecialunitRepository = perforImspecialunitRepository; _perforImspecialunitRepository = perforImspecialunitRepository;
} }
...@@ -246,7 +246,7 @@ private void CommonExport(int sheetID, SheetExportResponse response) ...@@ -246,7 +246,7 @@ private void CommonExport(int sheetID, SheetExportResponse response)
private void AccountNurseExport(int sheetID, SheetExportResponse response) private void AccountNurseExport(int sheetID, SheetExportResponse response)
{ {
var list = _perforImaccountnurseRepository.GetEntities(t => t.SheetID == sheetID)?.OrderByDescending(t => t.AccountingUnit); var list = _perforResaccountRepository.GetEntities(t => t.UnitType == (int)UnitType.护理组 && t.SheetID == sheetID)?.OrderByDescending(t => t.AccountingUnit);
if (list != null && list.Count() > 0) if (list != null && list.Count() > 0)
{ {
...@@ -294,7 +294,7 @@ private void AccountNurseExport(int sheetID, SheetExportResponse response) ...@@ -294,7 +294,7 @@ private void AccountNurseExport(int sheetID, SheetExportResponse response)
private void AccountDoctorExport(int sheetID, SheetExportResponse response) private void AccountDoctorExport(int sheetID, SheetExportResponse response)
{ {
var list = _perforImaccountdoctorRepository.GetEntities(t => t.SheetID == sheetID)?.OrderByDescending(t => t.AccountingUnit); var list = _perforResaccountRepository.GetEntities(t => t.UnitType != (int)UnitType.护理组 && t.SheetID == sheetID)?.OrderByDescending(t => t.AccountingUnit);
if (list != null && list.Count() > 0) if (list != null && list.Count() > 0)
{ {
......
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