From ba4b58fefaf4416a0887711012a9b960103197c4 Mon Sep 17 00:00:00 2001 From: cretadn22 Date: Sun, 5 Jul 2026 22:14:05 +0700 Subject: [PATCH 1/2] Add chatReportActions to PerDiem expense handling --- src/libs/actions/IOU/Duplicate.ts | 1 + src/libs/actions/IOU/PerDiem.ts | 7 +- .../step/confirmation/useExpenseSubmission.ts | 1 + tests/actions/IOU/PerDiemTest.ts | 94 ++++++++++++++++++- 4 files changed, 101 insertions(+), 2 deletions(-) diff --git a/src/libs/actions/IOU/Duplicate.ts b/src/libs/actions/IOU/Duplicate.ts index b6bd96417ec6..f87de3130d53 100644 --- a/src/libs/actions/IOU/Duplicate.ts +++ b/src/libs/actions/IOU/Duplicate.ts @@ -727,6 +727,7 @@ function createExpenseByType({ }, hasViolations: false, customUnitPolicyID, + chatReportActions: undefined, }; return submitPerDiemExpense(perDiemParams); } diff --git a/src/libs/actions/IOU/PerDiem.ts b/src/libs/actions/IOU/PerDiem.ts index c7bca2242de7..80d191240f9b 100644 --- a/src/libs/actions/IOU/PerDiem.ts +++ b/src/libs/actions/IOU/PerDiem.ts @@ -240,6 +240,7 @@ type PerDiemExpenseInformation = { shouldDeferAutoSubmit?: boolean; optimisticChatReportID?: string; optimisticTransactionID?: string; + chatReportActions: OnyxEntry; // TODO: delegateAccountID will be made required in PR 13 when all callers pass the value (https://github.com/Expensify/App/issues/66425) delegateAccountID?: number | undefined; }; @@ -263,6 +264,7 @@ type PerDiemExpenseInformationParams = { personalDetails: OnyxEntry; optimisticChatReportID?: string; optimisticTransactionID?: string; + chatReportActions: OnyxEntry; // TODO: delegateAccountID will be made required in PR 13 when all callers pass the value (https://github.com/Expensify/App/issues/66425) delegateAccountID?: number | undefined; }; @@ -319,6 +321,7 @@ function getPerDiemExpenseInformation(perDiemExpenseInformation: PerDiemExpenseI personalDetails, optimisticChatReportID, optimisticTransactionID: uiProvidedOptimisticTransactionID, + chatReportActions, delegateAccountID, } = perDiemExpenseInformation; const {payeeAccountID = currentUserAccountIDParam, payeeEmail = currentUserEmailParam, participant} = participantParams; @@ -474,7 +477,7 @@ function getPerDiemExpenseInformation(perDiemExpenseInformation: PerDiemExpenseI delegateAccountIDParam: delegateAccountID, }); - let reportPreviewAction = shouldCreateNewMoneyRequestReport ? null : getReportPreviewAction(chatReport.reportID, iouReport.reportID); + let reportPreviewAction = shouldCreateNewMoneyRequestReport ? null : getReportPreviewAction(chatReport.reportID, iouReport.reportID, chatReportActions); if (reportPreviewAction) { reportPreviewAction = updateReportPreview(iouReport, reportPreviewAction, false, comment, optimisticTransaction); @@ -924,6 +927,7 @@ function submitPerDiemExpense(submitPerDiemExpenseInformation: PerDiemExpenseInf shouldDeferAutoSubmit, optimisticChatReportID, optimisticTransactionID, + chatReportActions, delegateAccountID, } = submitPerDiemExpenseInformation; const {currency, comment = '', category, tag, created, customUnit, attendees, isFromGlobalCreate} = transactionParams; @@ -976,6 +980,7 @@ function submitPerDiemExpense(submitPerDiemExpenseInformation: PerDiemExpenseInf personalDetails, optimisticChatReportID, optimisticTransactionID, + chatReportActions, delegateAccountID, }); diff --git a/src/pages/iou/request/step/confirmation/useExpenseSubmission.ts b/src/pages/iou/request/step/confirmation/useExpenseSubmission.ts index 181266b3a21e..b9836fe9a07d 100644 --- a/src/pages/iou/request/step/confirmation/useExpenseSubmission.ts +++ b/src/pages/iou/request/step/confirmation/useExpenseSubmission.ts @@ -592,6 +592,7 @@ function useExpenseSubmission(params: UseExpenseSubmissionParams) { betas, personalDetails, optimisticChatReportID, + chatReportActions: allReportActions?.[`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${chatReportID}`], }); const targetReportID = backToReport ?? activeReportID; // When backToReport exists we are creating the expense from chat, not the expense report, so no pending transaction registration needed. diff --git a/tests/actions/IOU/PerDiemTest.ts b/tests/actions/IOU/PerDiemTest.ts index 3ca5ac43478e..f4b8c1674745 100644 --- a/tests/actions/IOU/PerDiemTest.ts +++ b/tests/actions/IOU/PerDiemTest.ts @@ -5,7 +5,7 @@ import type RequestMoneyParticipantParams from '@libs/actions/IOU/types/RequestM import CONST from '@src/CONST'; import DateUtils from '@src/libs/DateUtils'; import ONYXKEYS from '@src/ONYXKEYS'; -import type {PersonalDetailsList, RecentlyUsedTags, Report} from '@src/types/onyx'; +import type {PersonalDetailsList, RecentlyUsedTags, Report, ReportActions} from '@src/types/onyx'; import type {CurrentUserPersonalDetails} from '@src/types/onyx/PersonalDetails'; import type Transaction from '@src/types/onyx/Transaction'; import type {TransactionCustomUnit} from '@src/types/onyx/Transaction'; @@ -326,6 +326,7 @@ describe('PerDiem', () => { quickAction: undefined, betas: [CONST.BETAS.ALL], personalDetails: {[mockParticipantParams.payeeAccountID]: {accountID: mockParticipantParams.payeeAccountID, login: 'payee@example.com'}}, + chatReportActions: undefined, }); expect(result.onyxData).toBeDefined(); @@ -416,6 +417,7 @@ describe('PerDiem', () => { quickAction: undefined, betas: [CONST.BETAS.ALL], personalDetails: {[mockParticipant.accountID]: {accountID: mockParticipant.accountID, login: 'existing@example.com'}}, + chatReportActions: undefined, }); // Then: Verify the result structure and key values @@ -550,6 +552,7 @@ describe('PerDiem', () => { quickAction: undefined, betas: [CONST.BETAS.ALL], personalDetails: {[mockParticipant.accountID]: {accountID: mockParticipant.accountID, login: 'existing@example.com'}}, + chatReportActions: undefined, }); // Then: Verify the result uses existing chat report @@ -638,6 +641,7 @@ describe('PerDiem', () => { quickAction: undefined, betas: [CONST.BETAS.ALL], personalDetails: {[mockParticipant.accountID]: {accountID: mockParticipant.accountID, login: 'existing@example.com'}}, + chatReportActions: undefined, }); // Then: Verify policy expense chat handling @@ -648,6 +652,90 @@ describe('PerDiem', () => { expect(result.billable).toBe(true); expect(result.reimbursable).toBe(true); }); + + it('should reuse the existing report preview action supplied via chatReportActions', () => { + const existingChatReportID = 'chat_with_actions'; + const existingIOUReportID = 'iou_existing'; + const existingPreviewActionID = 'preview_existing'; + + const existingChatReport: Report = { + reportID: existingChatReportID, + chatType: CONST.REPORT.CHAT_TYPE.GROUP, + iouReportID: existingIOUReportID, + type: CONST.REPORT.TYPE.CHAT, + }; + const existingIOUReport: Report = { + reportID: existingIOUReportID, + chatReportID: existingChatReportID, + type: CONST.REPORT.TYPE.IOU, + ownerAccountID: 456, + managerID: 123, + currency: 'USD', + total: 0, + }; + + const chatReportActions: ReportActions = { + [existingPreviewActionID]: { + reportActionID: existingPreviewActionID, + reportID: existingChatReportID, + actionName: CONST.REPORT.ACTIONS.TYPE.REPORT_PREVIEW, + originalMessage: {linkedReportID: existingIOUReportID}, + message: [{type: CONST.REPORT.MESSAGE.TYPE.COMMENT, html: '', text: '', isEdited: false}], + created: DateUtils.getDBTime(), + accountID: 123, + actorAccountID: 456, + childReportID: existingIOUReportID, + childMoneyRequestCount: 1, + }, + }; + + const mockCustomUnit: TransactionCustomUnit = { + customUnitID: 'per_diem_reuse', + customUnitRateID: 'rate_reuse', + name: CONST.CUSTOM_UNITS.NAME_PER_DIEM_INTERNATIONAL, + attributes: {dates: {start: '2024-03-01', end: '2024-03-01'}}, + subRates: [{id: 'meal_1', name: 'Meal', rate: 30, quantity: 1}], + quantity: 1, + }; + + const mockTransactionParams: PerDiemExpenseTransactionParams = { + comment: 'reuse preview', + currency: 'USD', + created: '2024-03-01', + category: 'Meals', + tag: '', + customUnit: mockCustomUnit, + billable: false, + attendees: [], + reimbursable: true, + }; + + const mockParticipantParams: RequestMoneyParticipantParams = { + payeeAccountID: 456, + payeeEmail: 'payee@example.com', + participant: {accountID: 123, login: 'existing@example.com'}, + }; + + const result = getPerDiemExpenseInformation({ + parentChatReport: existingChatReport, + existingIOUReport, + transactionParams: mockTransactionParams, + participantParams: mockParticipantParams, + recentlyUsedParams: {}, + isASAPSubmitBetaEnabled: false, + currentUserAccountIDParam: 456, + currentUserEmailParam: 'payee@example.com', + hasViolations: false, + policyRecentlyUsedCurrencies: [], + quickAction: undefined, + betas: [CONST.BETAS.ALL], + // eslint-disable-next-line @typescript-eslint/naming-convention + personalDetails: {123: {accountID: 123, login: 'existing@example.com'}}, + chatReportActions, + }); + + expect(result.reportPreviewAction.reportActionID).toBe(existingPreviewActionID); + }); }); describe('submitPerDiemExpense', () => { @@ -713,6 +801,7 @@ describe('PerDiem', () => { quickAction: undefined, betas: [CONST.BETAS.ALL], personalDetails: {[RORY_ACCOUNT_ID]: {accountID: RORY_ACCOUNT_ID, login: RORY_EMAIL}}, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -781,6 +870,7 @@ describe('PerDiem', () => { betas: [CONST.BETAS.ALL], personalDetails: {[RORY_ACCOUNT_ID]: {accountID: RORY_ACCOUNT_ID, login: RORY_EMAIL}}, optimisticTransactionID, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -854,6 +944,7 @@ describe('PerDiem', () => { quickAction: undefined, betas: [CONST.BETAS.ALL], personalDetails: personalDetailsList, + chatReportActions: undefined, }); // Then the result should be valid (personalDetails is correctly passed through the chain) @@ -918,6 +1009,7 @@ describe('PerDiem', () => { quickAction: undefined, betas: [CONST.BETAS.ALL], personalDetails: personalDetailsList, + chatReportActions: undefined, }); await waitForBatchedUpdates(); From 692a7e3dbc55cd455f74a7d1e658d67a5cb0a339 Mon Sep 17 00:00:00 2001 From: cretadn22 Date: Mon, 6 Jul 2026 21:24:38 +0700 Subject: [PATCH 2/2] Add allReportActions to various hooks and components for improved expense handling --- .../MoneyRequestHeaderSecondaryActions.tsx | 2 ++ src/hooks/useBulkDuplicateAction.ts | 2 ++ src/hooks/useBulkDuplicateReportAction.ts | 2 ++ src/hooks/useExpenseActions.ts | 3 +++ src/libs/actions/IOU/Duplicate.ts | 16 +++++++++++++++- tests/actions/IOUTest/DuplicateTest.ts | 18 ++++++++++++++++++ 6 files changed, 42 insertions(+), 1 deletion(-) diff --git a/src/components/MoneyRequestHeaderSecondaryActions.tsx b/src/components/MoneyRequestHeaderSecondaryActions.tsx index 35b8d2d4b0d8..12b447642c5e 100644 --- a/src/components/MoneyRequestHeaderSecondaryActions.tsx +++ b/src/components/MoneyRequestHeaderSecondaryActions.tsx @@ -143,6 +143,7 @@ function MoneyRequestHeaderSecondaryActions({reportID, onBackButtonPress}: Money const [allTransactionViolations] = useOnyx(ONYXKEYS.COLLECTION.TRANSACTION_VIOLATIONS); const rawTransactionViolations = allTransactionViolations?.[`${ONYXKEYS.COLLECTION.TRANSACTION_VIOLATIONS}${transaction?.transactionID}`]; const [transactionDrafts] = useOnyx(ONYXKEYS.COLLECTION.TRANSACTION_DRAFT, {selector: validTransactionDraftsSelector}); + const [allReportActions] = useOnyx(ONYXKEYS.COLLECTION.REPORT_ACTIONS); // NVP subscriptions const [policyRecentlyUsedCurrencies] = useOnyx(ONYXKEYS.RECENTLY_USED_CURRENCIES); @@ -256,6 +257,7 @@ function MoneyRequestHeaderSecondaryActions({reportID, onBackButtonPress}: Money targetPolicyTags, currentUser: {accountID, email: currentUserLogin ?? ''}, currentUserLocalCurrency: localCurrencyCode ?? CONST.CURRENCY.USD, + chatReportActions: activePolicyExpenseChat?.reportID ? allReportActions?.[`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${activePolicyExpenseChat.reportID}`] : undefined, }); } }; diff --git a/src/hooks/useBulkDuplicateAction.ts b/src/hooks/useBulkDuplicateAction.ts index 518826035149..3873325244e3 100644 --- a/src/hooks/useBulkDuplicateAction.ts +++ b/src/hooks/useBulkDuplicateAction.ts @@ -47,6 +47,7 @@ function useBulkDuplicateAction({selectedTransactionsKeys, allTransactions, allR const [recentWaypoints] = useOnyx(ONYXKEYS.NVP_RECENT_WAYPOINTS); const [targetPolicyCategories] = useOnyx(`${ONYXKEYS.COLLECTION.POLICY_CATEGORIES}${defaultExpensePolicy?.id}`); const [targetPolicyTags] = useOnyx(`${ONYXKEYS.COLLECTION.POLICY_TAGS}${defaultExpensePolicy?.id}`); + const [allReportActions] = useOnyx(ONYXKEYS.COLLECTION.REPORT_ACTIONS); const sourcePolicyIDMap: Record = {}; for (const transactionID of selectedTransactionsKeys) { @@ -81,6 +82,7 @@ function useBulkDuplicateAction({selectedTransactionsKeys, allTransactions, allR recentWaypoints, currentUser: {accountID, email: currentUserLogin ?? ''}, currentUserLocalCurrency: localCurrencyCode ?? CONST.CURRENCY.USD, + chatReportActions: activePolicyExpenseChat?.reportID ? allReportActions?.[`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${activePolicyExpenseChat.reportID}`] : undefined, }); if (onAfterDuplicate) { diff --git a/src/hooks/useBulkDuplicateReportAction.ts b/src/hooks/useBulkDuplicateReportAction.ts index a401388727e2..15bd2c3fec0c 100644 --- a/src/hooks/useBulkDuplicateReportAction.ts +++ b/src/hooks/useBulkDuplicateReportAction.ts @@ -42,6 +42,7 @@ function useBulkDuplicateReportAction({selectedReports, allReports, searchData}: const [allPolicies] = useOnyx(ONYXKEYS.COLLECTION.POLICY); const [allPolicyCategories] = useOnyx(ONYXKEYS.COLLECTION.POLICY_CATEGORIES); const [allPolicyTags] = useOnyx(ONYXKEYS.COLLECTION.POLICY_TAGS); + const [allReportActions] = useOnyx(ONYXKEYS.COLLECTION.REPORT_ACTIONS); const handleDuplicateReports = () => { const activePolicyExpenseChat = getPolicyExpenseChat(currentUserPersonalDetails.accountID, defaultExpensePolicy?.id); @@ -67,6 +68,7 @@ function useBulkDuplicateReportAction({selectedReports, allReports, searchData}: recentWaypoints, currentUserLogin: currentUserPersonalDetails.login ?? '', currentUserAccountID: currentUserPersonalDetails?.accountID, + allReportActions, }); clearSelectedTransactions(undefined, true); diff --git a/src/hooks/useExpenseActions.ts b/src/hooks/useExpenseActions.ts index 6d0fd315fe34..adc3c56158c5 100644 --- a/src/hooks/useExpenseActions.ts +++ b/src/hooks/useExpenseActions.ts @@ -134,6 +134,7 @@ function useExpenseActions({reportID, isReportInSearch = false, backTo, onDuplic // Global collections const [personalDetails] = useOnyx(ONYXKEYS.PERSONAL_DETAILS_LIST); const [allTransactions] = useOnyx(ONYXKEYS.COLLECTION.TRANSACTION); + const [allReportActions] = useOnyx(ONYXKEYS.COLLECTION.REPORT_ACTIONS); const [allTransactionViolations] = useOnyx(ONYXKEYS.COLLECTION.TRANSACTION_VIOLATIONS); const [allPolicyCategories] = useOnyx(ONYXKEYS.COLLECTION.POLICY_CATEGORIES); const [allPolicyTags] = useOnyx(ONYXKEYS.COLLECTION.POLICY_TAGS, {selector: passthroughPolicyTagListSelector}); @@ -265,6 +266,7 @@ function useExpenseActions({reportID, isReportInSearch = false, backTo, onDuplic targetPolicyTags, currentUser: {accountID: currentUserPersonalDetails?.accountID, email: currentUserPersonalDetails?.email ?? ''}, currentUserLocalCurrency: currentUserPersonalDetails?.localCurrencyCode ?? CONST.CURRENCY.USD, + chatReportActions: activePolicyExpenseChat?.reportID ? allReportActions?.[`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${activePolicyExpenseChat.reportID}`] : undefined, }); } }; @@ -423,6 +425,7 @@ function useExpenseActions({reportID, isReportInSearch = false, backTo, onDuplic recentWaypoints: recentWaypoints ?? [], currentUserAccountID: currentUserPersonalDetails?.accountID, currentUserLogin: currentUserPersonalDetails?.email ?? '', + chatReportActions: targetChatForDuplicate?.reportID ? allReportActions?.[`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${targetChatForDuplicate.reportID}`] : undefined, }); }, }, diff --git a/src/libs/actions/IOU/Duplicate.ts b/src/libs/actions/IOU/Duplicate.ts index f87de3130d53..818e4ae7b4f4 100644 --- a/src/libs/actions/IOU/Duplicate.ts +++ b/src/libs/actions/IOU/Duplicate.ts @@ -653,6 +653,7 @@ function createExpenseByType({ customUnitPolicyID, personalDetails, recentWaypoints, + chatReportActions, }: { transactionType: string; params: RequestMoneyInformation; @@ -665,6 +666,7 @@ function createExpenseByType({ customUnitPolicyID?: string; personalDetails: OnyxEntry; recentWaypoints: OnyxEntry; + chatReportActions: OnyxEntry; }) { switch (transactionType) { case CONST.SEARCH.TRANSACTION_TYPE.DISTANCE: { @@ -727,7 +729,7 @@ function createExpenseByType({ }, hasViolations: false, customUnitPolicyID, - chatReportActions: undefined, + chatReportActions, }; return submitPerDiemExpense(perDiemParams); } @@ -760,6 +762,7 @@ type DuplicateExpenseTransactionParams = { optimisticReportPreviewActionID?: string; currentUser: CurrentUser; currentUserLocalCurrency: string | undefined; + chatReportActions: OnyxEntry; }; function duplicateExpenseTransaction({ @@ -786,6 +789,7 @@ function duplicateExpenseTransaction({ optimisticReportPreviewActionID: externalReportPreviewActionID, currentUser, currentUserLocalCurrency, + chatReportActions, }: DuplicateExpenseTransactionParams) { if (!transaction) { return; @@ -894,6 +898,7 @@ function duplicateExpenseTransaction({ customUnitPolicyID, personalDetails, recentWaypoints, + chatReportActions, }); } @@ -918,6 +923,7 @@ type DuplicateReportParams = { currentUserLogin: string; currentUserAccountID: number; shouldPlaySound?: boolean; + chatReportActions: OnyxEntry; }; function duplicateReport({ @@ -941,6 +947,7 @@ function duplicateReport({ currentUserAccountID, currentUserLogin, shouldPlaySound = true, + chatReportActions, }: DuplicateReportParams) { if (!targetPolicy || !parentChatReport) { return; @@ -1045,6 +1052,7 @@ function duplicateReport({ customUnitPolicyID: targetPolicy?.id, personalDetails, recentWaypoints, + chatReportActions, }); if (result?.iouReport) { @@ -1076,6 +1084,7 @@ type BulkDuplicateExpensesParams = { recentWaypoints: OnyxEntry; currentUser: CurrentUser; currentUserLocalCurrency: string | undefined; + chatReportActions: OnyxEntry; }; function bulkDuplicateExpenses({ @@ -1097,6 +1106,7 @@ function bulkDuplicateExpenses({ recentWaypoints, currentUser, currentUserLocalCurrency, + chatReportActions, }: BulkDuplicateExpensesParams) { const transactionsToDuplicate = transactionIDs.map((id) => allTransactions[`${ONYXKEYS.COLLECTION.TRANSACTION}${id}`]).filter((t): t is OnyxTypes.Transaction => !!t); @@ -1192,6 +1202,7 @@ function bulkDuplicateExpenses({ optimisticReportPreviewActionID: currentReportPreviewActionID, currentUser, currentUserLocalCurrency, + chatReportActions, }); if (result?.iouReport) { @@ -1227,6 +1238,7 @@ type BulkDuplicateReportsParams = { recentWaypoints: OnyxEntry; currentUserLogin: string; currentUserAccountID: number; + allReportActions: OnyxCollection; }; function bulkDuplicateReports({ @@ -1250,6 +1262,7 @@ function bulkDuplicateReports({ recentWaypoints, currentUserLogin, currentUserAccountID, + allReportActions, }: BulkDuplicateReportsParams) { const allTransactionsMap = getAllTransactions(); const transactionsByReportID = new Map(); @@ -1324,6 +1337,7 @@ function bulkDuplicateReports({ shouldPlaySound: false, currentUserAccountID, currentUserLogin, + chatReportActions: parentChatReport?.reportID ? allReportActions?.[`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${parentChatReport.reportID}`] : undefined, }); } diff --git a/tests/actions/IOUTest/DuplicateTest.ts b/tests/actions/IOUTest/DuplicateTest.ts index bd2a277a0b97..d9c9d24a158e 100644 --- a/tests/actions/IOUTest/DuplicateTest.ts +++ b/tests/actions/IOUTest/DuplicateTest.ts @@ -1340,6 +1340,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1404,6 +1405,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1460,6 +1462,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1509,6 +1512,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1558,6 +1562,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1610,6 +1615,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1672,6 +1678,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1719,6 +1726,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1759,6 +1767,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1802,6 +1811,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1851,6 +1861,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1916,6 +1927,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -1981,6 +1993,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -2030,6 +2043,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -2090,6 +2104,7 @@ describe('actions/Duplicate', () => { targetPolicyTags, currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -2261,6 +2276,7 @@ describe('actions/Duplicate', () => { currentUserAccountID: RORY_ACCOUNT_ID, currentUserLogin: RORY_EMAIL, recentWaypoints: [], + chatReportActions: undefined, ...overrides, }); @@ -2830,6 +2846,7 @@ describe('actions/Duplicate', () => { recentWaypoints: [], currentUser: {accountID: RORY_ACCOUNT_ID, email: RORY_EMAIL}, currentUserLocalCurrency: undefined, + chatReportActions: undefined, }); await waitForBatchedUpdates(); @@ -2945,6 +2962,7 @@ describe('actions/Duplicate', () => { transactionViolations: {}, translate: mockTranslate, recentWaypoints: [], + allReportActions: undefined, ...overrides, });