diff --git a/src/controllers/ProfileEmployeeController.ts b/src/controllers/ProfileEmployeeController.ts index bf312ee6..e6d4e213 100644 --- a/src/controllers/ProfileEmployeeController.ts +++ b/src/controllers/ProfileEmployeeController.ts @@ -331,7 +331,7 @@ export class ProfileEmployeeController extends Controller { ) .andWhere( new Brackets((qb) => { - qb.where("profile.id NOT IN (:...ids)", { + qb.where("profileEmployee.id NOT IN (:...ids)", { ids: orgRevision.posMasters .filter((x) => x.next_holderId != null) .map((x) => x.next_holderId),