Commit 0cb685da by lcx

Merge branch 'develop' into feature/划拨

parents 5160e0cc ceb0691e
......@@ -10,7 +10,7 @@
<PackageReference Include="MySql.Data" Version="8.0.15" />
<PackageReference Include="MySql.Data.EntityFrameworkCore" Version="8.0.15" />
<PackageReference Include="Oracle.ManagedDataAccess.Core" Version="2.19.60" />
<PackageReference Include="Z.EntityFramework.Extensions.EFCore" Version="2.8.20" />
<PackageReference Include="Z.EntityFramework.Extensions.EFCore" Version="2.8.40" />
</ItemGroup>
<ItemGroup>
......
......@@ -653,7 +653,7 @@ public List<cof_accounting> GetAccountingList(AccoungingRequest request)
}
if (request.Type == (int)AccountTypeEnum.AccountingUnit && !string.IsNullOrEmpty(request.UnitType))
exp = exp.And(t => t.UnitType == request.UnitType);
exp = exp.And(t => t.UnitType.Replace("行政后勤", "行政工勤") == request.UnitType.Replace("行政后勤", "行政工勤"));
return cofaccountingRepository.GetEntities(exp) ?? new List<cof_accounting>();
}
......
......@@ -762,8 +762,6 @@ public string Judge(int allotId, int hospitalId, int useTemplate, ref bool isSin
var hosConfig = hospitalconfigRepository.GetEntities(t => scriptConfig.Contains(t.Id));
if (hosConfig == null) return null;
Dictionary<string, object> paramtemers = new Dictionary<string, object>();
StringBuilder stringBuilder = new StringBuilder();
List<string> deparmants = new List<string>();
List<string> drugs = new List<string>();
List<per_dept_dic> deptList = new List<per_dept_dic>();
......@@ -820,21 +818,27 @@ public string Judge(int allotId, int hospitalId, int useTemplate, ref bool isSin
}
}
bool hasErrors = false;
Dictionary<string, object> paramtemers = new Dictionary<string, object>();
StringBuilder stringBuilder = new StringBuilder();
if (deparmants != null && deparmants.Any())
{
var distinctedDept = deptList.ToDistinct().ToList();
distinctedDept.ForEach(t => t.CreateTime = DateTime.Now); //在去重前添加时间,可能造成时间不一致,无法去重
perdeptdicRepository.AddRange(distinctedDept.ToArray());
stringBuilder.AppendLine($"新增科室:{string.Join(",", deparmants.Distinct())}");
hasErrors = true;
}
if (drugs != null && drugs.Any())
{
cofdrugtypeRepository.AddRange(drugTypeList.ToDistinct().ToArray());
stringBuilder.AppendLine($"新增费用类型:{string.Join(",", drugs.Distinct())}");
hasErrors = true;
}
paramtemers.Add("新增科室或费用类型", stringBuilder.ToString());
if (hasErrors)
paramtemers.Add("新增科室或费用类型", stringBuilder.ToString());
return paramtemers;
}
......
......@@ -927,7 +927,7 @@ private void DeptDicList(int HospitalId, List<per_dept_dic> deptDics, DeptdicHan
{ nameof(DeptdicResponse.InpatDoctorAccounting), "住院·核算单元医生组" },
{ nameof(DeptdicResponse.InpatNurseAccounting), "住院·核算单元护理组" },
{ nameof(DeptdicResponse.InpatTechnicAccounting), "住院·核算单元医技组" },
{ nameof(DeptdicResponse.LogisticsAccounting), "行政勤" },
{ nameof(DeptdicResponse.LogisticsAccounting), "行政勤" },
{ nameof(DeptdicResponse.SpecialAccounting), "特殊核算组" }
};
......
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