Repository navigation
Conversation
…minders, and quick capture
…nders feat(api): safe-to-spend engine, Goodbudget envelopes, smart email reminders, and quick capture
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a comprehensive "Envelope Budgeting" system, enabling users to visually track, transfer, and fill budget envelopes (categories) on a monthly basis. It adds new database structures, API endpoints, service logic, and automated tests to support envelope transfers, payday allocation, and envelope status tracking.
Envelope Budgeting System Enhancements:
Database schema changes:
Usermodel for payday and household budgeting options, and notification preferences. [1] [2]EnvelopeTransfermodel/table to record transfers between budget envelopes, with supporting indexes and foreign key constraints. [1] [2]API endpoints and controller logic:
/envelopes), transferring funds between envelopes (/transfer), and batch filling envelopes (/fill-envelopes). Corresponding controller methods were implemented to handle these actions. [1] [2] [3]Envelope service logic:
getEnvelopesto calculate per-category envelope status, remaining cash, and recent transfer history for a given month/year.transferEnvelopeFundsto move funds between envelopes atomically, updating limits and recording the transfer with audit logging.fillEnvelopesfor batch allocation of funds to envelopes, supporting both "set" and "add" modes, with audit logging.Validation and schema updates:
Automated tests:
budgetGoals.envelopes.test.ts) covering envelope status calculations and atomic transfers between categories.These changes lay the foundation for robust envelope-based budgeting, supporting user-friendly fund allocation, transfer, and tracking features.