diff --git a/APT.MicroApi/APT.FO.WebApi/Controllers/LeaderWellRecordController.cs b/APT.MicroApi/APT.FO.WebApi/Controllers/LeaderWellRecordController.cs index 905a28f..5d6e231 100644 --- a/APT.MicroApi/APT.FO.WebApi/Controllers/LeaderWellRecordController.cs +++ b/APT.MicroApi/APT.FO.WebApi/Controllers/LeaderWellRecordController.cs @@ -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 => 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();