mirror of
https://github.com/jhillyerd/inbucket.git
synced 2025-12-18 18:17:03 +00:00
- Label graphs by their duration, not update period - Extend to 60 units so they are either 10 minutes or an hour of data - Improvements to retention information - Change javascript calculations, fixes #9 (I hope)
21 lines
534 B
Go
21 lines
534 B
Go
package web
|
|
|
|
import (
|
|
"github.com/jhillyerd/inbucket/config"
|
|
"net/http"
|
|
)
|
|
|
|
func RootIndex(w http.ResponseWriter, req *http.Request, ctx *Context) (err error) {
|
|
return RenderTemplate("root/index.html", w, map[string]interface{}{
|
|
"ctx": ctx,
|
|
})
|
|
}
|
|
|
|
func RootStatus(w http.ResponseWriter, req *http.Request, ctx *Context) (err error) {
|
|
retentionMinutes := config.GetDataStoreConfig().RetentionMinutes
|
|
return RenderTemplate("root/status.html", w, map[string]interface{}{
|
|
"ctx": ctx,
|
|
"retentionMinutes": retentionMinutes,
|
|
})
|
|
}
|