only send employee with unique IDs when getting list

This commit is contained in:
ashutosh.nehete 2025-09-08 14:49:14 +05:30
parent d507b9ede2
commit 365439b2de

View File

@ -148,6 +148,8 @@ namespace MarcoBMS.Services.Controllers
.Distinct()
.ToListAsync();
employeeIds = employeeIds.Distinct().ToList();
result = await _context.Employees
.Include(fp => fp.JobRole)
.Where(e => employeeIds.Contains(e.Id) && e.IsActive)