From 97e5b8abc38d65e789182fd32660f0b5dbe4411a Mon Sep 17 00:00:00 2001 From: waruneeauy Date: Thu, 2 Apr 2026 18:14:10 +0700 Subject: [PATCH] fix bug --- src/controllers/UserController.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/controllers/UserController.ts b/src/controllers/UserController.ts index a3384f78..afc686e6 100644 --- a/src/controllers/UserController.ts +++ b/src/controllers/UserController.ts @@ -572,8 +572,8 @@ export class KeycloakController extends Controller { .leftJoinAndSelect("current_holders.orgChild2", "orgChild2") .leftJoinAndSelect("current_holders.orgChild3", "orgChild3") .leftJoinAndSelect("current_holders.orgChild4", "orgChild4") - // .where("profile.keycloak IS NOT NULL AND profile.keycloak != ''") - .where("profile.isDelete = :isDelete", { isDelete: false }) + .where("profile.keycloak IS NOT NULL AND profile.keycloak != ''") + .andWhere("profile.isDelete = :isDelete", { isDelete: false }) .andWhere(checkChildFromRole) .andWhere(conditions) .andWhere( @@ -616,8 +616,8 @@ export class KeycloakController extends Controller { .leftJoinAndSelect("current_holders.orgChild2", "orgChild2") .leftJoinAndSelect("current_holders.orgChild3", "orgChild3") .leftJoinAndSelect("current_holders.orgChild4", "orgChild4") - // .where("profileEmployee.keycloak IS NOT NULL AND profileEmployee.keycloak != ''") - .where("profileEmployee.isDelete = :isDelete", { isDelete: false }) + .where("profileEmployee.keycloak IS NOT NULL AND profileEmployee.keycloak != ''") + .andWhere("profileEmployee.isDelete = :isDelete", { isDelete: false }) .andWhere(checkChildFromRole) .andWhere(conditions) .andWhere({ employeeClass: "PERM" })