领导带班下井记录子表必填

This commit is contained in:
何美荣 2026-05-25 09:26:17 +08:00
parent e5db67475e
commit 7a3a92ee03

View File

@ -271,9 +271,13 @@ namespace APT.FO.WebApi.Controllers
{
throw new Exception("接班人不能为空");
}
if (!details.Any())
if (detailList!=null && detailList.Any())
{
throw new Exception("明细行至少填写一行,且现场责任人不能为空");
}
else
{
throw new Exception("明细行至少填写一行");
}
var allUsers = this.GetEntities<T_FM_USER>(t => t.ENABLE_STATUS == 0 && !t.CODE.Contains("admin"), new BaseFilter(entity.ORG_ID));
var sendUserIds = userList.Where(t => t.USER_ID != loginUserId && t.USER_ID != null).Select(m => (Guid)m.USER_ID).Distinct().ToList();