add hr report

This commit is contained in:
kamonwan taengsuk
2022-12-11 12:26:57 +07:00
parent 31a036e637
commit f56408a9b2
4 changed files with 332 additions and 22 deletions

View File

@@ -199,8 +199,8 @@ namespace rmutr_report.Controllers
ws.Cell(row, 8).Value = teaching.number_of_weeks2;
ws.Cell(row, 9).Value = teaching.amount2;
ws.Cell(row, 10).Value = teaching.total_amount;
ws.Cell(row, 11).Value = teaching.major;
//ws.Cell(row, 11).Value = teaching.major;
ws.Range(ws.Cell(row, 11), ws.Cell(row2, 11)).Merge().Value = teaching.major;
ws.Range(ws.Cell(row, 2), ws.Cell(row, 11)).Style.Font.FontName =
"TH SarabunPSK";
ws.Range(ws.Cell(row, 2), ws.Cell(row, 11)).Style.Font.FontSize = 16;
@@ -273,8 +273,10 @@ namespace rmutr_report.Controllers
//row++;
if (datadetail.teacher == "รวมทั้งสิ้น")
{
ws.Cell(row2, 2).Value = datadetail.teacher;
ws.Cell(row2, 3).Value = datadetail.teaching_rate;
//ws.Cell(row2, 2).Value = datadetail.teacher;
ws.Range(ws.Cell(row2, 2), ws.Cell(row2, 3)).Merge().Value = datadetail.teacher;
ws.Range(ws.Cell(row2, 2), ws.Cell(row2, 3)).Merge();
//ws.Cell(row2, 3).Value = datadetail.teaching_rate;
ws.Cell(row2, 4).Value = datadetail.number_of_hours1;
ws.Cell(row2, 5).Value = datadetail.number_of_weeks1;
ws.Cell(row2, 6).Value = datadetail.amount1;
@@ -294,7 +296,7 @@ namespace rmutr_report.Controllers
ws.Range(ws.Cell(row2, 2), ws.Cell(row2, 11)).Style.Border.RightBorder =
XLBorderStyleValues.Thin;
ws.Cell(row2, 2).Style.Alignment.Horizontal = XLAlignmentHorizontalValues.Center;
ws.Cell(row2, 3).Style.Alignment.Horizontal = XLAlignmentHorizontalValues.Center;
//ws.Cell(row2, 3).Style.Alignment.Horizontal = XLAlignmentHorizontalValues.Center;
ws.Cell(row2, 4).Style.Alignment.Horizontal = XLAlignmentHorizontalValues.Center;
ws.Cell(row2, 5).Style.Alignment.Horizontal = XLAlignmentHorizontalValues.Center;
ws.Cell(row2, 6).Style.Alignment.Horizontal = XLAlignmentHorizontalValues.Center;