Where the picker lives
The picker is the component <app-location-picker-inline>. It appears in the page header on most admin pages and in the calendar header on the schedule. The control shows the name of the currently selected branch followed by a chevron.
Clicking the chevron opens a popover called popover-locations that lists the branches you can access. Branches outside your permission set are either disabled or hidden, so the list is always a safe set of choices.
If you have the AllLocations permission, the popover also surfaces an All locations option at the top of the list for viewing global, cross-branch data.
How switching works
The popover is a radio list, so you can choose only one branch at a time. Selecting a branch calls locationStore.selectLocation(id, true), which performs three steps in order:
- Updates the active location signal in memory so all open computed signals re-read.
- Persists the selection to IndexedDB so the choice survives a reload and a new tab.
- Triggers a full page reload so server-rendered data is fetched fresh for the new branch.
The reload is intentional. It guarantees that lists, filters, and any in-flight requests are restarted against the new branch and that you never see a half-mixed view.
When the picker is locked
If your account only has one accessible branch, the picker renders in a locked state. The branch name is still visible so you know which site you are viewing, but the chevron is disabled and the popover will not open.
This protects single-site staff from accidentally landing on a branch they have no permission for. It also keeps the UI simple for accounts that have not enabled the multi-location feature at all.
- One accessible branch: locked, no chevron action.
- Multiple accessible branches: chevron opens the radio list.
- AllLocations granted: All locations appears as an extra option.
