App icon indicating copy to clipboard operation
App copied to clipboard

[MEDIUM] Admin “force submit” throws a RBR red dot in the LHN and double messaging

Open Christinadobrzyn opened this issue 1 year ago • 32 comments

Slack conversation: https://expensify.slack.com/archives/C02MW39LT9N/p1703190155736439?thread_ts=1703187017.215259&cid=C02MW39LT9N

Action Performed:

Pre-testing requirement: Collect workspace type with the isPolicyExpenseChatEnabled NVP set (SO).

  1. As the admin, go to OldDot and change the scheduled submit frequency to manually for a workspace
  2. Log back into NewDot as the member (or refresh if you already are in another window) • Verify that the LHN row for the workspace chat includes a GBR green dot for the draft report awaiting submission :white_check_mark:
  3. Tap the workspace chat row to navigate to the workspace chat view • Verify that the draft report preview component appears in the workspace chat :white_check_mark: • Verify that the draft report preview component in the chat:
  4. Includes a green Submit button :white_check_mark:
  5. Sign-in as the collect policy admin account, and navigate to the member’s workspace chat in NewDot
  6. Tap the report preview component of the draft report to navigate to the expense report view
  7. Tap the Submit button :x: • Verify the text in the next steps banner updates to reflect the report has been submitted and is awaiting approval: “Waiting for %approverName% to review these requests” :white_check_mark: • Verify a system message is added to the expense report from the admin that reads: “submitted %reportTotal%” :white_check_mark: • Verify a green Approve/Pay button appears to approve the report :white_check_mark:

Expected Result:

If an admin "force submits" an expense there's a GBR and one message about the expense submitted

Actual Result:

If an admin "force submits" an expense there's a RBR and multiple messages about the expense submitted

Screenshots/Videos

image

View all open jobs on GitHub

Christinadobrzyn avatar Dec 21 '23 20:12 Christinadobrzyn

