Commit 47103830 by 钟博

发放表名字修改

parent 76217558
......@@ -54,7 +54,7 @@ public class DownloadService : IAutoInjection
/// <param name="allData"></param>
/// <param name="isAll"></param>
/// <returns></returns>
public string AllComputerReport(int allotId, List<ComputeResponse> allData, bool isAll)
public string AllComputerReport(int allotId, List<ComputeResponse> allData, bool isAll,string name)
{
var allot = perallotRepository.GetEntity(t => t.ID == allotId);
var hospital = perforHospital.GetEntity(t => t.ID == allot.HospitalId);
......@@ -81,7 +81,7 @@ public string AllComputerReport(int allotId, List<ComputeResponse> allData, bool
var dpath = Path.Combine(evn.ContentRootPath, "Files", "PerformanceRelease", $"{allot.HospitalId}");
FileHelper.CreateDirectory(dpath);
string fileName = $"{hospital.HosName}-全院绩效发放-{DateTime.Now:yyyyMMdd}";
string fileName = $"{hospital.HosName}-{name}-{DateTime.Now:yyyyMMdd}";
string filepath = Path.Combine(dpath, fileName);
FileStream stream = new FileStream(filepath, FileMode.Create);
try
......@@ -93,7 +93,7 @@ public string AllComputerReport(int allotId, List<ComputeResponse> allData, bool
style.BorderBottom = BorderStyle.Thin;
style.BorderRight = BorderStyle.Thin;
ISheet sheet = workbook.CreateSheet("全院绩效发放");
ISheet sheet = workbook.CreateSheet($"{name}");
sheet.ForceFormulaRecalculation = true;
ICellStyle cellStyle = workbook.CreateCellStyle();
cellStyle.DataFormat = HSSFDataFormat.GetBuiltinFormat("0.00");
......@@ -228,7 +228,7 @@ public string DeptReport(int allotId, List<DeptResponse> deptData)
FileStream stream = new FileStream(filepath, FileMode.Create);
try
{
XSSFWorkbook workbook = new HSSFWorkbook();
XSSFWorkbook workbook = new XSSFWorkbook();
//设置单元格样式
ICellStyle style = workbook.CreateCellStyle();
style.Alignment = HorizontalAlignment.Center;
......
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