Repository navigation
rc.49: Voters list default columns from realm user-profile annotations (meta#15619) - #4683
Merged
Merged
Conversation
…#15619) An election event's Voters tab now takes its default visible columns from the realm's user profile: attributes annotated `"voterListColumn": "default"` are shown, plus the fixed Enabled, Username, Area, ID validated?, Voted and Actions columns; every other column stays available through Columns. Without any annotation the table keeps its previous defaults (or the VOTER_COLUMNS_PROFILE setting's). An operator's own column selection is carried over to the new grid key, as before. The COMELEC realm template annotates firstName, lastName, middleName and dateOfBirth. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. 🗂️ Base branches to auto review: 2
Please check the settings in the CodeRabbit UI or the
|
edulix
added a commit
that referenced
this pull request
Dec 3, 2026
Restores code that the squash of #4680 (3a08ae0) reverted on `ovcs`. **Cause.** #4680 merged ovcs (335506a) into its branch in feab331. That merge resolution kept the branch's older copies of 49 files, and the squash then applied those older copies to ovcs. The reverted work: - **#4563** tenant reset (the administration tenant's reset keeps or deletes other tenants, Gold, b4 bodies and custom URLs): `tenant_reset/*`, `reset_tenant.rs`, `delete_tenant.rs`, `delete_election_event.rs`, `custom_url.rs`, `cloudflare.rs`, `TenantResetCard*`, translations, devcontainer compose, tests. - **#4682** Statistical Report, bulk Post vote receipts, audit-log hash-chain check: `reports/*`, electoral-log adapters and tests, report templates, Tabs, docs. - **#4683** Voters list default columns: `voterDefaultColumns*`, `ListUsers.tsx`, COMELEC `keycloak.hbs` annotations. #4684–#4687 were not affected; the squash's 3-way merge kept them. **Fix.** - The 49 files are restored byte-for-byte from `3a08ae0^` (cfd675a). None of them carried #4680 changes. - #4680's own changes (label rules, migration, checks, tests, docs) are unchanged. The tree equals cfd675a plus #4680's own commits bac670c and 8af66ee, except the tgz. - The sequent-core WASM tgz files and yarn.lock are regenerated: electoral-log, which this PR restores, is one of the package's inputs. Built with rustc 1.96.0, wasm-bindgen 0.2.128 and wasm-opt 123. **Checks.** - `scripts.dev.wasm --check-package` passes. - `cargo check -p electoral-log -p windmill -p harvest --tests` passes. meta#15602 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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.
Refs sequentech/meta#15619 (rc.49 tracker sequentech/meta#15576).
What
On an election event's Voters tab, the default visible columns now come from the realm's user profile instead of being hard-coded:
"annotations": {"voterListColumn": "default"}are shown by default.sequent.read-only.id-card-number-validated), Voted, Actions.Backwards compatible: with no annotated attribute, the table keeps its previous defaults, or the
VOTER_COLUMNS_PROFILEsetting's profile (meta#15530) if one is set. Users and Roles (no election event) is unchanged.Operator overrides kept: the annotated set gets its own grid key (
..._realm_<hash>), and an operator's explicit column selection is carried over once, as the existing profile mechanism already does (carryVoterColumnSelection).Changes
admin-portal/src/resources/User/voterDefaultColumns.ts:VOTER_LIST_COLUMN_ANNOTATION,isDefaultVoterListColumn,realmVoterColumns()(builds aVoterColumnProfilefrom the realm's attributes).ListUsers.tsx: realm profile first, then the setting's profile; the grid waits for the user profile before mounting on the Voters tab.janitor/templates/COMELEC/keycloak.hbs: annotatesfirstName,lastName,middleName,dateOfBirth.keycloak_event_realm) carries the same four annotations.Existing deployments
Either re-import the event realm from the updated Sheet/template, or in the Keycloak admin console: Realm settings → User profile → (attribute) → Annotations → Add key
voterListColumn, valuedefault, for First name, Last name, Middle name and Date of birth. Reload the admin portal.Tests
npx jest src/resources/User/voterDefaultColumns(in docker, node:20): 23 passed, including new cases with annotations (exact shown/hidden sets, unannotated first/last name hidden, annotated Elections kept, per-set grid key + carried selection) and without (no profile, previous defaults unchanged).🤖 Generated with Claude Code