Skip to content
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

[$250] Room - In room created with dependent tags enabled workspace, state tags shown in expense preview #53454

Open
4 of 8 tasks
vincdargento opened this issue Dec 3, 2024 · 10 comments
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor retest-weekly Apply this label if you want this issue tested on a Weekly basis by Applause Reviewing Has a PR in review Weekly KSv2

Comments

@vincdargento
Copy link

vincdargento commented Dec 3, 2024

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


Version Number: 9.0.70-0
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: Yes
If this was caught during regression testing, add the test name, ID and link from TestRail: N/A
Email or phone of affected tester (no customers): N/A
Issue reported by: Applause Internal Team

Action Performed:

  1. Launch app
  2. Go to workspace settings ( a workspace with dependent tags added in old dot)
  3. Tap tags and note dependent tags
  4. Navigate to LHN and create a room with above workspace
  5. Invite a member via mention
  6. Create a split expense
  7. Note expense preview displays state tag
  8. Go to workspace settings and enable tag feature
  9. Add a tag
  10. Navigate to LHN and create a room with above workspace
  11. Invite a member via mention
  12. Create a split expense
  13. Note expense preview doesn't displays tag

Expected Result:

In confirmation page, no tag option and so after creating expense, in preview

Actual Result:

In room created with dependent tags enabled workspace, state tags shown in expense preview. But tag not shown in preview for room created with ordinary tags enabled.

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android: Standalone
  • Android: HybridApp
  • Android: mWeb Chrome
  • iOS: Standalone
  • iOS: HybridApp
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

bug.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021865094255127866607
  • Upwork Job ID: 1865094255127866607
  • Last Price Increase: 2024-12-06
  • Automatic offers:
    • abzokhattab | Contributor | 105256689
Issue OwnerCurrent Issue Owner: @abzokhattab
@vincdargento vincdargento added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Dec 3, 2024
Copy link

melvin-bot bot commented Dec 3, 2024

Triggered auto assignment to @CortneyOfstad (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

@abzokhattab
Copy link
Contributor

abzokhattab commented Dec 3, 2024

Proposal

Please re-state the problem that we are trying to solve in this issue.

Inconsistency in the tag field between the split report preview and the split confirm and details

What is the root cause of that problem?

this inconsistency occurs because in the split confirm page we dont show the tag if the split is not an expense report chat however we dont check that in the split preview:

const shouldShowTags = useMemo(() => isPolicyExpenseChat && TagsOptionsListUtils.hasEnabledTags(policyTagLists), [isPolicyExpenseChat, policyTagLists]);

const shouldShowCategoryOrTag = !!tag || !!category;

What changes do you think we should make in order to solve the problem?

we should add a check to validate that the current report is isPolicyExpenseChatso we should change this to

    const shouldShowTag = !!tag && isPolicyExpenseChat;
    const shouldShowCategoryOrTag = shouldShowTag || !!category;

and here we should use shouldShowTag instead of the tag

What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?

N/A

What alternative solutions did you explore? (Optional)

another solution is to prevent setting the tag in request transaction if the chat is not a isPolicyExpenseChat

if (updatedTagsString !== TransactionUtils.getTag(transaction) && updatedTagsString) {
IOU.setMoneyRequestTag(transactionID, updatedTagsString);
}

        if (updatedTagsString !== TransactionUtils.getTag(transaction) && updatedTagsString && isPolicyExpenseChat) {
            IOU.setMoneyRequestTag(transactionID, updatedTagsString);
        }

@melvin-bot melvin-bot bot added the Overdue label Dec 6, 2024
@CortneyOfstad CortneyOfstad added the External Added to denote the issue can be worked on by a contributor label Dec 6, 2024
Copy link

melvin-bot bot commented Dec 6, 2024

Job added to Upwork: https://www.upwork.com/jobs/~021865094255127866607

@melvin-bot melvin-bot bot changed the title Room - In room created with dependent tags enabled workspace, state tags shown in expense preview [$250] Room - In room created with dependent tags enabled workspace, state tags shown in expense preview Dec 6, 2024
@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Dec 6, 2024
Copy link

melvin-bot bot commented Dec 6, 2024

Triggered auto assignment to Contributor-plus team member for initial proposal review - @jayeshmangwani (External)

@melvin-bot melvin-bot bot removed the Overdue label Dec 6, 2024
@CortneyOfstad
Copy link
Contributor

I was not able to reproduce this — going to have this retested!

@CortneyOfstad CortneyOfstad added the retest-weekly Apply this label if you want this issue tested on a Weekly basis by Applause label Dec 6, 2024
@jayeshmangwani
Copy link
Contributor

@abzokhattab 's Proposal looks good to me. We can add the isPolicyExpenseChat check for showing the tag on MoneyRequestPreviewContent. We're doing the same on the Split Details page, so it seems fine here too.

🎀 👀 🎀 C+ reviewed

Copy link

melvin-bot bot commented Dec 9, 2024

Triggered auto assignment to @cristipaval, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Dec 9, 2024
Copy link

melvin-bot bot commented Dec 9, 2024

📣 @abzokhattab 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!

Offer link
Upwork job
Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑‍💻
Keep in mind: Code of Conduct | Contributing 📖

@garrettmknight garrettmknight moved this to Bugs and Follow Up Issues in [#whatsnext] #expense Dec 10, 2024
@jayeshmangwani
Copy link
Contributor

@abzokhattab What's the ETA for the PR?

@abzokhattab
Copy link
Contributor

the pr is ready here #53973

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor retest-weekly Apply this label if you want this issue tested on a Weekly basis by Applause Reviewing Has a PR in review Weekly KSv2
Projects
Status: Bugs and Follow Up Issues
Development

No branches or pull requests

5 participants