Commit 512290f7 by lcx

抽取sql根据isenabled字段判断是否显示,特殊科室数量字段根据值判断是否填充样式

parent 5de67c14
...@@ -679,7 +679,7 @@ private void WriteSpecialUnit(ISheet sheet, IPerSheetDataRead sheetRead, List<sy ...@@ -679,7 +679,7 @@ private void WriteSpecialUnit(ISheet sheet, IPerSheetDataRead sheetRead, List<sy
var newCell = importRow.CreateCell(cellIndex); var newCell = importRow.CreateCell(cellIndex);
//newCell.SetCellValue(Verify(value)); //newCell.SetCellValue(Verify(value));
OutToExcelCell(newCell, value); OutToExcelCell(newCell, value);
if (dictionary.ContainsKey(cell.StringCellValue) || cell.StringCellValue == "数量") if (dictionary.ContainsKey(cell.StringCellValue) || (cell.StringCellValue == "数量" && !string.IsNullOrEmpty(value?.ToString())))
newCell.CellStyle = style; newCell.CellStyle = style;
cellIndex++; cellIndex++;
......
...@@ -49,7 +49,7 @@ public class ModExtractService : IAutoInjection ...@@ -49,7 +49,7 @@ public class ModExtractService : IAutoInjection
public List<TitleValue> ExtractScheme(int hospitalId, List<int> executeType) public List<TitleValue> ExtractScheme(int hospitalId, List<int> executeType)
{ {
var titlevalue = new List<TitleValue>(); var titlevalue = new List<TitleValue>();
var list = perforModextractRepository.GetEntities(t => (t.HospitalId == hospitalId || t.HospitalId == null) && executeType.Contains(t.ExecuteType.Value)); var list = perforModextractRepository.GetEntities(t => (t.HospitalId == hospitalId || t.HospitalId == null) && executeType.Contains(t.ExecuteType.Value) && t.IsEnable == 1);
if (list != null && list.Any()) if (list != null && list.Any())
titlevalue = list.OrderBy(t => t.EName).Select(t => new TitleValue { Title = string.IsNullOrEmpty(t.Description) ? t.EName : $"{t.EName}({t.Description})", Value = t.Id.ToString() }).OrderBy(t => t.Title).ToList(); titlevalue = list.OrderBy(t => t.EName).Select(t => new TitleValue { Title = string.IsNullOrEmpty(t.Description) ? t.EName : $"{t.EName}({t.Description})", Value = t.Id.ToString() }).OrderBy(t => t.Title).ToList();
......
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