Skip to content

Commit

Permalink
Merge pull request #50987 from mkzie2/mkzie2-issue/50980
Browse files Browse the repository at this point in the history
[CP Staging] fix: cannot edit receipt

(cherry picked from commit e3e0387)

(CP triggered by Beamanator)
  • Loading branch information
Beamanator authored and OSBotify committed Oct 17, 2024
1 parent 247376b commit 28b6528
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/libs/Navigation/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1527,8 +1527,8 @@ type AuthScreensParamList = CentralPaneScreensParamList &
[SCREENS.TRANSACTION_RECEIPT]: {
reportID: string;
transactionID: string;
readonly?: boolean;
isFromReviewDuplicates?: boolean;
readonly?: string;
isFromReviewDuplicates?: string;
};
[SCREENS.CONNECTION_COMPLETE]: undefined;
};
Expand Down
4 changes: 2 additions & 2 deletions src/pages/TransactionReceiptPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ function TransactionReceipt({route}: TransactionReceiptProps) {
const imageSource = tryResolveUrlFromApiRoot(receiptURIs.image ?? '');

const isLocalFile = receiptURIs.isLocalFile;
const readonly = route.params.readonly ?? false;
const isFromReviewDuplicates = route.params.isFromReviewDuplicates ?? false;
const readonly = route.params.readonly === 'true';
const isFromReviewDuplicates = route.params.isFromReviewDuplicates === 'true';

const parentReportAction = ReportActionUtils.getReportAction(report?.parentReportID ?? '-1', report?.parentReportActionID ?? '-1');
const canEditReceipt = ReportUtils.canEditFieldOfMoneyRequest(parentReportAction, CONST.EDIT_REQUEST_FIELD.RECEIPT);
Expand Down

0 comments on commit 28b6528

Please sign in to comment.