Expensify / App

Welcome to New Expensify: a complete re-imagination of financial collaboration, centered around chat. Help us build the next generation of Expensify by sharing feedback and contributing to the code.
https://new.expensify.com
MIT License
3.48k stars 2.83k forks source link

Workspace - Correct message shown in delete modal after navigating to expensify card #50671

Open lanitochka17 opened 1 week ago

lanitochka17 commented 1 week ago

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 9.0.48-0 Reproducible in staging?: Y Reproducible in production?: Y If this was caught during regression testing, add the test name, ID and link from TestRail: N/A Issue reported by: Applause - Internal Team

Issue found when executing PR https://github.com/Expensify/App/pull/50152

Action Performed:

precondition: user enabled expensify card and logged out

  1. Go to https://staging.new.expensify.com/ and log in with the account that has expensify card enabled
  2. Navigate to the list of workspaces
  3. Click on the 3 dot > Delete workspace

Expected Result:

The correct message on the delete modal "Are you sure you want to delete this workspace? This will remove all card feeds and assigned cards." is dispalyed

Actual Result:

The correct message on the delete modal is displayed only after the user navigates to the expensify card option and then try deleting the workspace

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

Add any screenshot/video evidence

https://github.com/user-attachments/assets/fb93815d-508c-4c2d-b072-498dcdbf375e

View all open jobs on GitHub

melvin-bot[bot] commented 1 week ago

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.

truph01 commented 1 week ago

Edited by proposal-police: This proposal was edited at 2024-10-12 00:19:15 UTC.

Proposal

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

What is the root cause of that problem?

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

https://github.com/Expensify/App/blob/e4969b22e7dbb1f6a200cc587ced4ab665415c0e/src/pages/workspace/WorkspacesListPage.tsx#L127

like:

    const hasCardFeedOrExpensifyCard = !isEmptyObject(cardFeeds) || !isEmptyObject(cardsList) || policy.hasCardList || policy.hasCardFeed;
    const hasCardFeedOrExpensifyCard =
        !isEmptyObject(cardFeeds) ||
        !isEmptyObject(cardsList) ||
        PolicyUtils.getPolicy(policyIDToDelete)?.areExpensifyCardsEnabled ||
        PolicyUtils.getPolicy(policyIDToDelete)?.areCompanyCardsEnabled;

But BE need to make sure they always return these data in policy.

CortneyOfstad commented 3 days ago

@lanitochka17 the Actual Result description does not match the steps listed above it. There is no reference to navigating to the "expensify card option" within the steps.

Can you provide some additional context into that?

CortneyOfstad commented 3 days ago

Going to see if QA will retest

MelvinBot commented 3 days ago

This has been labelled "Needs Reproduction". Follow the steps here: https://stackoverflowteams.com/c/expensify/questions/16989

melvin-bot[bot] commented 3 days ago

Triggered auto assignment to @garrettmknight (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.

CortneyOfstad commented 3 days ago

Hey @garrettmknight! I am heading OoO this afternoon (10/15 to 10/23), so reassigning this to keep it moving! I had a clarifying question on the reproduction steps here. Did not add to a project yet, as I wanted to be sure it could be actively reproduced 👍

Thanks!