filtered personal chats out of list when submitting expense with coprate card#69815
filtered personal chats out of list when submitting expense with coprate card#69815mukhrr wants to merge 14 commits intoExpensify:mainfrom
Conversation
|
@trjExpensify do we need to allow user to delete the report when there is/are card transactions in it? Currently, for single card transaction expense report we are not showing the delete option so I thought user can't delete the report when there is any card transaction with corporate liability. comment |
|
Right, there shouldn't be a restriction on deleting an expense report. There should be a restriction on deleting a corp card liability expense.
The reason for this restriction is because deleting a "one expense report" is effectively deleting the expense. |
|
@Pujan92 @trjExpensify so we are back to my first solution here #66902 (comment) ?! |
Interestingly, my first question is why and how can a managed corporate card transaction make its way onto an IOUReport? 🤔 |
|
Yeah, that's my same initial thought, it does not sound like a problem to me since you cannot have a card transaction on iou report |
|
@trjExpensify @mountiny pls, check out the video and QA steps here. They moved expense to the iou report |
|
Once the user deletes the report, card transactions are moved to the personal space as unreported transactions. From there it is transferred to iou report. Based on that, I thought we should not allow users to delete that report. |
|
Hmm I think you can delete the report, but you should not be able to move card transaction to IOU report 🤔 at least not now |
Haha, track flow strikes again! 😅 Agreed, I think the fix here should be to only show a list of workspaces in that "Submit it to someone" page for a corp card transaction unreported in the selfDM, to prevent corp card transactions going onto IOU Reports. |
|
now BE seems to be responding with an error to avoid this company card transaction to iou request. Testing team informed that the issue is not reproducible now #66902 (comment)
|
|
@Pujan92 now I'm working on filtering out workspaces list on "Submit to someone" page when it's card transaction. Should I continue?! |
|
Wait for some time, let's @trjExpensify and @mountiny confirm the final expected behaviour, whether we need to filter and show a list of workspaces only in that "Submit it to someone" page for a corp card transaction unreported in the selfDM? |
Great! Glad the BE is now preventing it.
Yes, let's do this please! |
|
@Pujan92 I have updated PR based on the latest discussions. |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / SafariScreen.Recording.2025-09-25.at.11.58.36.movMacOS: Desktop |
|
@mukhrr Your changes look good. Bug: Once the card expense gets unreported after deleting the expense report, it starts showing the delete option in the secondary actions menu(it is bcoz below condition gets true). Also, it shows when that unreported transaction moved to any other workspace. It is not from your changes but we need to fix it by not showing delete option there. While checking, it seems the App/src/libs/ReportSecondaryActionUtils.ts Lines 460 to 462 in f3c247f Screen.Recording.2025-09-11.at.00.29.32.mov |
|
@trjExpensify yesss! So let's move forward with this PR as the issue on Unreporting is related to BE as I mentioned here cc @Pujan92 |
|
@Pujan92 it's ready! |
Just to confirm.. with this PR:
Is that right? |
|
@trjExpensify yes, that's correct. |
|
@Pujan92 done✅ |
Pujan92
left a comment
There was a problem hiding this comment.
LGTM!
Screen.Recording.2025-09-25.at.11.58.36.mov
|
@inimaga hmm I see.. how to sign it? |
|
I wonder how that middle commit is unsigned 🤔 To sign, I found the following steps from ChatGPT. To sign an existing commit in Git that wasn't signed, you can amend the commit and re-sign it. Here's how you can do it: If you want to sign a previous commit (for example, a commit that's not the most recent), you can do the following: Step-by-step:
|
|
|
The merge-base changed after approval.
|
Yes @mukhrr, Let's open a new PR. |


Explanation of Change
Fixed Issues
$ #66902
PROPOSAL: #66902 (comment)
Tests
The same with QA step.
Offline tests
QA Steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand 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
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop