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] Submit expense RHP doesn't include workspaces from Track flow #51552

Open
shawnborton opened this issue Oct 28, 2024 · 6 comments
Open
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors

Comments

@shawnborton
Copy link
Contributor

shawnborton commented Oct 28, 2024

Problem:
When you Track an expense, you can then submit it to someone. However, the list of contacts shown on this screen differs from the same contacts you would see if you first chose Submit expense from global create.

Track sees this:
image

Submit sees this:
image

Solution:
Let's make sure the Submit expense RHP flow looks identical no matter if you chose Track or Submit. This will fix the inconsistency in the product, and it also helps our chances for conversion as it unhides submitting an expense to a workspace from this flow.

cc @anmurali @JmillsExpensify to file this one, I think it is a #convert issue

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021850835832011853233
  • Upwork Job ID: 1850835832011853233
  • Last Price Increase: 2024-10-28
Issue OwnerCurrent Issue Owner: @hoangzinh
@shawnborton shawnborton added External Added to denote the issue can be worked on by a contributor Bug Something is broken. Auto assigns a BugZero manager. labels Oct 28, 2024
@melvin-bot melvin-bot bot changed the title Submit expense RHP doesn't include workspaces from Track flow [$250] Submit expense RHP doesn't include workspaces from Track flow Oct 28, 2024
Copy link

melvin-bot bot commented Oct 28, 2024

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

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Oct 28, 2024
Copy link

melvin-bot bot commented Oct 28, 2024

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

Copy link

melvin-bot bot commented Oct 28, 2024

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

@melvin-bot melvin-bot bot added the Daily KSv2 label Oct 28, 2024
@NJ-2020
Copy link
Contributor

NJ-2020 commented Oct 28, 2024

Proposal

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

Submit expense RHP doesn't include workspaces from Track flow

What is the root cause of that problem?

We do not include here for track expense

includeOwnedWorkspaceChats: (iouType === CONST.IOU.TYPE.SUBMIT || iouType === CONST.IOU.TYPE.CREATE || iouType === CONST.IOU.TYPE.SPLIT) && action !== CONST.IOU.ACTION.SUBMIT,

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

We should include track expense as well

includeOwnedWorkspaceChats: (iouType === CONST.IOU.TYPE.SUBMIT || iouType === CONST.IOU.TYPE.CREATE || iouType === CONST.IOU.TYPE.SPLIT || iouType === CONST.IOU.TYPE.TRACK) && action !== CONST.IOU.ACTION.SUBMIT,

Result

Screenshot 2024-10-28 at 03 07 00

What alternative solutions did you explore? (Optional)

@bernhardoj
Copy link
Contributor

Proposal

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

The Submit to someone track option opens a participant page without including workplace chat.

What is the root cause of that problem?

We are currently excluding workspace from the participant list if the ACTION is SUBMIT.

includeOwnedWorkspaceChats: (iouType === CONST.IOU.TYPE.SUBMIT || iouType === CONST.IOU.TYPE.CREATE || iouType === CONST.IOU.TYPE.SPLIT) && action !== CONST.IOU.ACTION.SUBMIT,

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

Remove the action SUBMIT condition

includeOwnedWorkspaceChats: (iouType === CONST.IOU.TYPE.SUBMIT || iouType === CONST.IOU.TYPE.CREATE || iouType === CONST.IOU.TYPE.SPLIT) && action !== CONST.IOU.ACTION.SUBMIT,

&& action !== CONST.IOU.ACTION.SUBMIT

But I have a concern. The action currently reads "Submit it to someone". Is workspace considered "someone"? If not, I think we should rephrase it.
image

@FitseTLT
Copy link
Contributor

Proposal

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

Submit expense RHP doesn't include workspaces from Track flow

What is the root cause of that problem?

We are currently not allowing workspaces through the Submit it to someone operation so we disallow the option for distance requests if P2P distance is not enabled

...(!TransactionUtils.isDistanceRequest(TransactionUtils.getTransaction(transactionID ?? '-1')) || canUseP2PDistanceRequests

and in participants we are not including workspaces if the action is submit
includeOwnedWorkspaceChats: (iouType === CONST.IOU.TYPE.SUBMIT || iouType === CONST.IOU.TYPE.CREATE || iouType === CONST.IOU.TYPE.SPLIT) && action !== CONST.IOU.ACTION.SUBMIT,

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

  1. we need to remove this condition here to allow the option to be visible for distance requests even if the P2P is disabled

    ...(!TransactionUtils.isDistanceRequest(TransactionUtils.getTransaction(transactionID ?? '-1')) || canUseP2PDistanceRequests

  2. remove the submit action condition here

    includeOwnedWorkspaceChats: (iouType === CONST.IOU.TYPE.SUBMIT || iouType === CONST.IOU.TYPE.CREATE || iouType === CONST.IOU.TYPE.SPLIT) && action !== CONST.IOU.ACTION.SUBMIT,

            includeOwnedWorkspaceChats: iouType === CONST.IOU.TYPE.SUBMIT || iouType === CONST.IOU.TYPE.CREATE || iouType === CONST.IOU.TYPE.SPLIT,

What alternative solutions did you explore? (Optional)

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. Daily KSv2 External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors
Projects
None yet
Development

No branches or pull requests

6 participants