Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,15 @@ function MoneyRequestReportView({report, policy, reportMetadata, shouldDisplayRe

return (
<View style={styles.flex1}>
<OfflineWithFeedback
pendingAction={reportPendingAction ?? report?.pendingFields?.reimbursed}
errors={reportErrors}
needsOffscreenAlphaCompositing
shouldShowErrorMessages={false}
>
<HeaderGap />
{reportHeaderView}
</OfflineWithFeedback>
<OfflineWithFeedback
pendingAction={reportPendingAction}
errors={reportErrors}
Expand All @@ -215,8 +224,6 @@ function MoneyRequestReportView({report, policy, reportMetadata, shouldDisplayRe
contentContainerStyle={styles.flex1}
errorRowStyles={[styles.ph5, styles.mv2]}
>
<HeaderGap />
{reportHeaderView}
<View style={[styles.overflowHidden, styles.justifyContentEnd, styles.flex1]}>
{shouldDisplayMoneyRequestActionsList ? (
<MoneyRequestReportActionsList
Expand Down
7 changes: 1 addition & 6 deletions src/libs/ReportUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10239,12 +10239,7 @@ function getOriginalReportID(reportID: string | undefined, reportAction: OnyxInp
*/
function getReportOfflinePendingActionAndErrors(report: OnyxEntry<Report>): ReportOfflinePendingActionAndErrors {
// It shouldn't be possible for all of these actions to be pending (or to have errors) for the same report at the same time, so just take the first that exists
const reportPendingAction =
report?.pendingFields?.addWorkspaceRoom ??
report?.pendingFields?.createChat ??
report?.pendingFields?.reimbursed ??
report?.pendingFields?.createReport ??
report?.pendingFields?.reportName;
const reportPendingAction = report?.pendingFields?.addWorkspaceRoom ?? report?.pendingFields?.createChat ?? report?.pendingFields?.createReport ?? report?.pendingFields?.reportName;
const reportErrors = getCreationReportErrors(report);
return {reportPendingAction, reportErrors};
}
Expand Down
2 changes: 1 addition & 1 deletion src/pages/home/ReportScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -952,7 +952,7 @@ function ReportScreen({route, navigation}: ReportScreenProps) {
>
<DragAndDropProvider isDisabled={isEditingDisabled}>
<OfflineWithFeedback
pendingAction={reportPendingAction}
pendingAction={reportPendingAction ?? report?.pendingFields?.reimbursed}
errors={reportErrors}
shouldShowErrorMessages={false}
needsOffscreenAlphaCompositing
Expand Down
Loading