Skip to content

Commit

Permalink
fix: offline support for system messages
Browse files Browse the repository at this point in the history
  • Loading branch information
BartoszGrajdek committed Mar 6, 2024
1 parent 7f691ff commit 071ca7b
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ function MoneyRequestPreviewContent({
>
{displayAmount}
</Text>
{ReportUtils.isSettled(iouReport?.reportID) && !isBillSplit && (
{ReportUtils.isSettled(iouReport?.reportID) && !isPartialHold && !isBillSplit && (
<View style={styles.defaultCheckmarkWrapper}>
<Icon
src={Expensicons.Checkmark}
Expand Down
6 changes: 5 additions & 1 deletion src/libs/actions/IOU.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3494,7 +3494,11 @@ function getPayMoneyRequestParams(
paymentMethodType: PaymentMethodType,
full: boolean,
): PayMoneyRequestData {
const total = iouReport.total ?? 0;
let total = iouReport.total ?? 0;
if (ReportUtils.hasHeldExpenses(iouReport.reportID) && !full && !!iouReport.unheldTotal) {
total = iouReport.unheldTotal;
}

const optimisticIOUReportAction = ReportUtils.buildOptimisticIOUReportAction(
CONST.IOU.REPORT_ACTION_TYPE.PAY,
ReportUtils.isExpenseReport(iouReport) ? -total : total,
Expand Down
1 change: 1 addition & 0 deletions src/pages/home/ReportScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,7 @@ function ReportScreen({
reportProp.reportFields,
reportProp.ownerAccountID,
reportProp.currency,
reportProp.unheldTotal,
reportProp.participantAccountIDs,
reportProp.isWaitingOnBankAccount,
reportProp.iouReportID,
Expand Down

0 comments on commit 071ca7b

Please sign in to comment.