Commit 1e701386 by wyc

其他收入(1.0.1 额外收入) -如果不填就赋空

parent d5087a73
......@@ -2,6 +2,7 @@
using System.Collections.Generic;
using System.Linq;
using NPOI.SS.UserModel;
using NPOI.XWPF.UserModel;
using Performance.DtoModels;
using Performance.Infrastructure;
......@@ -70,6 +71,7 @@ public List<IPerData> ReadData(ISheet sheet, List<PerHeader> perHeader)
var cellValue = ConvertHelper.ToDecimalOrNull(row.GetCell(athead.PointCell).GetValue());
if (!cellValue.HasValue || cellValue.Value == 0)
continue;
var cell = sheet.GetRow(unit.FactorRow.Value)?.GetCell(athead.PointCell);
PerData data = new PerData
{
RowNumber = r,
......@@ -80,7 +82,8 @@ public List<IPerData> ReadData(ISheet sheet, List<PerHeader> perHeader)
CellValue = cellValue,
//Annotation = row.GetCell(athead.PointCell)?.CellComment?.String?.String,
UnitType = unit.UnitType, //手动匹配
FactorValue = ConvertHelper.ToDecimalOrNull(sheet.GetRow(unit.FactorRow.Value).GetCell(athead.PointCell)?.NumericCellValue),
//FactorValue = ConvertHelper.ToDecimalOrNull(sheet.GetRow(unit.FactorRow.Value).GetCell(athead.PointCell)?.NumericCellValue),
FactorValue = !string.IsNullOrEmpty(cell.GetValue()) ? ConvertHelper.ToDecimalOrNull(cell?.NumericCellValue) : null,
IsFactor = true,
};
if (string.IsNullOrEmpty(data.AccountingUnit) && string.IsNullOrEmpty(data.Department))
......
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