Skip to content

feat(finance): display organization fiat balance in navbar and finance page#448

Merged
codeZe-us merged 4 commits into
SafeVault:devfrom
Shadow-MMN:feat/org-fiat-balance-display
Apr 28, 2026
Merged

feat(finance): display organization fiat balance in navbar and finance page#448
codeZe-us merged 4 commits into
SafeVault:devfrom
Shadow-MMN:feat/org-fiat-balance-display

Conversation

@Shadow-MMN
Copy link
Copy Markdown

@Shadow-MMN Shadow-MMN commented Apr 26, 2026

Pull Request

Summary

This PR implements the display of the organization’s real fiat balance across the dashboard. The balance is fetched from the backend organization_fiat_balances record (stored in kobo), converted to NGN, and formatted consistently for display in both the navbar and the finance overview page.

A reusable utility was introduced to ensure consistent currency formatting across the application.


Type of Change

  • Feature
  • Bug Fix
  • Refactoring
  • Documentation
  • Tests
  • Infrastructure / CI

Linked Issues

Closes #434


Key Changes

  • Added getOrganizationFiatBalance service method to fetch fiat balance from the database
  • Created reusable utility formatNairaFromKobo for consistent NGN formatting
  • Added new API endpoint: GET /api/v1/finance/balance
  • Integrated balance display into dashboard navbar via AppShellDesktopHeader
  • Displayed balance in finance overview page (BalanceSection)
  • Added graceful fallback for missing or failed balance fetch (₦0.00)
  • Ensured consistent conversion from kobo to NGN across UI layers

Checklist

  • I have performed a self-review of my code.
  • I have commented my code, particularly in hard-to-understand areas.
  • My changes generate no new linting/type-checking warnings.
  • I have added tests that prove my fix is effective or that my feature works.
  • I have updated the documentation accordingly.

Screenshots / Recordings

Closes #434

@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 26, 2026

Someone is attempting to deploy a commit to the vestroll's projects Team on Vercel.

A member of the Team first needs to authorize it.

@codeZe-us
Copy link
Copy Markdown
Contributor

@Shadow-MMN is the PR ready for review or is it a work in progress

@Shadow-MMN
Copy link
Copy Markdown
Author

Shadow-MMN commented Apr 26, 2026

@Shadow-MMN is the PR ready for review or is it a work in progress

Still in progress,I will be done by night time or tomorrow

@Shadow-MMN Shadow-MMN marked this pull request as ready for review April 26, 2026 21:47
@Shadow-MMN
Copy link
Copy Markdown
Author

@codeZe-us we can check it out now

@codeZe-us codeZe-us self-requested a review April 28, 2026 12:18
@codeZe-us
Copy link
Copy Markdown
Contributor

@Shadow-MMN the PR points to main, it should point to dev

@Shadow-MMN
Copy link
Copy Markdown
Author

@Shadow-MMN the PR points to main, it should point to dev

Ok let me correct that

@Shadow-MMN Shadow-MMN changed the base branch from main to dev April 28, 2026 12:29
@Shadow-MMN
Copy link
Copy Markdown
Author

@codeZe-us I am done

@codeZe-us codeZe-us merged commit 4944339 into SafeVault:dev Apr 28, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Display Organization Fiat Balance

2 participants