feat: grant "eForm users" full planning view when no manager exists#1490
Merged
renemadsen merged 1 commit intostablefrom Apr 21, 2026
Merged
Conversation
When no AssignedSite has IsManager=true anywhere in the tenant, promote users in the "eForm users" security group to the admin-for-visibility branch of TimePlanningPlanningService.Index so the planning dashboard isn't empty in that degenerate state. Composite "Kun tid + WebAccess" users (added to both groups by BackendConfigurationAssignmentWorker\ ServiceHelper) are explicitly excluded and stay restricted to own site. Co-Authored-By: Claude Opus 4.7 <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.
Summary
TimePlanningPlanningService.Index: when noAssignedSitehasIsManager=truesystem-wide, users in the "eForm users" security group are promoted to the admin-for-visibility path so the planning dashboard isn't empty in that degenerate state.BackendConfigurationAssignmentWorkerServiceHelper) are explicitly excluded and stay restricted to their own site — honoring the rule that "kun tid" users must only see their own time.isAdmin = eFormAdminsGroup) is preserved; the fallback only fires when that gate fails.TimePlanningPlanningService.Index.TimeSettingService.GetAvailableSitesandAbsenceRequestService.GetInboxAsyncare untouched.Test plan
AssignedSite.IsManager=truerows, log in as a non-admin user in "eForm users" → Time Planning > Plannings shows all workers.AssignedSite.IsManager=true(via property-worker UI) → same user now sees only their own site.timeRegistrationEnabled=true) in the same zero-manager tenant → still restricted to own site.adminrole) flow unchanged — sees all workers regardless.🤖 Generated with Claude Code