Feature: Implement ChangeReportPolicy#57553
Conversation
d0ab9ca to
61f4961
Compare
|
I had to force-push to sign my commits |
|
Requested translation confirmation in Slack: https://expensify.slack.com/archives/C01GTK53T8Q/p1741005706637539 |
|
@luacmartins Are there existing manual testing steps for this feature / design doc? |
|
@Expensify/design for eyes on this new modal #57553 (comment) |
|
Looking good! I wonder if we should bold @Expensify/design Do we typically use |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
@rayane-d Can you help with the following step for native apps?
|
|
🚀 Deployed to staging by https://github.com/luacmartins in version: 9.1.13-0 🚀
|
This is a dev command. For native platforms, you can:
|
|
@kavimuru I updated the tests |
|
🚀 Deployed to production by https://github.com/mountiny in version: 9.1.13-5 🚀
|
|
|
||
| // 3. Optimistically create a new REPORTPREVIEW reportAction with the newReportPreviewActionID | ||
| // and set it as a parent of the moved report | ||
| const policyExpenseChat = getPolicyExpenseChat(currentUserAccountID, policyID); |
There was a problem hiding this comment.
Come from: #65561
This logic creates a new REPORT_PREVIEW report action and adds it to the policy expense chat. However, we are always adding it to the current user's policy expense chat, instead of the policy expense chat of the user who owns the expense report (optimistically).
| isOffline, | ||
| selectedPolicyID: report.policyID, | ||
| searchTerm: debouncedSearchTerm, | ||
| additionalFilter: (newPolicy) => isWorkspaceEligibleForReportChange(newPolicy, report, oldPolicy, currentUserLogin), |
There was a problem hiding this comment.
Coming from #75657, We need to check the workspaces where the current user is an admin when setting the data here

Explanation of Change
Fixed Issues
$ #57464
PROPOSAL: N/A
Tests
/change-workspaceto the URL of the expenses report. Example: If the report URL is https://new.expensify.com/r/123456, change it to https://new.expensify.com/r/123456/change-workspace. For native platforms:CHANGEPOLICYis added, indicating the workspace change.Offline tests
Same as tests
QA Steps
Same as tests
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Screen.Recording.2025-03-12.at.10.28.55.PM.mov
Android: mWeb Chrome
Screen.Recording.2025-03-12.at.10.09.05.PM.mov
iOS: Native
Simulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2025-03-12.at.22.16.05.mp4
iOS: mWeb Safari
Simulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2025-03-04.at.20.36.47.mp4
MacOS: Chrome / Safari
Screen.Recording.2025-03-04.at.8.02.29.PM.mov
MacOS: Desktop
Screen.Recording.2025-03-12.at.10.11.24.PM.mov