towerops/lib/towerops_web/controllers
Graham McIntire a2d96f8e6e
Implement hierarchical agent assignment for SNMP polling
Add three-level agent assignment hierarchy (Equipment > Site > Organization)
allowing flexible agent deployment strategies. Agents now receive only equipment
assigned to them through direct assignment or inheritance from site/organization
defaults.

Key changes:
- Add agent_token_id to Sites table with migration
- Implement get_effective_agent_token/1 for hierarchical resolution
- Add list_agent_polling_targets/1 to return polling targets per agent
- Update API config endpoint to use hierarchical polling targets
- Add agent assignment UI to equipment, site, and organization forms
- Show agent source (direct/site/org/none) in equipment form
- Add equipment count column to agent list
- Update terminology from "poll from server" to "cloud polling"

Tests:
- Add 8 comprehensive tests for list_agent_polling_targets/1
- Add end-to-end test for hierarchical config endpoint
- All 775 tests passing
2026-01-14 08:38:50 -06:00
..
api Implement hierarchical agent assignment for SNMP polling 2026-01-14 08:38:50 -06:00
error_html add error pages 2026-01-06 14:37:48 -06:00
page_html separate out marketing layouts 2026-01-06 14:46:39 -06:00
user_registration_html Improve UI styling and remove DaisyUI dependencies 2026-01-03 11:02:38 -06:00
user_session_html add passkey 2026-01-09 12:26:32 -06:00
user_settings_html add passkey 2026-01-09 12:26:32 -06:00
admin_controller.ex Add superuser system with user impersonation for admin support 2026-01-06 12:50:10 -06:00
error_html.ex add error pages 2026-01-06 14:37:48 -06:00
error_json.ex init 2025-12-21 11:10:43 -06:00
health_controller.ex Add /health endpoint for Kubernetes probes 2026-01-04 10:56:03 -06:00
page_controller.ex add marketing site 2026-01-06 14:34:48 -06:00
page_html.ex init 2025-12-21 11:10:43 -06:00
user_credential_controller.ex add passkey 2026-01-09 12:26:32 -06:00
user_registration_controller.ex 1. User Authentication 2025-12-21 13:31:59 -06:00
user_registration_html.ex 1. User Authentication 2025-12-21 13:31:59 -06:00
user_session_controller.ex Streamline login flow and fix test failures 2026-01-13 13:08:24 -06:00
user_session_html.ex 1. User Authentication 2025-12-21 13:31:59 -06:00
user_settings_controller.ex add passkey 2026-01-09 12:26:32 -06:00
user_settings_html.ex 1. User Authentication 2025-12-21 13:31:59 -06:00