- Network dropdowns now show "Name - CIDR" in both filter bar and add modal
- Port filter accepts comma-separated ports (e.g. "80, 443"); a host must
have ALL listed ports open to match (AND semantics)
- Add host modal has a new "Open ports" field (comma-separated); ports are
registered in the catalog and linked to the host on creation
- Port conditions are inlined as validated integers in SQL (no injection risk)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Implements task #7. The Hosts page provides:
- Name/network/port/application filters (sentinel values instead of
Option<T> to avoid server function serialization issues)
- Configurable page size (15 default, 25/50/100/All)
- Prev/next navigation with total host count
- Add host form with network selector
- Delete action per row
Sub-components (AddHostForm, FilterBar, PaginationBar, HostTable) each
call .into_any() to erase their concrete view types. This breaks the
deeply-nested generic type that caused "queries overflow the depth
limit!" without requiring an unbounded recursion_limit increase.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add src/api/ module with server functions for networks, hosts, applications
- Each server function retrieves the pool via use_context::<AnyPool>()
- Pool is injected via provide_context in two places in main.rs:
* leptos_routes_with_context: for SSR renders and inline server fn calls
* handle_server_fns_with_context on /api/*fn_name: for WASM client calls
- create_host validates IP against network CIDR before inserting
- create_network validates CIDR format before inserting
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>