Skip to content

Commit

Permalink
Merge pull request #40270 from bernhardoj/fix/39352-transaction-threa…
Browse files Browse the repository at this point in the history
…d-header-not-grayed-out

Fix transaction thread header is not grayed out when creating while offline
  • Loading branch information
srikarparsi authored Apr 19, 2024
2 parents e0a43be + ed45a70 commit 4350e96
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/libs/actions/IOU.ts
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,10 @@ function buildOnyxDataForMoneyRequest(
{
onyxMethod: Onyx.METHOD.MERGE,
key: `${ONYXKEYS.COLLECTION.REPORT}${transactionThreadReport.reportID}`,
value: transactionThreadReport,
value: {
...transactionThreadReport,
pendingFields: {createChat: CONST.RED_BRICK_ROAD_PENDING_ACTION.ADD},
},
},
// Remove the temporary transaction used during the creation flow
{
Expand Down Expand Up @@ -746,6 +749,7 @@ function buildOnyxDataForMoneyRequest(
onyxMethod: Onyx.METHOD.MERGE,
key: `${ONYXKEYS.COLLECTION.REPORT}${transactionThreadReport.reportID}`,
value: {
pendingFields: null,
errorFields: existingTransactionThreadReport
? null
: {
Expand Down Expand Up @@ -911,7 +915,10 @@ function buildOnyxDataForTrackExpense(
{
onyxMethod: Onyx.METHOD.MERGE,
key: `${ONYXKEYS.COLLECTION.REPORT}${transactionThreadReport.reportID}`,
value: transactionThreadReport,
value: {
...transactionThreadReport,
pendingFields: {createChat: CONST.RED_BRICK_ROAD_PENDING_ACTION.ADD},
},
},
// Remove the temporary transaction used during the creation flow
{
Expand Down Expand Up @@ -1082,6 +1089,7 @@ function buildOnyxDataForTrackExpense(
onyxMethod: Onyx.METHOD.MERGE,
key: `${ONYXKEYS.COLLECTION.REPORT}${transactionThreadReport.reportID}`,
value: {
pendingFields: null,
errorFields: existingTransactionThreadReport
? null
: {
Expand Down

0 comments on commit 4350e96

Please sign in to comment.