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.98k stars 2.99k forks source link

Expense - Unable to submit an expense when there is control workspace only in the account #55123

Closed IuliiaHerets closed 1 week ago

IuliiaHerets commented 2 weeks 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: v9.0.84-0 Reproducible in staging?: Yes Reproducible in production?: Yes Email or phone of affected tester (no customers): htad26+sdfgshdgfh@gmail.com Issue reported by: Applause Internal Team Device used: Windows 10/Chrome, mWeb/Chrome App Component: Money Requests

Action Performed:

  1. Log in to a new Gmail account in new dot (Choose "other" in purposes during onboarding so that a workspace is not auto-created)
  2. Sign in to old dot with the same account
  3. Navigate to old dot > Create a new control workspace
  4. Navigate to new dot > Global Create > Create expense

Expected Result:

User should be directed to expense creation RHN

Actual Result:

"Switch to Expensify classic" modal appears and user is unable to submit expense on Newdot. The issue persists after downgrading the workspace to Collect too.

Workaround:

Unknown

Platforms:

Screenshots/Videos

https://github.com/user-attachments/assets/827cd0b6-38e5-4957-acaa-f5be79f019f1

View all open jobs on GitHub

melvin-bot[bot] commented 2 weeks ago

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

ijmalik commented 2 weeks ago

Hi @sakluger

When workspace has been created in OD it has isPolicyExpenseChatEnabled: false

And when workspace has been created in ND it has isPolicyExpenseChatEnabled: true

In this case, this appears to be the intended behavior.

https://github.com/Expensify/App/blob/fb487a59dada9d0d0f8215408287ba86f0eac98b/src/pages/home/sidebar/SidebarScreen/FloatingActionButtonAndPopover.tsx#L218-L224

https://github.com/Expensify/App/blob/fb487a59dada9d0d0f8215408287ba86f0eac98b/src/pages/home/sidebar/SidebarScreen/FloatingActionButtonAndPopover.tsx#L351-L354

sakluger commented 1 week ago

I agree that this may be intended behavior, since I know that we block submission in NewDot if a user is a member of a Control workspace. I'm verifying expected behavior in Slack: https://expensify.slack.com/archives/C06ML6X0W9L/p1736796258522319

sakluger commented 1 week ago

Re-reading the bug report, this is more of a #migrate issue. I posted in the migrate Slack channel instead: https://expensify.slack.com/archives/C07NMDKEFMH/p1737074102447149

sakluger commented 1 week ago

I learned that this is expected behavior. Since isPolicyExpenseChatEnabled: false that means they haven't been migrated to NewDot yet, so the workspace chat is not enabled in their workspace. Even after downgrading to Collect, it would still be the same since they still have not been migrated yet.