Skip to main content
Source snapshot: 13 October 2026. These pages describe the current implementation, including unfinished controls. See coverage and review notes.

Division profile

Host: admin.<ROOT_DOMAIN> · Route: /[tenant]/divisions/[divisionId]

Purpose and access

Inspect the households and residents of one subdivision.You need an account session and a resolved membership context in the selected Mahallu (including the API’s current platform elevation path). The API independently checks the requested operation’s permissions and feature availability.

Screen layout

The record screen contains division information, families/members roster tabs, search, Add family, and Assign family controls.

Fields and displayed information

Fields and filters: Division detail view

Fields and filters: Add family dialog

Fields and filters: Assign family dialog

Actions

Linked navigation

Interaction sequence

Open a division → switch between families and members → search the active roster. Add family starts intake in this division; Assign family links an existing household through its assignment dialog.

States and rules

The detail route resolves its division and associated data within the tenant. Missing records use notFound. Changing the roster tab changes the search context; it does not alter membership.Explicit validation messages in the rendered forms:
  • Please provide the Applicant / Househead Name.
  • Please provide the primary contact phone number.
  • Failed to load existing families.
The rendered action controls bind loading indicators to pending state. Failed API saves keep their documented error/notification path; a loading indicator alone does not establish persistence.

Implementation references

Paths below are relative to the application repository. This is source-reviewed behavior, not a recorded browser test.
  • apps/web/src/app/sites/admin/[tenant]/divisions/[divisionId]/page.tsx
  • apps/web/src/features/tenants/division-detail-view.tsx
  • apps/web/src/features/tenants/add-family-dialog.tsx
  • apps/web/src/features/tenants/assign-family-dialog.tsx
Data and access helpers: apps/web/src/lib/structure.ts, apps/web/src/lib/server-api.ts, apps/web/src/lib/business-resources.ts, apps/web/src/lib/houses.ts, apps/web/src/lib/members.ts, apps/web/src/lib/api-client.tsRelevant controller permission keys: structure.view, structure.update, families.view, families.create, families.update, families.delete. Keys are operation-specific; the current guard grants OWNER/ADMIN and its platform-elevation context an operational bypass. A visible control still does not establish authorization.

API behavior references

  • apps/api/src/structure/structure.controller.ts
  • apps/api/src/families/families.controller.ts