修改进度模块

This commit is contained in:
2023-08-01 17:28:03 +08:00
parent 947413323e
commit c13283b8e1
11 changed files with 427 additions and 55 deletions
@@ -972,7 +972,26 @@ namespace FineUIPro.Web.CQMS.Check
if (!string.IsNullOrEmpty(c.HGForms) || !string.IsNullOrEmpty(c.SHForms))
{
isExitForms = true;
break;
}
//处理工作包实际完成时间
if (c.CheckNum != null && c.CheckNum != 0) //检查次数为0表示一直检查
{
if (c.CheckNum == 1) //检查一次
{
c.RealEndDate = DateTime.Now;
BLL.ControlItemAndCycleService.UpdateControlItemAndCycle(c);
BLL.WorkPackageService.UpdateWorkPackageRealEndDate(c.WorkPackageId);
}
else //检查多次
{
List<Model.Check_SpotCheckDetail> details = BLL.SpotCheckDetailService.GetSpotCheckDetailsByControlItemAndCycleId(c.ControlItemAndCycleId);
if (details.Count == c.CheckNum) //检查次数已达到最大值
{
c.RealEndDate = DateTime.Now;
BLL.ControlItemAndCycleService.UpdateControlItemAndCycle(c);
BLL.WorkPackageService.UpdateWorkPackageRealEndDate(c.WorkPackageId);
}
}
}
}
}