From 4e58f20ba3c104b80c66f3b76741551ea8a1b356 Mon Sep 17 00:00:00 2001 From: ValdiANS Date: Mon, 4 May 2026 14:15:57 +0700 Subject: [PATCH 1/2] fix: set timeout to 1 minute --- src/services/http/client.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/services/http/client.ts b/src/services/http/client.ts index c9fbfe2c..64bf9680 100644 --- a/src/services/http/client.ts +++ b/src/services/http/client.ts @@ -5,7 +5,7 @@ import { RequestOptions } from '@/services/http/base'; import { redirectToSSO } from '@/lib/auth-helper'; const BASE_URL = process.env.NEXT_PUBLIC_API_BASE_URL ?? ''; -const axiosClient = axios.create({ baseURL: BASE_URL, timeout: 30_000 }); +const axiosClient = axios.create({ baseURL: BASE_URL, timeout: 60_000 }); axiosClient.interceptors.response.use( (response) => response, @@ -38,7 +38,7 @@ export async function httpClient( method: opts.method ?? 'GET', params: opts.query, data: opts.body, - timeout: opts.timeoutMs ?? 30_000, + timeout: opts.timeoutMs ?? 60_000, withCredentials: isCookieAuth && !isBearerAuth, responseType: opts.responseType, headers: { From a5f1a6ea75c5c9b15d93da2bca364a797f2696f7 Mon Sep 17 00:00:00 2001 From: ValdiANS Date: Mon, 4 May 2026 14:19:14 +0700 Subject: [PATCH 2/2] fix: order select input options in ascending manner --- .../components/pages/dashboard/Dashboard.tsx | 5 ++- .../ListDailyChecklistContent.tsx | 5 ++- .../employee/MasterEmployeeContent.tsx | 5 ++- .../kandang/MasterKandangContent.tsx | 10 ++++-- .../reports/DailyChecklistReportsContent.tsx | 36 +++++++++++++------ 5 files changed, 45 insertions(+), 16 deletions(-) diff --git a/src/figma-make/components/pages/dashboard/Dashboard.tsx b/src/figma-make/components/pages/dashboard/Dashboard.tsx index 36b04cf6..3cf8a9b7 100644 --- a/src/figma-make/components/pages/dashboard/Dashboard.tsx +++ b/src/figma-make/components/pages/dashboard/Dashboard.tsx @@ -89,7 +89,10 @@ export function Dashboard() { options: kandangOptions, loadMore: loadMoreKandang, isLoadingMore: isLoadingMoreKandang, - } = useSelect(DailyChecklistKandangApi.basePath, 'id', 'name'); + } = useSelect(DailyChecklistKandangApi.basePath, 'id', 'name', 'search', { + order_by: 'asc', + sort_by: 'name', + }); const handleKandangScroll = (e: React.UIEvent) => { const target = e.target as HTMLDivElement; diff --git a/src/figma-make/components/pages/list-daily-checklist/ListDailyChecklistContent.tsx b/src/figma-make/components/pages/list-daily-checklist/ListDailyChecklistContent.tsx index ae00d17a..64f716c1 100644 --- a/src/figma-make/components/pages/list-daily-checklist/ListDailyChecklistContent.tsx +++ b/src/figma-make/components/pages/list-daily-checklist/ListDailyChecklistContent.tsx @@ -110,7 +110,10 @@ export function ListDailyChecklistContent() { options: kandangOptions, isLoadingMore: isLoadingMoreKandang, loadMore: loadMoreKandang, - } = useSelect(DailyChecklistKandangApi.basePath, 'id', 'name'); + } = useSelect(DailyChecklistKandangApi.basePath, 'id', 'name', 'search', { + order_by: 'asc', + sort_by: 'name', + }); const checklistList = isResponseSuccess(checklistListRes) ? checklistListRes.data || [] diff --git a/src/figma-make/components/pages/master-data/employee/MasterEmployeeContent.tsx b/src/figma-make/components/pages/master-data/employee/MasterEmployeeContent.tsx index 37c81057..572317e0 100644 --- a/src/figma-make/components/pages/master-data/employee/MasterEmployeeContent.tsx +++ b/src/figma-make/components/pages/master-data/employee/MasterEmployeeContent.tsx @@ -96,7 +96,10 @@ export function MasterEmployeeContent() { options: kandangOptions, loadMore: loadMoreKandang, isLoadingMore: isLoadingMoreKandang, - } = useSelect(DailyChecklistKandangApi.basePath, 'id', 'name'); + } = useSelect(DailyChecklistKandangApi.basePath, 'id', 'name', 'search', { + order_by: 'asc', + sort_by: 'name', + }); const handleKandangScroll = (e: React.UIEvent) => { const target = e.target as HTMLDivElement; diff --git a/src/figma-make/components/pages/master-data/kandang/MasterKandangContent.tsx b/src/figma-make/components/pages/master-data/kandang/MasterKandangContent.tsx index 33de94e4..da733edb 100644 --- a/src/figma-make/components/pages/master-data/kandang/MasterKandangContent.tsx +++ b/src/figma-make/components/pages/master-data/kandang/MasterKandangContent.tsx @@ -368,7 +368,9 @@ export function MasterKandangContent() { name='search' placeholder='Cari kandang...' value={tableFilterState.search} - onChange={(e) => updateFilter('search', e.target.value)} + onChange={(e) => + updateFilter('search', e.target.value, true) + } className={{ wrapper: 'w-full sm:w-[280px] border-gray-200', inputWrapper: 'px-3 py-2 h-fit rounded-md', @@ -383,7 +385,11 @@ export function MasterKandangContent() {