This commit is contained in:
何美荣 2026-05-09 15:56:56 +08:00
parent 8527a9f6b1
commit 53fc12b0fa

View File

@ -63,6 +63,7 @@ namespace APT.FO.WebApi.Controllers.Api.FO
List<T_FO_PRE_SHIFT_MEETING_RECORD_DETAIL_POST> postList = new List<T_FO_PRE_SHIFT_MEETING_RECORD_DETAIL_POST>();
var oldUserIds = GetEntities<T_FO_PRE_SHIFT_MEETING_RECORD_USER>(t => t.PRE_SHIFT_MEETING_RECORD_ID == entity.ID, new BaseFilter(entity.ORG_ID)).Select(m => m.ID).ToList();
var userID = APT.Infrastructure.Api.AppContext.CurrentSession.UserID;
var departId = APT.Infrastructure.Api.AppContext.CurrentSession.DepartmentID;
if (entity.TaskID != null && entity.TaskID != Guid.Empty)
{
var currTask = GetEntity<T_FM_NOTIFICATION_TASK>(t => t.ID == entity.TaskID);
@ -141,6 +142,7 @@ namespace APT.FO.WebApi.Controllers.Api.FO
{
throw new Exception("通知人员不能为空");
}
if (entity.DEPARTMENT_ID == null)
{
var user = GetEntity<T_FM_USER>(t => t.ID == userID);
@ -160,7 +162,7 @@ namespace APT.FO.WebApi.Controllers.Api.FO
}
else
{
var currTeam = GetEntity<T_FM_TEAM>(t => t.DEPARTMENT_ID == entity.DEPARTMENT_ID);
var currTeam = GetEntity<T_FM_TEAM>(t => t.DEPARTMENT_ID == departId);
entity.TEAM_ID = currTeam?.ID;
TeamName = currTeam?.NAME;
}