-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[CP Staging] Fix thread title not updated in header and in LHN after editing parent message #44526
[CP Staging] Fix thread title not updated in header and in LHN after editing parent message #44526
Conversation
@eVoloshchak Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
let formattedName: string | undefined; | ||
const parentReportAction = ReportActionsUtils.getParentReportAction(report); | ||
const parentReportAction = parentReportActionParam ?? ReportActionsUtils.getParentReportAction(report); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are quite a few uses of getReportName
and to not affect the others, I add the param and fallback to getParentReportAction
.
@@ -1538,6 +1538,7 @@ function editReportComment(reportID: string, originalReportAction: OnyxEntry<Rep | |||
text: reportComment, | |||
}, | |||
], | |||
lastModified: DateUtils.getDBTime(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't we need to revert this in the failure data?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I realized that the failureData already has the previous report action, so I think no need to add lastModified: originalReportAction.lastModified,
again.
App/src/libs/actions/Report.ts
Lines 1566 to 1574 in 9d8e7fe
const failureData: OnyxUpdate[] = [ | |
{ | |
onyxMethod: Onyx.METHOD.MERGE, | |
key: `${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${originalReportID}`, | |
value: { | |
[reportActionID]: { | |
...originalReportAction, | |
pendingAction: null, | |
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ohhhh ok yeah, that makes sense
Asked for c+ volunteer and Rushat is jumping on this one |
Reviewer Checklist
Screenshots/VideosAndroid: NativeAndroid coming soon Android: mWeb ChromeiOS: NativeScreen.Recording.2024-06-27.at.20.48.12.moviOS: mWeb SafariScreen.Recording.2024-06-27.at.20.51.58.movMacOS: Chrome / SafariScreen.Recording.2024-06-27.at.20.35.32.movMacOS: DesktopScreen.Recording.2024-06-27.at.20.56.13.mov |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM @mountiny
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@iwiznia already approved, moving this ahead so we can CP and deploy soon
…nt-update [CP Staging] Fix thread title not updated in header and in LHN after editing parent message (cherry picked from commit b26b9b1)
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Cherry-picked to staging by https://github.com/yuwenmemon in version: 9.0.2-6 🚀
@Expensify/applauseleads please QA this PR and check it off on the deploy checklist if it passes. |
🚀 Deployed to production by https://github.com/jasperhuangg in version: 9.0.3-7 🚀
|
🚀 Deployed to production by https://github.com/Julesssss in version: 9.0.5-13 🚀
|
Details
The thread title doesn't update immediately after editing the thread message.
Fixed Issues
$ #44430
PROPOSAL: #44430 (comment)
Tests
Same as QA Steps
Offline tests
Same as QA Steps
QA Steps
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodSTYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label and/or tagged@Expensify/design
so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
android.mp4
Android: mWeb Chrome
android.mweb.mp4
iOS: Native
ios.mp4
iOS: mWeb Safari
ios.mweb.mp4
MacOS: Chrome / Safari
web.mp4
MacOS: Desktop
desktop.mp4