Skip to content

Feature/recurring expenses and subscriptions#1

Merged
nadeemnali merged 10 commits intomainfrom
feature/recurring-expenses-and-subscriptions
Mar 31, 2026
Merged

Feature/recurring expenses and subscriptions#1
nadeemnali merged 10 commits intomainfrom
feature/recurring-expenses-and-subscriptions

Conversation

@nadeemnali
Copy link
Copy Markdown
Owner

No description provided.

nadeemnali and others added 10 commits March 31, 2026 20:33
- Implement RecurringExpense struct with all required fields
- Add RecurrenceFrequency enum supporting 5 frequency options
- Implement helper methods: nextDueDate(), shouldGenerate(), yearlyAmount
- Add date validation and status checking
- Implement Codable for persistence support

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Implement RecurringExpenseStore with CRUD operations
- Add filtering methods: activeRecurringExpenses, subscriptions
- Implement amount calculations: monthlyRecurringAmount, totalYearlyAmount
- Add dueSoon() for upcoming bills
- Persist data to UserDefaults with error handling
- Auto-save on changes using Combine publishers

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Implement RecurringExpensesView with summary card
- Add AddRecurringExpenseView for creating new recurring expenses
- Add EditRecurringExpenseView for modifying existing expenses
- Include frequency selection, date picking, notification settings
- Add FormFieldLabel component for consistent form styling
- Display monthly/yearly projections and active status

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Implement BillReminderService for scheduling local notifications
- Support configurable reminder timing (1-7 days before)
- Handle notification permissions with user callbacks
- Auto-schedule reminders for all active recurring expenses
- Support removal of individual and all pending reminders
- Query pending notifications for status checking

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Implement autoGenerateRecurringExpenses() in ExpenseStore
- Add daily auto-generation check (max once per day)
- Smart date comparison to avoid duplicate expenses
- Respect start and end dates of recurring expenses
- Add generated expense notes to track recurring source
- Maintain data integrity with UserDefaults caching

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Add exportDataAsCSV() function for exporting all expenses
- Implement CSV formatting with proper escaping
- Handle special characters (commas, quotes, newlines)
- Use UIActivityViewController for sharing CSV file
- Generate timestamped filename for exports
- Integrate export button into Settings Data section

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Add RecurringExpenseStore to ExpenseFlowApp
- Setup notification permissions on app launch
- Auto-generate recurring expenses daily
- Add UserNotifications import for notification support
- Add currencyString() helper to Formatters for currency formatting
- Ensure all stores initialized and synchronized

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Regenerate project with xcodegen
- Add new source files to build targets
- Configure test target with GENERATE_INFOPLIST_FILE
- Update project.yml with test bundle configuration
- Maintain compatibility with iOS 16.0+

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Add RecurringExpenseTests (13 test cases)
  - Test frequency calculations and next due dates
  - Validate yearly amount calculations
  - Test date comparison logic
  - Verify persistence and encoding/decoding

- Add RecurringExpenseStoreTests (14 test cases)
  - Test CRUD operations (create, read, update, delete)
  - Validate data persistence to UserDefaults
  - Test filtering and sorting
  - Verify store initialization and updates

- Add BillReminderServiceTests (9 test cases)
  - Test notification scheduling and removal
  - Validate permission request flow
  - Test pending notification queries
  - Verify identifier generation

- Add CSVExportTests (10 test cases)
  - Validate CSV format and headers
  - Test special character escaping
  - Verify field quoting rules
  - Test real-world scenarios

Total: 46+ unit tests covering all new functionality

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Document all features added (recurring expenses, subscriptions vault, bill reminders, CSV export, auto-generation)
- Include test coverage summary (46+ test cases)
- Add competitive analysis table vs Mint, YNAB, Goodbudget, PocketGuard, Spendee
- List all 10 commits with descriptions
- Provide deployment notes and reviewer focus areas
- Ready for GitHub PR submission

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@nadeemnali nadeemnali merged commit a66fd38 into main Mar 31, 2026
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant