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

B 20940 disbursement #13696

Merged
merged 14 commits into from
Sep 12, 2024
Merged

B 20940 disbursement #13696

merged 14 commits into from
Sep 12, 2024

Conversation

antgmann
Copy link
Contributor

B-20940

INT PR 1
INT PR 2

Summary

B-20940 introduces a disbursement calculation for the SSW, only when a Payment Packet is being created. Please consult the agility backlog item description for the overview of the calculation. Additionally, it is accompanied by a test that checks both methods of calculation, as well as ensuring the Member value cannot be less than 0. This also cleans up an incorrectly named orders value.

Verification Steps for the Author

These are to be checked by the author.

  • Have the Agility acceptance criteria been met for this change?

Verification Steps for Reviewers

These are to be checked by a reviewer.

  • Has the branch been pulled in and checked out?
  • Have the BL acceptance criteria been met for this change?
  • Was the CircleCI build successful?
  • Has the code been reviewed from a standards and best practices point of view?

How to test

  1. Access the app as a service member.
  2. Create a new move.
  3. When setting up shipments, create 2 PPMs.
  4. The details don't matter too much here, since we don't use the AOA packet. Submit the shipments.
  5. Once the moves are submitted, log in as a service counselor and approve the shipments.
  6. Log back in as a service member.
  7. For both moves, begin the closeout process by finishing the weight ticket you're prompted to do.
  8. Once you get the option to add expenses, we'll need to do two different types for our shipments.
  9. For one shipment, add an expense with a type of Oil, paid with GTCC. Make the value small, such as $50.
    Then, add another expense type of Storage, with a larger cost, NOT paid with GTCC.
    This triggers our "A" calculation, making GTCC the amount of your oil expense, and allows us to verify member disbursement cannot be less than 0.
  10. For the other shipment, add a storage expense not paid with GTCC in a small amount, such as $30.
    Then, add more expensive GTCC expenses. Member disbursement will still be 0 as in the calculation, the member paid storage will cancel out.
    However, this triggers our "B" calculation where the GTCC value will be the amount of the member storage expense.
  11. Note: The above instructions assume ppmRemainingEntitlement == 0, per the note above.
  12. Once the expenses are configured, submit them.
  13. Log back in as a service counselor, approve the expenses.
  14. Once the shipment is closed out, download the packet and verify your values against the calculation.

Backend

Screenshots

image

@antgmann antgmann marked this pull request as ready for review September 11, 2024 20:09
@antgmann antgmann requested a review from a team as a code owner September 11, 2024 20:09
@antgmann
Copy link
Contributor Author

Going to need to correct a failing test resulting from the latest main merge, regarding the PPM Remaining Entitlement. This change was made as part of merge conflict resolutions on the INT PR already, so no change to INT will be necessary:
image

Copy link
Contributor

@traskowskycaci traskowskycaci left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seeing a change to pkg/models/worksheet_shipment.go in the first integration PR, but I don't see that file as existing in main yet. When would this change go into main, if not this PR?

image

Copy link
Contributor

@MInthavongsay MInthavongsay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

@traskowskycaci
Copy link
Contributor

Seeing a change to pkg/models/worksheet_shipment.go in the first integration PR, but I don't see that file as existing in main yet. When would this change go into main, if not this PR?

image

Talked with Anthony via slack and got clarification - pkg/models/worksheet_shipment.go was created as part of @TevinAdams work on B-20947 so we will just want to make sure that change from unit.Pound to float64 makes it into Tevin's main PR https://github.com/transcom/mymove/pull/13594/files#diff-0062207dd5e2a86a57f6555b5ff0a71c6f26c09efc6dcd760061c54a738a70c5

@r-mettler r-mettler merged commit 402f356 into main Sep 12, 2024
41 checks passed
@r-mettler r-mettler deleted the B-20940-Disbursement branch September 12, 2024 17:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

5 participants