Skip to content

Conversation

@DavidAmunga
Copy link
Owner

Add Optional Charges/Fees Sheet to Excel Exports

Overview

This PR adds a new optional export feature that creates a separate "Charges & Fees" sheet when exporting M-Pesa statements to Excel format. This enhancement helps users better analyze their transaction fees and charges.

What's New

  • New Export Option: Checkbox to include "Charges/Fees Sheet" when Excel format is selected

Service Layer Updates

  • ExportService: Updated to pass export options through the service chain
  • XlsxService: Enhanced to generate additional sheets based on options
    • New addChargesSheet() method for creating the charges worksheet

Testing Scenarios

  • Excel export with charges sheet enabled
  • Excel export with charges sheet disabled
  • CSV export (no charges option shown)
  • Format switching maintains option state
  • Empty charges (no sheet created if no charges found)

Screenshots

Add screenshots showing:

  1. New checkbox option in the export UI
CleanShot 2025-09-25 at 9  56 29@2x 2. Generated Excel file with both sheets CleanShot 2025-09-25 at 9  57 23@2x

Benefits for Users

  • Better Financial Awareness: Clear visibility into M-Pesa fees and charges

Backward Compatibility

  • Existing CSV exports unchanged
  • Default Excel exports unchanged (charges sheet is optional)
  • No breaking changes to existing APIs

@DavidAmunga DavidAmunga self-assigned this Sep 25, 2025
@DavidAmunga DavidAmunga merged commit 5d487d1 into main Sep 25, 2025
5 checks passed
@DavidAmunga DavidAmunga deleted the feat/add-charges-export-option branch September 26, 2025 15:19
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.

2 participants