Show collapsible IP check cycles in the registry
This commit is contained in:
1 parent
94124747ce
commit
b58d5f5b82
16 files changed
+332
-36
No files matched your search
@@ -122,8 +122,13 @@ type ipsPageData struct {
|
||||
|
||||
type ipDetailData struct {
|
||||
PageData
|
||||
Detail ipDetailResponse
|
||||
Events []eventView
|
||||
ipDetailView
|
||||
}
|
||||
|
||||
type ipDetailView struct {
|
||||
Detail ipDetailResponse
|
||||
Events []eventView
|
||||
HasQueueData bool
|
||||
}
|
||||
|
||||
// tracerouteView is a parsed traceroute_result event payload.
|
||||
@@ -227,7 +232,7 @@ func (s *Server) handleIPsPage(w http.ResponseWriter, r *http.Request) {
|
||||
func (s *Server) handleIPDetail(w http.ResponseWriter, r *http.Request) {
|
||||
ip := r.PathValue("ip")
|
||||
detail, err := s.CA.GetIP(r.Context(), ip)
|
||||
data := ipDetailData{Detail: detail, Events: buildEventViews(detail.Events)}
|
||||
data := ipDetailData{ipDetailView: ipDetailView{Detail: detail, Events: buildEventViews(detail.Events), HasQueueData: true}}
|
||||
data.ActiveNav = "ips"
|
||||
data.Banner = bannerFor(err)
|
||||
s.renderPage(w, r, "ip_detail_page", data)
|
||||
|
||||
Reference in new issue
Block a user