From daa0b872601789815513508d48a14cbd8e1f6518 Mon Sep 17 00:00:00 2001 From: it-fixcomart Date: Mon, 23 Dec 2024 13:39:47 +0700 Subject: update pengajuan tempo --- src/lib/pengajuan-tempo/component/PengajuanTempo.jsx | 1 - src/lib/pengajuan-tempo/component/informasiPerusahaan.jsx | 8 +++++--- 2 files changed, 5 insertions(+), 4 deletions(-) (limited to 'src/lib/pengajuan-tempo') diff --git a/src/lib/pengajuan-tempo/component/PengajuanTempo.jsx b/src/lib/pengajuan-tempo/component/PengajuanTempo.jsx index 22227624..dbf2c606 100644 --- a/src/lib/pengajuan-tempo/component/PengajuanTempo.jsx +++ b/src/lib/pengajuan-tempo/component/PengajuanTempo.jsx @@ -550,7 +550,6 @@ const PengajuanTempo = () => { // if (isLoading && !bigData) { // return; // } - console.log('bigData', bigData); return ( <>
diff --git a/src/lib/pengajuan-tempo/component/informasiPerusahaan.jsx b/src/lib/pengajuan-tempo/component/informasiPerusahaan.jsx index 4bc04a3f..fc0f1c28 100644 --- a/src/lib/pengajuan-tempo/component/informasiPerusahaan.jsx +++ b/src/lib/pengajuan-tempo/component/informasiPerusahaan.jsx @@ -95,8 +95,6 @@ const InformasiPerusahaan = ({ useEffect(() => { if (watchCity) { - updateForm('city', `${watchCity}`); - validate(); const loadDistricts = async () => { let dataDistricts = await districtApi({ cityId: watchCity }); dataDistricts = dataDistricts.map((district) => ({ @@ -105,9 +103,13 @@ const InformasiPerusahaan = ({ })); setDistricts(dataDistricts); }; + if (form.city !== `${watchCity}`) { + updateForm('city', `${watchCity}`); + } + validate(); loadDistricts(); } - }, [watchCity, setValue]); + }, [watchCity]); const watchDistrict = watch('district'); useEffect(() => { -- cgit v1.2.3