Uploaded image for project: 'mod-finance'
  1. mod-finance
  2. MODFIN-86

Restrict adjustment of budget's allowableEncumbrance and allowableExpenditures

    XMLWordPrintable

Details

    • Story
    • Status: Closed (View Workflow)
    • P3
    • Resolution: Done
    • None
    • 2.0.0
    • None
    • ACQ Sprint 82, ACQ Sprint 83
    • 2
    • Thunderjet

    Description

      Overview

      Before allowing a user to adjust a budget's allowableEncumbrance and allowableExpenditure values, we need to make sure the new limits aren't already exceeded. If they are we must reject the update and return an appropriate error.

      • If adjusting allowableEncumbrance, first check that the amount (encumbered + awaitingPayment) isn't already over the new value.
      • If adjusting allowableExpenditures, first check that the amount (expended + awaitingPayment) isn't already over the new value.
      if ((allocated * newAllowableEncumbrance) < (encumbrance + awaitingPayment) 
        reject
      else 
        apply update
      
      if ((allocated * newAllowableExpenditure) < (awaitingPayment + expended)) 
        reject
      else 
        apply update
      

      Acceptance Criteria

      • The checks described above are put in place
      • unit tests are updated
      • API tests are updated

      TestRail: Results

        Attachments

          Issue Links

            Activity

              People

                cmcnally Craig McNally
                cmcnally Craig McNally
                Craig McNally Craig McNally
                Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  TestRail: Runs

                    TestRail: Cases