Skip to content

[Frontend] Properties list screen + assigned staff (Part 2 of 2 — #356) #550

Description

@CRamsan

Part of #356. See also #549 — the backend + RLS slice this issue depends on merging first.

Goal

Make "the Properties page" actually show every property in the user's active organization as a browsable list (gated Admin+ to add, Manager+ to open detail), and show each property's assigned manager/security/cleaning staff on its detail screen.

Why this is its own PR

Backend Kotlin and frontend Compose are rarely reviewed in the same pass, and this slice needs the backend slice's endpoints live first. Splitting keeps each PR independently reviewable and revertible.

Background

What's actually wired in today as "the Properties page" (PropertyHomeScreen) is not a list screen — it's a name-only dropdown selector used to pick one "active" property, whose content area shows an event log for that property. There is no card-based list of properties in the app today.

PropertyDetailScreen already shows icon, name, address, edit, and delete. What's missing is the assigned-staff section.

Two older HTML mocks exist for this area but model more than this issue asks for (grouped/collapsible list, tabbed Units/Common Areas detail) — overlapping separate issues (#398, #386, #422). This work descopes to exactly what's needed here: a flat list and a single-page detail screen with a staff section added, no tabs. The mocks will be refined to match before implementation.

Scope

  • New PropertyListScreen — flat list of all org properties (name, address), FAB to add a property (Admin+ only), tap to open detail (Manager+ only, otherwise an inline access message).

  • PropertyDetailScreen gains an assigned-staff section, labeled by role (Manager / Security / Security Cover / Cleaning), or an explicit "no staff assigned" state.

  • PropertyListScreen replaces PropertyHomeScreen as the Properties tab's content. The old screen/ViewModel and the backend slice's interim compatibility shim are deleted as part of this work, not left as dead code.

Known regression (flagged intentionally, not silently accepted)

PropertyHomeScreen is currently the only entry point to its event log view (and a fallback screen for users with zero properties). Replacing it with a flat list removes that entry point with no replacement in this PR — re-homing it needs its own design decision and is tracked as a separate follow-up issue, filed alongside this one.

Acceptance Criteria

  • The Properties tab shows every property in the active org as a flat list, not just properties individually assigned to the current user.
  • The add-property FAB is visible only to Admin-or-higher users.
  • Tapping a property card opens the detail screen for Manager-or-higher users; shows an inline access message otherwise.
  • The detail screen shows assigned staff by role, or an explicit empty state.
  • Loading, error, and empty-org states are handled.
  • The old property-switcher screen and its ViewModel/UI model are deleted.
  • The follow-up issue for re-homing the event log entry point is filed (see below), and the PR description calls out the interim regression explicitly.

Dependencies

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions