Legacy Tenancy Dashboard Alerts
Legacy Tenancy Dashboard Alerts
The agent dashboard surfaces colour-coded alert panels for legacy (off-platform) tenancies that need action. Alerts appear automatically at the top of the dashboard and disappear when no action is required.
Overview
When an agent adds a legacy tenancy, the platform tracks its lifecycle and flags it for attention based on end-date proximity and move-in status. The dashboard now makes these flags visible without the agent needing to navigate to the tenancy list.
Alert Categories
🔴 Past End Date (Critical)
Condition: An active legacy tenancy has passed its end date.
What to do: Open the tenancy and use the Action Renewal button to either renew the tenancy or formally end it.
🟡 Ending Soon (Warning)
Condition: An active legacy tenancy ends within the next 90 days.
What to do: Open the tenancy and begin the renewal or end process. Each row shows the number of days remaining.
🔵 Pending Move-In (Informational)
Condition: A pending legacy tenancy has a future start date and move-in has not been confirmed.
What to do: Open the tenancy and use the Confirm Move-In button once the tenant has arrived.
How the Panel Works
- The panel renders at the top of the agent dashboard, above KPIs.
- It is hidden automatically when
totalCountis zero — no empty states are shown. - Each alert section lists up to 10 tenancies. If more exist, navigate to the full tenancy list.
- Each row is a direct link to the tenancy detail page (
/dashboard/tenancies/{id}). - Sections are ordered by urgency: Past End Date → Ending Soon → Pending Move-In.
Legacy Tenancies Metrics Card
A Legacy Tenancies card in the portfolio metrics grid provides a quick count summary:
| Stat | Description |
|---|---|
| Pending move-in | Tenancies awaiting move-in confirmation |
| Renewal / end needed | Tenancies past end date or ending within 90 days |
The card only appears when the organisation has at least one legacy tenancy.
Typical Workflow
- Agent creates a legacy tenancy using the Add Legacy Tenancy wizard.
- The system automatically confirms historical move-in dates.
- If the tenancy end date is within 90 days, a renewal record is auto-created.
- The dashboard surfaces the tenancy in the appropriate alert section.
- The agent clicks through to the tenancy detail page.
- The agent uses Action Renewal (to renew via the fixed-term renewal wizard, or to end the tenancy) or Confirm Move-In as appropriate.
API Reference
The alert data is fetched via the dashboard.legacyAlerts tRPC query.
Request
const { data } = trpc.dashboard.legacyAlerts.useQuery();
No input parameters are required. The procedure is scoped to the authenticated organisation.
Response Shape
type TenancySummary = {
id: string;
propertyAddress: string | null;
tenantName: string | null;
startDate: Date | string | null;
endDate: Date | string | null;
};
type LegacyAlertsResponse = {
pastEnd: TenancySummary[]; // active tenancies past their end date
endingSoon: TenancySummary[]; // active tenancies ending within 90 days
pendingMoveIn: TenancySummary[]; // pending tenancies with a future start date
totalCount: number; // sum of all three lists
};
Each list contains at most 10 items.
portfolioMetrics — legacy field
The existing dashboard.portfolioMetrics procedure now includes a legacy aggregate:
legacy: {
total: number; // all legacy tenancies for the org
pendingMoveIn: number; // pending with future start date
needingAction: number; // pastEnd + endingSoon combined
}
Notes
- Periodic tenancies (no fixed end date) are excluded from the
pastEndandendingSooncategories. - Ended tenancies (status
ended) are excluded from all alert categories. - An end date of exactly today is classified as Past End Date.