20240701 修改NCR

This commit is contained in:
2024-07-01 14:09:40 +08:00
parent 4b4f52d903
commit 188c6bf3c3
14 changed files with 328 additions and 70 deletions
@@ -29,12 +29,13 @@ namespace FineUIPro.Web.Comprehensive
}
public void BindGrid()
{
string strSql = @"select NCRManagementId, ProjectId, SendUnit, NCRCode, Contents,Problem,Measure,IssuedDate, ReceiveUnit,Status,
ClosedDate, CompleteDate, ResponsibleMan, AttachUrl, ImplementationFrontState,
CompileMan, UnitWorkId,CN.ProfessionalName,C.CNProfessionalId,u.UnitName,C.RemarkCode
string strSql = @"select C.NCRManagementId, C.ProjectId, C.SendUnit, C.NCRCode, C.Contents,C.Problem,C.Measure,C.IssuedDate, C.ReceiveUnit,C.Status,
C.ClosedDate, C.CompleteDate, C.ResponsibleMan, C.AttachUrl, C.ImplementationFrontState,C.Supervisor,
C.CompileMan, C.UnitWorkId,CN.ProfessionalName,C.CNProfessionalId,u.UnitName,C.RemarkCode,su.UserName as SupervisorName
from Comprehensive_NCRManagement C
left join Base_CNProfessional CN on C.CNProfessionalId=CN.CNProfessionalId
left join Base_Unit u on u.UnitId = C.SendUnit
left join Sys_User su on su.UserId = C.Supervisor
where C.ProjectId = @ProjectId";
List<SqlParameter> listStr = new List<SqlParameter>();
listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId));
@@ -417,11 +418,16 @@ namespace FineUIPro.Web.Comprehensive
cell = row.CreateCell(3);
cell.CellStyle = cellStyle;
cell.SetCellValue(item.Contents);//主要内容
string unitWorkName = string.Empty;
if (!string.IsNullOrEmpty(item.UnitWorkId))
{
unitWorkName = ConvertUnitWork(item.UnitWorkId);
}
cell.SetCellValue(unitWorkName);//单位工程
cell = row.CreateCell(4);
cell.CellStyle = cellStyle;
cell.SetCellValue(item.IssuedDate.HasValue ? string.Format("{0:yyyy-MM-dd}", item.IssuedDate) : "");//下发日期
cell.SetCellValue(item.Contents);//主要内容
cell = row.CreateCell(5);
cell.CellStyle = cellStyle;
@@ -433,13 +439,8 @@ namespace FineUIPro.Web.Comprehensive
cell = row.CreateCell(7);
cell.CellStyle = cellStyle;
string unitWorkName = string.Empty;
if (!string.IsNullOrEmpty(item.UnitWorkId))
{
unitWorkName = ConvertUnitWork(item.UnitWorkId);
}
cell.SetCellValue(unitWorkName);//单位工程
cell.SetCellValue(item.IssuedDate.HasValue ? string.Format("{0:yyyy-MM-dd}", item.IssuedDate) : "");//下发日期
cell = row.CreateCell(8);
cell.CellStyle = cellStyle;
string receiveUnitName = string.Empty;
@@ -460,18 +461,27 @@ namespace FineUIPro.Web.Comprehensive
cell = row.CreateCell(10);
cell.CellStyle = cellStyle;
cell.SetCellValue(item.ResponsibleMan);//责任人
cell.SetCellValue(item.ClosedDate.HasValue ? string.Format("{0:yyyy-MM-dd}", item.ClosedDate) : "");//要求封闭日期
cell = row.CreateCell(11);
cell.CellStyle = cellStyle;
cell.SetCellValue(item.ClosedDate.HasValue ? string.Format("{0:yyyy-MM-dd}", item.ClosedDate) : "");//要求封闭日期
cell.SetCellValue(item.CompleteDate.HasValue ? string.Format("{0:yyyy-MM-dd}", item.CompleteDate) : "");//完成日期
cell = row.CreateCell(12);
cell.CellStyle = cellStyle;
cell.SetCellValue(item.CompleteDate.HasValue ? string.Format("{0:yyyy-MM-dd}", item.CompleteDate) : "");//完成日期
cell.SetCellValue(item.ResponsibleMan);//责任人
cell = row.CreateCell(13);
cell.CellStyle = cellStyle;
string supervisorName = string.Empty;
if (!string.IsNullOrEmpty(item.Supervisor))
{
supervisorName = BLL.UserService.GetUserNameByUserId(item.Supervisor);
}
cell.SetCellValue(supervisorName);//监督人
cell = row.CreateCell(14);
cell.CellStyle = cellStyle;
cell.SetCellValue(item.RemarkCode.HasValue ? item.RemarkCode.ToString() : "");//标志编号
i++;