feat(contracts): show allotment headline and edit allotted hours from detail view #257

Merged
vas2000-work merged 1 commit from feat/mapps-255-contract-allotment-edit into main 2026-06-17 23:01:36 +02:00
Owner

Surface the current-period allotted/remaining hours as a headline on the contract detail Hour Balance card and let managers edit the allotment in place. The headline derives "X of Y hours remaining" from the most-recently-started period in balance_resource, above the existing per-period table which still lists Included / Used / Remaining / Rollover.

Add an "Edit Allotment" control (billing-gated, shown only when a block_hours line item exists) that opens a modal editing that item's included_hours via a full-replace PUT through UpsertContractItemRequest, preserving every other field so the allotment changes without re-creating the line item. On save, both the balance and items resources refresh so the new remaining balance shows immediately.

#MAPPS-255

Surface the current-period allotted/remaining hours as a headline on the contract detail Hour Balance card and let managers edit the allotment in place. The headline derives "X of Y hours remaining" from the most-recently-started period in balance_resource, above the existing per-period table which still lists Included / Used / Remaining / Rollover. Add an "Edit Allotment" control (billing-gated, shown only when a block_hours line item exists) that opens a modal editing that item's included_hours via a full-replace PUT through UpsertContractItemRequest, preserving every other field so the allotment changes without re-creating the line item. On save, both the balance and items resources refresh so the new remaining balance shows immediately. #MAPPS-255
feat(contracts): show allotment headline and edit allotted hours from detail view
All checks were successful
Check / clippy + fmt + tests (pull_request) Successful in 2m52s
Create release / Create release from merged PR (pull_request) Has been skipped
c95d5b4378
Surface the current-period allotted/remaining hours as a headline on the contract detail Hour Balance card and let managers edit the allotment in place. The headline derives "X of Y hours remaining" from the most-recently-started period in balance_resource, above the existing per-period table which still lists Included / Used / Remaining / Rollover.

Add an "Edit Allotment" control (billing-gated, shown only when a block_hours line item exists) that opens a modal editing that item's included_hours via a full-replace PUT through UpsertContractItemRequest, preserving every other field so the allotment changes without re-creating the line item. On save, both the balance and items resources refresh so the new remaining balance shows immediately.

#MAPPS-255
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
psa-systems/mokosh-apps!257
No description provided.