fix(20): add SNMP profiles settings link and device_count to profile list

Adds SNMP Device Profiles card to SettingsPage for discoverability.
Adds device_count correlated subquery to profile list SQL and schema
field so the frontend profile cards show accurate device counts.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Jason Staack
2026-03-21 20:41:04 -05:00
parent 2c74783f17
commit f6fb206d4d
3 changed files with 29 additions and 5 deletions

View File

@@ -167,6 +167,23 @@ export function SettingsPage() {
</div>
)}
{/* SNMP Profiles */}
{isTenantAdmin(user) && (
<div className="rounded-lg border border-border bg-panel px-4 py-3 space-y-1">
<SectionHeader icon={Monitor} title="SNMP Profiles" />
<Link
to="/settings/snmp-profiles"
className="flex items-center justify-between py-2 px-1 rounded hover:bg-elevated/30 transition-colors group"
>
<div>
<span className="text-sm text-text-primary">SNMP Device Profiles</span>
<p className="text-xs text-text-muted">Manage OID collection profiles, upload MIBs, test against live devices</p>
</div>
<ChevronRight className="h-4 w-4 text-text-muted group-hover:text-text-primary transition-colors" />
</Link>
</div>
)}
{/* Maintenance — super_admin only */}
{isSuperAdmin(user) && (
<div className="rounded-lg border border-border bg-panel px-4 py-3 space-y-1">