This commit is contained in:
2025-09-17 11:05:54 +08:00
parent 273dc4e487
commit 5b8d3f2181
9 changed files with 1125 additions and 1821 deletions
@@ -933,7 +933,7 @@ namespace FineUIPro.Web.CQMS.ManageReportNew
}
}
numberIndex = 1;
int? num1 = 0, num2 = 0;
int? num1 = 0, num2 = 0, num3 = 0, num4 = 0;
foreach (var item in pqrList)
{
//创建行
@@ -942,10 +942,14 @@ namespace FineUIPro.Web.CQMS.ManageReportNew
row.Cells.Add(CreateCell(item.UnitOrMajor, doc, table.FirstRow.Cells[1].CellFormat.Width, "", "", "unit"));
row.Cells.Add(CreateCell(item.Quantity1.ToString(), doc, table.FirstRow.Cells[2].CellFormat.Width));
row.Cells.Add(CreateCell(item.Quantity2.ToString(), doc, table.FirstRow.Cells[3].CellFormat.Width));
row.Cells.Add(CreateCell(item.Remarks, doc, table.FirstRow.Cells[4].CellFormat.Width));
row.Cells.Add(CreateCell(item.Quantity3.ToString(), doc, table.FirstRow.Cells[4].CellFormat.Width));
row.Cells.Add(CreateCell(item.Quantity4.ToString(), doc, table.FirstRow.Cells[5].CellFormat.Width));
row.Cells.Add(CreateCell(item.Remarks, doc, table.FirstRow.Cells[6].CellFormat.Width));
table.Rows.Insert(numberIndex, row);
num1 += item.Quantity1;
num2 += item.Quantity2;
num3 += item.Quantity3;
num4 += item.Quantity4;
numberIndex += 1;
}
//自动设置表格样式
@@ -957,7 +961,9 @@ namespace FineUIPro.Web.CQMS.ManageReportNew
rowhj.Cells.Add(CreateCell("合计", doc, table.FirstRow.Cells[1].CellFormat.Width, "", "", "unit"));
rowhj.Cells.Add(CreateCell(num1.ToString(), doc, table.FirstRow.Cells[2].CellFormat.Width));
rowhj.Cells.Add(CreateCell(num2.ToString(), doc, table.FirstRow.Cells[3].CellFormat.Width));
rowhj.Cells.Add(CreateCell("", doc, table.FirstRow.Cells[4].CellFormat.Width));
rowhj.Cells.Add(CreateCell(num3.ToString(), doc, table.FirstRow.Cells[4].CellFormat.Width));
rowhj.Cells.Add(CreateCell(num4.ToString(), doc, table.FirstRow.Cells[5].CellFormat.Width));
rowhj.Cells.Add(CreateCell("", doc, table.FirstRow.Cells[6].CellFormat.Width));
table.Rows.Insert(numberIndex, rowhj);
//自动设置表格样式