From b30bd30280f945a7a22710dca3e638df2b9d6d07 Mon Sep 17 00:00:00 2001 From: mhawryluk Date: Thu, 15 Jan 2026 14:13:36 +0100 Subject: [PATCH 1/2] Fix time expense confirm page back button navigation when submitting from report details RHP --- src/pages/iou/request/step/IOURequestStepConfirmation.tsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/pages/iou/request/step/IOURequestStepConfirmation.tsx b/src/pages/iou/request/step/IOURequestStepConfirmation.tsx index 5e4be0eba26c9..9d56c9857b4dd 100644 --- a/src/pages/iou/request/step/IOURequestStepConfirmation.tsx +++ b/src/pages/iou/request/step/IOURequestStepConfirmation.tsx @@ -435,6 +435,11 @@ function IOURequestStepConfirmation({ return; } if (isTimeRequest) { + if (isMovingTransactionFromTrackExpense) { + return Navigation.goBack(ROUTES.MONEY_REQUEST_STEP_PARTICIPANTS.getRoute(iouType, initialTransactionID, transaction?.reportID ?? reportID, undefined, action), { + compareParams: false, + }); + } return Navigation.goBack(ROUTES.MONEY_REQUEST_CREATE_TAB_TIME.getRoute(action, iouType, initialTransactionID, reportID)); } From e445386b966bddfc4f2b75570930160bd4caf9ae Mon Sep 17 00:00:00 2001 From: mhawryluk Date: Fri, 16 Jan 2026 11:33:36 +0100 Subject: [PATCH 2/2] Remove checking if transaction is a time request in navigateBack in confirmation page --- src/libs/IOUUtils.ts | 3 +++ .../iou/request/step/IOURequestStepConfirmation.tsx | 9 --------- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/src/libs/IOUUtils.ts b/src/libs/IOUUtils.ts index 04d6f7baebf2c..7a3cfc99be989 100644 --- a/src/libs/IOUUtils.ts +++ b/src/libs/IOUUtils.ts @@ -38,6 +38,9 @@ function navigateToStartMoneyRequestStep(requestType: IOURequestType, iouType: I case CONST.IOU.REQUEST_TYPE.SCAN: Navigation.goBack(ROUTES.MONEY_REQUEST_CREATE_TAB_SCAN.getRoute(CONST.IOU.ACTION.CREATE, iouType, transactionID, reportID), {compareParams: false}); break; + case CONST.IOU.REQUEST_TYPE.TIME: + Navigation.goBack(ROUTES.MONEY_REQUEST_CREATE_TAB_TIME.getRoute(CONST.IOU.ACTION.CREATE, iouType, transactionID, reportID), {compareParams: false}); + break; default: Navigation.goBack(ROUTES.MONEY_REQUEST_CREATE_TAB_MANUAL.getRoute(CONST.IOU.ACTION.CREATE, iouType, transactionID, reportID), {compareParams: false}); break; diff --git a/src/pages/iou/request/step/IOURequestStepConfirmation.tsx b/src/pages/iou/request/step/IOURequestStepConfirmation.tsx index 9d56c9857b4dd..84144405a8233 100644 --- a/src/pages/iou/request/step/IOURequestStepConfirmation.tsx +++ b/src/pages/iou/request/step/IOURequestStepConfirmation.tsx @@ -434,14 +434,6 @@ function IOURequestStepConfirmation({ Navigation.goBack(ROUTES.MONEY_REQUEST_STEP_SUBRATE.getRoute(action, iouType, initialTransactionID, reportID)); return; } - if (isTimeRequest) { - if (isMovingTransactionFromTrackExpense) { - return Navigation.goBack(ROUTES.MONEY_REQUEST_STEP_PARTICIPANTS.getRoute(iouType, initialTransactionID, transaction?.reportID ?? reportID, undefined, action), { - compareParams: false, - }); - } - return Navigation.goBack(ROUTES.MONEY_REQUEST_CREATE_TAB_TIME.getRoute(action, iouType, initialTransactionID, reportID)); - } if (transaction?.isFromGlobalCreate && !transaction.receipt?.isTestReceipt) { // If the participants weren't automatically added to the transaction, then we should go back to the IOURequestStepParticipants. @@ -483,7 +475,6 @@ function IOURequestStepConfirmation({ isMovingTransactionFromTrackExpense, participantsAutoAssignedFromRoute, backTo, - isTimeRequest, ]); // When the component mounts, if there is a receipt, see if the image can be read from the disk. If not, redirect the user to the starting step of the flow.