App
App copied to clipboard
Expense - "Approved" is not present in Amount in request details page for approved expense
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 1.3.45-5 Reproducible in staging?: Y Reproducible in production?: Y If this was caught during regression testing, add the test name, ID and link from TestRail: https://expensify.testrail.io/index.php?/tests/view/4264387 Email or phone of affected tester (no customers): Logs: https://stackoverflow.com/c/expensify/questions/4856 Expensify/Expensify Issue URL: Issue reported by: Applause - Internal Team Slack conversation:
Action Performed:
Precondition:
- Admin and employee are part of Collect workspace
- Admin is also approver in the Collect workspace
- [Employee] Create a manual request in the workspace chat
- [Employee] Submit the report
- [Admin] Go to workspace chat with employee
- [Admin] Click on the request preview
- [Admin] Click on the dropdown button next to the green button on the top right > Approve
- [Admin] Approve the report
- [Admin] Click on the expense preview
Expected Result:
"Approved" will be present next to "Amount • Cash" in request details page
Actual Result:
"Approved" is not present next to "Amount • Cash" in request details page, while it is present next to "Cash" in expense preview in expense report
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
- [x] Android: Native
- [x] Android: mWeb Chrome
- [x] iOS: Native
- [x] iOS: mWeb Safari
- [x] MacOS: Chrome / Safari
- [x] MacOS: Desktop
Screenshots/Videos
Add any screenshot/video evidence
https://github.com/Expensify/App/assets/78819774/6afb6b9f-b44c-4ecc-a3f7-4ff66c3707d9
Triggered auto assignment to @sakluger (Bug
), see https://stackoverflow.com/c/expensify/questions/14418 for more details.
We think that this bug might be related to #wave7 CC @RachCHopkins
@sakluger Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
Proposal
Please re-state the problem that we are trying to solve in this issue.
"Approved" is not present in Amount in request details page for approved expense
What is the root cause of that problem?
Currently we have the condition to check for approved transactions as: https://github.com/Expensify/App/blob/51303b5c2a392660193feb809f61105e090f9c15/src/components/ReportActionItem/MoneyRequestView.tsx#L178-L180
But here we pass report, which in turn returns false, and hence the text for approved is not added
What changes do you think we should make in order to solve the problem?
We need to update the conditions of adding the approved text with conditions similar to the preview page:
https://github.com/Expensify/App/blob/51303b5c2a392660193feb809f61105e090f9c15/src/components/ReportActionItem/MoneyRequestPreview.tsx#L208-L210
What alternative solutions did you explore? (Optional)
N/A
Asked in #wave7 if it's connected to that wave.
Job added to Upwork: https://www.upwork.com/jobs/~01afb3d30cf9a1eb24
Triggered auto assignment to Contributor-plus team member for initial proposal review - @c3024 (External
)
Hi @GandalfGwaihir, thanks for the proposal but the extra conditionals don't solve the issue. I noticed we're getting the status and state from the wrong report (transaction report) instead of the money request.
I'm going to create a PR since it's a quick fix, I will remove the external label
Triggered auto assignment to Contributor Plus for review of internal employee PR - @eVoloshchak (Internal
)
Sent an offer to @eVoloshchak via Upwork for the PR review.
Reviewing
label has been removed, please complete the "BugZero Checklist".
The solution for this issue has been :rocket: deployed to production :rocket: in version 1.4.40-5 and is now subject to a 7-day regression period :calendar:. Here is the list of pull requests that resolve this issue:
- https://github.com/Expensify/App/pull/36063
If no regressions arise, payment will be issued on 2024-02-20. :confetti_ball:
For reference, here are some details about the assignees on this issue:
- @eVoloshchak requires payment through NewDot Manual Requests
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
- [ ] [@eVoloshchak] The PR that introduced the bug has been identified. Link to the PR:
- [ ] [@eVoloshchak] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment:
- [ ] [@eVoloshchak] A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion:
- [ ] [@eVoloshchak] Determine if we should create a regression test for this bug.
- [ ] [@eVoloshchak] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
- [ ] [@sakluger] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:
Sent an offer to @eVoloshchak via Upwork for the PR review.
@sakluger, no need for Upwork, I get paid via NewDot I'll request the payment for this on 20th (assuming no regressions arise)
Thanks for clarifying @eVoloshchak. Our spreadsheet said that you didn't do NewDot requests, sorry about that.
Payment Summary
- Reviewer: @eVoloshchak owed $500 via NewDot
BugZero Checklist (@sakluger)
- [x] I have verified the correct assignees and roles are listed above and updated the neccesary manual offers
- [x] I have verified that there are no duplicate or incorrect contracts on Upwork for this job (https://www.upwork.com/ab/applicants/1755300910406561792/hired)
- [x] I have paid out the Upwork contracts or cancelled the ones that are incorrect
- [x] I have verified the payment summary above is correct
- The PR that introduced the bug has been identified. Link to the PR: https://github.com/Expensify/App/pull/28976
- The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment: https://github.com/Expensify/App/pull/28976/files#r1495989726
- A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion: I don't think an additional discussion is needed here, this is a pretty minor bug
Regression Test Proposal
Preconditions:
- Admin and employee are part of a Collect workspace
- Admin is also approver in the Collect workspace
Test steps:
- [Employee] Create a manual request in the workspace chat
- [Employee] Submit the report
- [Admin] Go to workspace chat with employee
- [Admin] Click on the request preview
- [Admin] Click on the dropdown button next to the green button on the top right > Approve
- [Admin] Approve the report
- [Admin] Click on the expense preview
- [Admin] Verify the text "Approved" appears in the description (i.e.
Amount*Cash*Approved
)
Do we agree 👍 or 👎
The test steps look good! You're all set to request payment via NewDot.
$500 approved for @eVoloshchak based on summary above.