From e0f37dda4a018d325f8d1aa26d89ae5b25cb0433 Mon Sep 17 00:00:00 2001 From: AdisakKanthawilang Date: Thu, 3 Oct 2024 15:20:33 +0700 Subject: [PATCH] =?UTF-8?q?fix=20=E0=B9=80=E0=B8=9E=E0=B8=B4=E0=B9=88?= =?UTF-8?q?=E0=B8=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/controllers/DevelopmentEmployeeHistoryController.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/controllers/DevelopmentEmployeeHistoryController.ts b/src/controllers/DevelopmentEmployeeHistoryController.ts index 8d25e7c..794a7d7 100644 --- a/src/controllers/DevelopmentEmployeeHistoryController.ts +++ b/src/controllers/DevelopmentEmployeeHistoryController.ts @@ -331,6 +331,14 @@ export class DevelopmentEmployeeHistoryController extends Controller { { keyword: `%${body.keyword}%`, }, + ) + .orWhere( + body.keyword != null && body.keyword != "" + ? "developmentHistory.citizenId LIKE :keyword" + : "1=1", + { + keyword: `%${body.keyword}%`, + }, ); }), )