Show invoice amount and balance on the account invoices page without losing pagination
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 55/100
Research direction
Start by reading the account invoices page implementation and its paginated invoice API calls, then trace how Edit Columns controls visibility. Check how invoice details and loading placeholders are handled elsewhere in the UI. Done means the current page still uses pagination, visible Amount and Balance columns load values for only that page, hidden columns trigger no extra calls, and pagination continues to work.
Written by the indexing model from the issue text.
Description
Background
#329 switched the account invoices page to the paginated account invoices API (see killbill/killbill#1272 and killbill/killbill#1792). Some customers have accounts with hundreds or thousands of invoices and subscriptions, and the page wouldn't load for them before this change.
The paginated API returns shallow invoices with no invoice components. Because of that, the Amount and Balance columns are empty or show 0 on the account invoices page. Users only see the real values after opening each invoice.
Problem
We have two groups of users whose needs conflict:
- Accounts with a large invoice history need the page to load quickly. Fetching every invoice with its components isn't an option for them.
- Most other users expect to see the amount and balance in the invoice list, as they could before #329. One customer has now reported the missing values as a regression.
Proposed Solution
Keep pagination as the default, and fetch amount and balance only for the invoices on the current page:
- Load the page as today. Use the paginated API to get the invoices for the current page.
- Fill in amount and balance for that page only. Once the page is shown, fetch the full details of just those invoices (asynchronously) and populate the Amount and Balance columns. The cost then depends on the page size, not on how many invoices the account has. Show a loading placeholder in those cells while the values load.
- Let users choose the columns in Edit Columns. List Amount and Balance there like the other columns. Users who don't need them can hide them, and Kaui skips the extra calls when they're hidden.
References
- killbill/killbill-admin-ui#329
- killbill/killbill#1272
- killbill/killbill#1792
- Dominant language
- HTML
- Stars
- 70
- Forks
- 76
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 5
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from killbill/killbill-admin-ui
-
Cognito token exchange: log into Kill Bill with the Bearer token (no KB password) and move the exchange into KauiPossibly taken @tungleduyxyz claimed this 4 days ago. Open
Difficulty 5/5 Over a week Newbie friendliness 12/100
killbill/killbill-admin-ui#682 · 1 assignee ·
-
Difficulty 3/5 1-2 days Newbie friendliness 50/100
killbill/killbill-admin-ui#663 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 55/100
killbill/killbill-admin-ui#662 ·
-
Kaui 4.0.1 - viewing catalogMay be free again @tungleduyxyz claimed this 367 days ago, and no pull request is open. Openenhancement
killbill/killbill-admin-ui#556 · 5 comments · 1 assignee ·
-
Difficulty 5/5 Over a week Newbie friendliness 15/100
killbill/killbill-admin-ui#86 · 1 comment ·
All issues in killbill/killbill-admin-ui
Similar issues
-
bug good first issue Image/PDF Annotation TA Grading / TA UI URGENT / PRIORITY
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
Maintainers usually reply within 5 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
zingolabs/zingo-mobile#1951 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
desec-io/desec-stack#1312 ·
Maintainers usually reply within 14 days
-
Unsorted
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
AdguardTeam/AdguardFilters#247699 · 1 comment ·
Maintainers usually reply within 1 day
-
Add AbortController cleanup for fetch() requests in orderbook-tool.tsx and soroban-expiration pageOpenbug frontend low-priority Stellar Wave
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Savitura/Savitools#608 · 1 comment ·
Maintainers usually reply within 6 days