package views import "vctp/components/core" type SnapshotEntry struct { Label string Link string Count int64 Group string } type VcenterLink struct { Name string Link string } type VcenterTotalsEntry struct { Snapshot string RawTime int64 VmCount int64 VcpuTotal int64 RamTotalGB int64 } type VcenterTotalsMeta struct { ViewType string TypeLabel string HourlyLink string DailyLink string MonthlyLink string HourlyClass string DailyClass string MonthlyClass string } type VcenterChartData struct { ConfigJSON string } templ SnapshotHourlyList(entries []SnapshotEntry) { @SnapshotListPage("Hourly Inventory Snapshots", "inventory snapshots captured hourly", entries) } templ SnapshotDailyList(entries []SnapshotEntry) { @SnapshotListPage("Daily Inventory Snapshots", "daily summaries of hourly inventory snapshots", entries) } templ SnapshotMonthlyList(entries []SnapshotEntry) { @SnapshotListPage("Monthly Inventory Snapshots", "monthly summary aggregated from daily snapshots", entries) } templ SnapshotListPage(title string, subtitle string, entries []SnapshotEntry) { @core.Header()
Snapshot Library

{ title }

{ subtitle }

Back to Dashboard

Available Exports

{ len(entries) } files
for i, entry := range entries { if entry.Group != "" && (i == 0 || entries[i-1].Group != entry.Group) { } }
Snapshot Records Download
{ entry.Group }
{ entry.Label }
{ entry.Count } records Download XLSX
@core.Footer() } templ VcenterList(links []VcenterLink) { @core.Header()
vCenter Inventory

Monitored vCenters

Select a vCenter to view snapshot totals over time.

Back to Dashboard

vCenters

{ len(links) } total
for _, link := range links { }
vCenter Totals
{ link.Name } View Totals
@core.Footer() } templ VcenterTotalsPage(vcenter string, entries []VcenterTotalsEntry, chart VcenterChartData, meta VcenterTotalsMeta) { @core.Header()
vCenter Totals

Totals for { vcenter }

{ meta.TypeLabel } snapshots of VM count, vCPU, and RAM over time.

{ meta.TypeLabel } Snapshots

{ len(entries) } records
if chart.ConfigJSON != "" {
}
for _, entry := range entries { }
Snapshot Time VMs vCPUs RAM (GB)
{ entry.Snapshot } { entry.VmCount } { entry.VcpuTotal } { entry.RamTotalGB }
@core.Footer() }