From 0bec7cc9dcd6601ef51dc07cda2a25cb37e76f2e Mon Sep 17 00:00:00 2001 From: truph01 Date: Thu, 5 Jun 2025 18:52:13 +0700 Subject: [PATCH 1/2] fix: disable keyboard avoiding view --- src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx b/src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx index c28289e40485..5cb96022f65b 100644 --- a/src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx +++ b/src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx @@ -53,6 +53,7 @@ function EditPerDiemCurrencyPage({route}: EditPerDiemCurrencyPageProps) { shouldBeBlocked={!policyID || !rateID || isEmptyObject(selectedRate)} > From d5adcb49c4fcf8e0b88915da6eb5c5a1c3b339da Mon Sep 17 00:00:00 2001 From: truph01 Date: Thu, 5 Jun 2025 22:58:36 +0700 Subject: [PATCH 2/2] fix: lint --- src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx b/src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx index 5cb96022f65b..0195dcb2c92a 100644 --- a/src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx +++ b/src/pages/workspace/perDiem/EditPerDiemCurrencyPage.tsx @@ -8,12 +8,12 @@ import ScreenWrapper from '@components/ScreenWrapper'; import Text from '@components/Text'; import useLocalize from '@hooks/useLocalize'; import useThemeStyles from '@hooks/useThemeStyles'; +import {editPerDiemRateCurrency} from '@libs/actions/Policy/PerDiem'; import Navigation from '@libs/Navigation/Navigation'; import type {PlatformStackScreenProps} from '@libs/Navigation/PlatformStackNavigation/types'; import {getPerDiemCustomUnit} from '@libs/PolicyUtils'; import type {SettingsNavigatorParamList} from '@navigation/types'; import AccessOrNotFoundWrapper from '@pages/workspace/AccessOrNotFoundWrapper'; -import * as PerDiem from '@userActions/Policy/PerDiem'; import CONST from '@src/CONST'; import ONYXKEYS from '@src/ONYXKEYS'; import ROUTES from '@src/ROUTES'; @@ -28,7 +28,7 @@ function EditPerDiemCurrencyPage({route}: EditPerDiemCurrencyPageProps) { const policyID = route.params.policyID; const rateID = route.params.rateID; const subRateID = route.params.subRateID; - const [policy] = useOnyx(`${ONYXKEYS.COLLECTION.POLICY}${policyID}`); + const [policy] = useOnyx(`${ONYXKEYS.COLLECTION.POLICY}${policyID}`, {canBeMissing: true}); const customUnit = getPerDiemCustomUnit(policy); @@ -38,7 +38,7 @@ function EditPerDiemCurrencyPage({route}: EditPerDiemCurrencyPageProps) { (item: CurrencyListItem) => { const newCurrency = item.currencyCode; if (newCurrency !== selectedRate?.currency) { - PerDiem.editPerDiemRateCurrency(policyID, rateID, customUnit, newCurrency); + editPerDiemRateCurrency(policyID, rateID, customUnit, newCurrency); } Navigation.goBack(ROUTES.WORKSPACE_PER_DIEM_DETAILS.getRoute(policyID, rateID, subRateID)); },