Repository navigation
feat(members): every fee-table column is filterable + sortable (spec 50) - #285
Merged
Merged
Conversation
…50 R14) Only the membership-type column was wired to the shared table framework; the money, period and status columns were plain `<Th>` cells. - `buildFeeRows` now derives the framework fields per row: `registrationText` / `currentFeeText` (currency-free decimals, so filtering "12" works), `registrationValue` / `currentFeeValue` (numbers — `useTableSort` only compares numbers numerically), `currentRange` / `currentStart` (range text + ISO start for chronological sort), and `statusKey` / `statusRank` (enum filter + semantic order: current -> planned-only -> not configured). Cells keep rendering formatted money. - `MembershipFeesEditor`: `FilterableHeader` on all five columns (money + period as text filters, status as an enum `Select`), default sort = type asc; the status badge now reads `row.statusKey`. - tests: model 18 -> 21 (framework fields incl. future-only), editor 8 -> 12 (five sortable headers + the three filter controls, money filter, numeric current-fee sort, status enum filter). - spec: design "Every column is filterable + sortable", tasks 11.2/11.3. Verified: vitest 40 passed (model 21, editor 12, translations 7), `tsc --noEmit` clean, eslint clean.
This was referenced Nov 30, 2026
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.
Only the membership-type column was wired to the shared table framework (
FilterableHeader+useFilterableTable) - the money, period and status columns were plain<Th>cells.All five columns are now filterable and sortable:
label12)registrationValue(numeric)77.9)currentFeeValue(numeric)2026)currentStart(ISO -> chronological)statusRank(semantic order)Why derived fields:
useTableSortonly compares values numerically when both are numbers, so sorting formatted money strings would be lexicographic; and filtering must not depend on the currency symbol. The row model now carriesregistrationText/Value,currentFeeText/Value,currentRange,currentStart,statusKey/Rank; cells keep rendering the formatted money. Rows without a value sort last (framework nullish rule). Default sort: type name asc.Tests: model 18 -> 21, editor 8 -> 12 (five sortable headers, money filter, numeric current-fee sort, status enum filter) = 40 passed;
tsc --noEmitclean; eslint clean.