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

[Awaiting Payment 20th August] [Held requests] Clean up the hold/unhold logic #44573

Closed
trjExpensify opened this issue Jun 27, 2024 · 28 comments
Closed
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Internal Requires API changes or must be handled by Expensify staff Weekly KSv2

Comments

@trjExpensify
Copy link
Contributor

Coming from here, we're seeing some inconsistencies in the intended design for hold/unhold logic. For example, a member on a workspace can unhold their expense even if the approver put it on hold.

@robertjchen @BartoszGrajdek let's go through this and make sure we clean up any inconsistencies. Any questions or further clarifiers necessary, let's align in the Slack thread.

Hold

Expenses on expenseReports

  • Members can hold their own expenses.
  • Approvers can hold expenses submitted to them.
  • Admins can hold any expense on a workspace they’re an admin of.

Expenses on iouReports

  • Members can hold each others expenses.

Unhold

Expenses on expenseReports

  • Members can unhold their own expenses, but only if they themselves put the expense on hold.
  • Approvers can unhold expenses submitted to them.
  • Admins can unhold any held expense on a workspace they’re an admin of.

Expenses on iouReports

  • Members can only unhold expenses they put on hold themselves.
@trjExpensify trjExpensify added Daily KSv2 Internal Requires API changes or must be handled by Expensify staff Bug Something is broken. Auto assigns a BugZero manager. labels Jun 27, 2024
Copy link

melvin-bot bot commented Jun 27, 2024

Current assignee @trjExpensify is eligible for the Bug assigner, not assigning anyone new.

@trjExpensify trjExpensify moved this to Release 2: Summer 2024 (Aug) in [#whatsnext] #wave-collect Jun 27, 2024
@robertjchen
Copy link
Contributor

Thanks for going through this and laying out all the cases! 🙇

@trjExpensify
Copy link
Contributor Author

Anytime!

@cdOut
Copy link
Contributor

cdOut commented Jul 1, 2024

Hi, I'm Tymoteusz Kałuzieński from Software Mansion, the expert agency, and I'm going to be working on this issue.

@BartoszGrajdek
Copy link
Contributor

BartoszGrajdek commented Jul 1, 2024

Hi! I'm currently quite busy with maintainment of live markdown lib, but @cdOut from our SWM team has the capacity to take this over. He has already worked with hold requests feature, so he knows everything necessary to work on this issue. 🙏🏻

@trjExpensify
Copy link
Contributor Author

Great!

@robertjchen
Copy link
Contributor

robertjchen commented Jul 2, 2024

Started on the backend, draft PR linked!

Having reviewed the existing logic, it looks like the only key thing we would have to change, at least for the backend, is just the unhold case (for both iouReports and expenseReports): Members can only unhold expenses they put on hold themselves. (with the exception of approvers and admins). All other cases appear to be working as intended.

I should have the backend PR wrapped up with automated tests tomorrow.

@cdOut Let me know if you have any questions on the frontend! In the Hold reportAction, we store the accountID of the person who performed the initial hold action, so you should be able to check that and display the Unhold button if the viewer is authorized to perform the action 👍

@robertjchen
Copy link
Contributor

robertjchen commented Jul 3, 2024

Backend PR completed and now under review 👍

@robertjchen
Copy link
Contributor

@cdOut Just to clarify that the frontend changes can be done independently without having to wait for the backend, let me know if you have any questions on the flows! 🙇

@cdOut
Copy link
Contributor

cdOut commented Jul 3, 2024

I'll start looking into this one today, I'll let you know if I have any questions.

@parasharrajat
Copy link
Member

Happy to review this PR.

@trjExpensify
Copy link
Contributor Author

Assigning @parasharrajat for the review. @cdOut let us know when the PR is up. Thanks!

@cdOut
Copy link
Contributor

cdOut commented Jul 8, 2024

I'll have a draft PR ready by the EOD.

@cdOut
Copy link
Contributor

cdOut commented Jul 9, 2024

My work on this got delayed due to having to implement some changes after merging the Details Revamp flow for hold/unhold logic, I should have a PR for this today.

Copy link

melvin-bot bot commented Jul 16, 2024

@robertjchen, @trjExpensify, @parasharrajat, @cdOut Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

@cdOut
Copy link
Contributor

cdOut commented Jul 16, 2024

It is in draft, will move through to review by tomorrow.

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Daily KSv2 labels Jul 19, 2024
@robertjchen
Copy link
Contributor

Thanks @cdOut ! Let me know if you need anything else, the backend fixes were deployed 👍

@robertjchen
Copy link
Contributor

robertjchen commented Jul 29, 2024

In progress, some dependencies to be sorted out. Latest update here: #45151 (comment)

@robertjchen
Copy link
Contributor

Finishing touches on the PR, looks on track to be merged later today.

@robertjchen
Copy link
Contributor

Under review/testing, looks like a few final bugs to hammer out, but we're close

@robertjchen
Copy link
Contributor

robertjchen commented Aug 9, 2024

PR was updated and now under review! 🏃

Copy link

melvin-bot bot commented Aug 12, 2024

⚠️ Looks like this issue was linked to a Deploy Blocker here

If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.

If a regression has occurred and you are the assigned CM follow the instructions here.

If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.

@trjExpensify trjExpensify changed the title [Held requests] Clean up the hold/unhold logic [Awaiting Payment 20th August] [Held requests] Clean up the hold/unhold logic Aug 14, 2024
@trjExpensify trjExpensify added Awaiting Payment Auto-added when associated PR is deployed to production and removed Reviewing Has a PR in review labels Aug 14, 2024
@robertjchen
Copy link
Contributor

Closing this out as this was internal, please re-open if we missed anything.

@github-project-automation github-project-automation bot moved this from Release 2: Summer 2024 (Aug) to Done in [#whatsnext] #wave-collect Aug 16, 2024
@parasharrajat
Copy link
Member

@robertjchen C+ payment is pending on this.

@robertjchen robertjchen reopened this Aug 16, 2024
@melvin-bot melvin-bot bot added Daily KSv2 Overdue and removed Weekly KSv2 labels Aug 21, 2024
@robertjchen robertjchen added Weekly KSv2 and removed Daily KSv2 labels Aug 22, 2024
@melvin-bot melvin-bot bot removed the Overdue label Aug 22, 2024
@dylanexpensify
Copy link
Contributor

Payment summary:

Please request on NewDot!

@trjExpensify
Copy link
Contributor Author

Thanks for that, Dylan! With the payment summary done, we can close it now. Thanks!

@parasharrajat
Copy link
Member

payment requested as per #44573 (comment)

@JmillsExpensify
Copy link

$250 approved for @parasharrajat

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Internal Requires API changes or must be handled by Expensify staff Weekly KSv2
Projects
No open projects
Status: Done
Development

No branches or pull requests

7 participants