检查清单BUG

This commit is contained in:
何美荣 2025-11-22 16:18:43 +08:00
parent 2670c3a18f
commit 2dc63f37c2

View File

@ -63,8 +63,9 @@ namespace APT.SK.WebApi.Controllers.Api
var checkUsers = entity.Nav_CheckUsers;
entity.Nav_CheckUsers = null;
List<Guid> detailIds = new List<Guid>();
//List<Guid> hiddenIds = new List<Guid>();
List<Guid> deleteCheckUserIds = new List<Guid>();
List<Guid> basicIds = new List<Guid>();
deleteCheckUserIds = this.GetEntities<T_SK_CHECK_SET_USER>(t => t.CHECK_SET_ID == entity.ID, new BaseFilter(entity.ORG_ID)).Select(t => t.ID).ToList();
detailIds = this.GetEntities<T_SK_CHECK_SET_CONTENTS>(t => t.CHECK_SET_ID == entity.ID, new BaseFilter(entity.ORG_ID)).Select(t => t.ID).ToList();
basicIds = this.GetEntities<T_SK_CHECK_SET_CONTENTS_BASIC>(t => detailIds.Contains(t.CHECK_CONTENTS_SET_ID), new BaseFilter(entity.ORG_ID)).Select(t => t.ID).ToList();
//hiddenIds = this.GetEntities<T_SK_CHECK_SET_CONTENTS_HIDDEN>(t => detailIds.Contains(t.CHECK_CONTENTS_SET_ID), new BaseFilter(entity.ORG_ID)).Select(t => t.ID).ToList();
@ -76,6 +77,7 @@ namespace APT.SK.WebApi.Controllers.Api
if (checkUsers != null && checkUsers.Any())
{
checkUsers = checkUsers.Where(t => !t.IS_DELETED).ToList();
checkUsers.ForEach(t => t.Nav_User = null);
}
if (details != null && details.Any())
{
@ -393,8 +395,8 @@ namespace APT.SK.WebApi.Controllers.Api
{
if (basicIds != null && basicIds.Any())
this.BantchDeleteEntityNoCommit<T_SK_CHECK_SET_CONTENTS_BASIC>(basicIds);
//if (hiddenIds != null && hiddenIds.Any())
// this.BantchDeleteEntityNoCommit<T_SK_CHECK_SET_CONTENTS_HIDDEN>(hiddenIds);
if (deleteCheckUserIds != null && deleteCheckUserIds.Any())
this.BantchDeleteEntityNoCommit<T_SK_CHECK_SET_USER>(deleteCheckUserIds);
if (detailIds != null && detailIds.Any())
this.BantchDeleteEntityNoCommit<T_SK_CHECK_SET_CONTENTS>(detailIds);
if (entity != null)