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.47k stars 2.82k forks source link

Update "submitted by harvesting" report action copy #48939

Closed Beamanator closed 2 weeks ago

Beamanator commented 1 month ago

Details

This PR helps us identify report actions where "submission" happened automatically (via delayed submission) vs manually by a human

Fixed Issues

$ https://github.com/Expensify/App/issues/35091

Tests

  1. Create policy with delayed submission (example: Daily) & simple or advanced approvals
  2. Create a report & a few expenses on that policy
  3. Let report auto-harvest
  4. Verify the "Submitted" report action now reads automatically submitted <amount> via delayed submission where the "Delayed Submission" test links out to https://help.expensify.com/articles/expensify-classic/reports/Automatically-submit-employee-reports

Offline tests

N/A - delayed submission doesn't work offline

QA Steps

Same as above

PR Author Checklist

Screenshots/Videos

Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari Screenshot 2024-09-10 at 3 01 18 PM
MacOS: Desktop
melvin-bot[bot] commented 1 month ago

@mollfpr Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button]

Beamanator commented 1 month ago

@mollfpr are you able to test this? A.k.a. report "harvesting" / "Delayed submission" should work for you, right? Maybe you can try to just have 1 report harvest / auto-submit, then you can test these changes on that "Submitted" report action? 🙏

mollfpr commented 1 month ago

@mollfpr are you able to test this? A.k.a. report "harvesting" / "Delayed submission" should work for you, right? Maybe you can try to just have 1 report harvest / auto-submit, then you can test these changes on that "Submitted" report action? 🙏

Sure, I'm testing it right now 👍

Beamanator commented 1 month ago

@mollfpr any update here? :D 🙏

Beamanator commented 1 month ago

~Hmm I might have to think about how a Report Preview looks after an auto-submit report action 🤔~

Actually this def prob most likely isn't necessary at all

Beamanator commented 3 weeks ago

Good catch! Thanks @mollfpr !

mollfpr commented 3 weeks ago

I'm waiting for the expense harvested!

mollfpr commented 3 weeks ago

@Beamanator Is there any way to triggered the harvesting manually? My expense from yesterday didn't get harvested.

Beamanator commented 3 weeks ago

Shoot @mollfpr - does your test policy have Daily scheduled submit on? I think I can only manually harvest if i have a test account that you make as the approver 🤔

Beamanator commented 3 weeks ago

OK I updated a few more things to fix eslint errors... hopefullyyyyyyyyy it won't cause bugs? 😅

mollfpr commented 2 weeks ago

Shoot @mollfpr - does your test policy have Daily scheduled submit on? I think I can only manually harvest if i have a test account that you make as the approver 🤔

Yeah, I have the policy set scheduled daily but haven't harvested since last week 🥲

I can invite your test account to the policy as the approver.

Beamanator commented 2 weeks ago

@mollfpr ok that's weird! but ya please invite my account alexbeaman@expensify.com - and if you don't mind, it might have to be a policy admin

Beamanator commented 2 weeks ago

@mollfpr reportID 3651962364821678? It says it was created 1 hour ago 🤔

mollfpr commented 2 weeks ago

@Beamanator Yeah, that's a newly submitted expense. Some of my expense is harvested now, but I don't see the report action for harvested expenses.

Screenshot 2024-09-24 at 23 52 11

I wondering if the actionName for the submitted expense should be SUBMITTED or SUBMITTEDCLOSED? The API response seems using SUBMITTEDCLOSED and it's make the report action item for submitted action doesn't shows up.

Beamanator commented 2 weeks ago

What the..... I'm seeing SUBMITTED in OldDot! I'll check NewDot

Screenshot 2024-09-24 at 8 58 29 PM
Beamanator commented 2 weeks ago

Hmm in NewDot I'm seeing:

Screenshot 2024-09-24 at 9 01 31 PM
Beamanator commented 2 weeks ago

Oh @mollfpr you're looking at a different report than me!

mollfpr commented 2 weeks ago

It's weird only this report ID 3651962364821678 has the SUBMITTED action name, the other expense has SUBMITTEDCLOSE, do you have any clue why this is happening?

Screenshot 2024-09-25 at 15 42 31

Update: I might know what is happening. I submitted the 2 previous expenses before changing the policy to approval mode. So it's got harvested and ready to pay instead of for waiting approval. The third expense, it's created after the approval mode and has the action name SUBMITTED.

Screenshot 2024-09-25 at 15 45 08

I think we missing a step in making the policy in approval mode.

Beamanator commented 2 weeks ago

oOooOoohhh submitted closed is an interesting one to think about!! For now ya let's move forward mentioning that the policy needs to be on advanced approvals, not submit & close 😬

Beamanator commented 2 weeks ago

I updated the test steps & will bring up "Submitted & Closed" in the issue!

mollfpr commented 2 weeks ago

Reviewer Checklist

Screenshots/Videos

Android: Native https://github.com/user-attachments/assets/20b68def-f257-4c76-99bb-1daa2c6700aa
Android: mWeb Chrome https://github.com/user-attachments/assets/e0376e8c-03a7-4762-96a8-1eff403dc4b4
iOS: Native https://github.com/user-attachments/assets/4ebc6368-f81f-49f2-8e0c-c4647308b706
iOS: mWeb Safari https://github.com/user-attachments/assets/9d3c87a7-8ecf-4d0f-80b7-0177e4e2941c
MacOS: Chrome / Safari https://github.com/user-attachments/assets/efcc9a0f-a7e0-4756-ab48-34d817580e87
MacOS: Desktop https://github.com/user-attachments/assets/12cac62b-1fe7-492d-a89a-6663ca2680d3
melvin-bot[bot] commented 2 weeks ago

@neil-marcellini Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button]

OSBotify commented 2 weeks ago

:hand: This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

github-actions[bot] commented 2 weeks ago

🚀 Deployed to staging by https://github.com/neil-marcellini in version: 9.0.41-0 🚀

platform result
🤖 android 🤖 cancelled 🔪
🖥 desktop 🖥 success ✅
🍎 iOS 🍎 success ✅
🕸 web 🕸 success ✅
kavimuru commented 2 weeks ago

@Beamanator, what does "Let report auto-harvest" mean? Is this auto submission?

mollfpr commented 2 weeks ago

@kavimuru Yes! It should be submitted automatically after setting the delayed submission.

kavimuru commented 2 weeks ago

@mollfpr Then should we wait for 24 hours if it is set to "Daily"?

Beamanator commented 2 weeks ago

@kavimuru yes, correct!! Thanks!

kavimuru commented 1 week ago

@Beamanator Tester has to wait for 24 hours, is there anyway this could be verified without waiting?

kavimuru commented 1 week ago

@Beamanator @mollfpr could this be verified internally?

Beamanator commented 1 week ago

Yes @kavimuru i can verify internally!

Beamanator commented 1 week ago

Ya looking good on staging 👍

Screenshot 2024-09-30 at 2 34 46 PM
github-actions[bot] commented 1 week ago

🚀 Deployed to production by https://github.com/jasperhuangg in version: 9.0.41-10 🚀

platform result
🤖 android 🤖 success ✅
🖥 desktop 🖥 success ✅
🍎 iOS 🍎 success ✅
🕸 web 🕸 success ✅