Triggered auto assignment to @greg-schroeder (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

melvin-bot[bot] avatar Dec 21 '23 20:12 melvin-bot[bot]

Bug0 Triage Checklist (Main S/O)

  • [ ] This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
  • [ ] This bug is not a duplicate report (check E/App issues and #expensify-bugs)
    • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
  • [ ] This bug is reproducible using the reproduction steps in the OP. S/O
    • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
    • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
  • [ ] This issue is filled out as thoroughly and clearly as possible
    • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
  • [ ] I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync

melvin-bot[bot] avatar Dec 21 '23 20:12 melvin-bot[bot]

Added to High will call out in next Weekly Update

greg-schroeder avatar Dec 31 '23 10:12 greg-schroeder

Unable to auto-create job on Upwork. The BZ team member should create it manually for this issue.

melvin-bot[bot] avatar Dec 31 '23 10:12 melvin-bot[bot]

Triggered auto assignment to Contributor Plus for review of internal employee PR - @mananjadhav (Internal)

melvin-bot[bot] avatar Dec 31 '23 10:12 melvin-bot[bot]

@mananjadhav @greg-schroeder this issue was created 2 weeks ago. Are we close to a solution? Let's make sure we're treating this as a top priority. Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

melvin-bot[bot] avatar Jan 04 '24 17:01 melvin-bot[bot]

Still trying to get our priorities in line

greg-schroeder avatar Jan 08 '24 21:01 greg-schroeder

@mananjadhav @greg-schroeder this issue is now 3 weeks old. There is one more week left before this issue breaks WAQ. What needs to happen to get a PR in review this week? Please create a thread in #expensify-open-source to discuss. Thanks!

melvin-bot[bot] avatar Jan 11 '24 17:01 melvin-bot[bot]

Weekly update tomorrow 1.12

greg-schroeder avatar Jan 11 '24 20:01 greg-schroeder

Holding on higher prio items

greg-schroeder avatar Jan 18 '24 00:01 greg-schroeder

Melvin please relax

greg-schroeder avatar Jan 18 '24 00:01 greg-schroeder

@mananjadhav @greg-schroeder this issue is now 4 weeks old and preventing us from maintaining WAQ. This should now be your highest priority. Please post below what your plan is to get a PR in review ASAP. Thanks!

melvin-bot[bot] avatar Jan 18 '24 17:01 melvin-bot[bot]

This a bug with a feature of drafts, why did we close it? 😕

trjExpensify avatar Jan 23 '24 18:01 trjExpensify

Randomly came across this one and I'm curious about the same?

JmillsExpensify avatar Jan 25 '24 23:01 JmillsExpensify

Going to reopen until we have an answer so it's not lost.

trjExpensify avatar Jan 25 '24 23:01 trjExpensify

Yeah, sorry about that. I was going through and closing a group of issues in my queue that weren't relevant to our roadmap - I had about ~15 or so open in tabs and closed them all at once. This one and another one were both open from doing the weekly update in the room, so I closed them by mistake alongside the rest

greg-schroeder avatar Jan 26 '24 18:01 greg-schroeder

Cool, sounds good! 👍

trjExpensify avatar Jan 29 '24 19:01 trjExpensify

Setting as a Hot Pick

greg-schroeder avatar Jan 29 '24 22:01 greg-schroeder

I believe this has been fixed, but it would be good if someone could try to reproduce in staging/prod to make sure we can close this one.

https://github.com/Expensify/App/assets/5201282/898df060-c2c8-48af-a67b-691e847ef8ee

There seems to have another bug where the next step is not automatically updated for the submitter though.

rlinoz avatar Jan 31 '24 18:01 rlinoz

@rlinoz I believe @JmillsExpensify had this issue today.

is your testing account also an admin? The problem happens when the approver is not an admin since we did not support this case in OldDot and currently the submit report command does not allow this for a mere approver.

We were discussing it a bit here

mountiny avatar Jan 31 '24 19:01 mountiny

Yeah I'm able to reliably reproduce this as an approver.

JmillsExpensify avatar Feb 01 '24 03:02 JmillsExpensify

@mananjadhav, @greg-schroeder Whoops! This issue is 2 days overdue. Let's get this updated quick!

melvin-bot[bot] avatar Feb 02 '24 15:02 melvin-bot[bot]

Keeping this on my radar if nobody picks it up, been focused on ideal nav these days!

mountiny avatar Feb 02 '24 19:02 mountiny

This will continue to be in the update until someone grabs it, hopefully soon!

greg-schroeder avatar Feb 06 '24 01:02 greg-schroeder

Picking this up. Will start work on it tomorrow.

blimpich avatar Feb 06 '24 02:02 blimpich

Started looking into this day, ran into some dev environment issues while trying to reproduce, so didn't get far. Will continue work on it tomorrow.

One question: I made a collect policy on old dot, and when I try to switch scheduled submit to manual I can't actually find where to do that. I followed this help doc but when I go to the reports page there is no scheduled submit option configuration modal, just this:

Screenshot 2024-02-06 at 5 25 28 PM

Did this option get moved somewhere?

blimpich avatar Feb 07 '24 01:02 blimpich

Oh, interesting! I can see the setting on staging:

image

trjExpensify avatar Feb 07 '24 02:02 trjExpensify

Update: okay I was able to get it to switch to manually submit. Restarted my VM and it started working for some reason.

blimpich avatar Feb 07 '24 19:02 blimpich

is your testing account also an admin? The problem happens when the approver is not an admin since we did not support this case in OldDot and currently the submit report command does not allow this for a mere approver.

Huh, this is confusing because the issue description says in step 5 Sign-in as the collect policy admin account. Also I feel silly but how do I even make an approver that isn't an admin? Looking at stackoverflow this appears somewhat enlightening, but its not clear for the issue description that there is more setup required here.

blimpich avatar Feb 07 '24 19:02 blimpich

Alright I think I was able to figure out how to reproduce this locally. Though my screen isn't exactly what is described in the issue description. I have three users, one admin, two normal workspace members, but in Old Dot under Members > Approval Mode I put one of my non-admin members as the person to submit reports to instead of the admin.

Screenshot 2024-02-07 at 11 40 37 AM

blimpich avatar Feb 07 '24 19:02 blimpich