diff --git a/common/pages.go b/common/pages.go index d468281c..eb25c6a1 100644 --- a/common/pages.go +++ b/common/pages.go @@ -621,6 +621,11 @@ type DebugPageDatabase struct { Attachments int Polls int + LoginLogs int + RegLogs int + ModLogs int + AdminLogs int + Views int ViewsAgents int ViewsForums int diff --git a/routes/panel/debug.go b/routes/panel/debug.go index 47f52c21..62f9b8ad 100644 --- a/routes/panel/debug.go +++ b/routes/panel/debug.go @@ -80,6 +80,24 @@ func Debug(w http.ResponseWriter, r *http.Request, user c.User) c.RouteError { if err != nil { return c.InternalError(err,w,r) } + + loginLogs, err := count("login_logs") + if err != nil { + return c.InternalError(err,w,r) + } + regLogs, err := count("registration_logs") + if err != nil { + return c.InternalError(err,w,r) + } + modLogs, err := count("moderation_logs") + if err != nil { + return c.InternalError(err,w,r) + } + adminLogs, err := count("administration_logs") + if err != nil { + return c.InternalError(err,w,r) + } + views, err := count("viewchunks") if err != nil { return c.InternalError(err,w,r) @@ -112,7 +130,7 @@ func Debug(w http.ResponseWriter, r *http.Request, user c.User) c.RouteError { if err != nil { return c.InternalError(err,w,r) } - debugDatabase := c.DebugPageDatabase{c.Topics.Count(),c.Users.Count(),c.Rstore.Count(),c.Prstore.Count(),c.Activity.Count(),likes,attachs,polls,views,viewsAgents,viewsForums,viewsLangs,viewsReferrers,viewsSystems,postChunks,topicChunks} + debugDatabase := c.DebugPageDatabase{c.Topics.Count(),c.Users.Count(),c.Rstore.Count(),c.Prstore.Count(),c.Activity.Count(),likes,attachs,polls,loginLogs,regLogs,modLogs,adminLogs,views,viewsAgents,viewsForums,viewsLangs,viewsReferrers,viewsSystems,postChunks,topicChunks} staticSize, err := c.DirSize("./public/") if err != nil { diff --git a/templates/panel_debug.html b/templates/panel_debug.html index ea73af57..c73fba1f 100644 --- a/templates/panel_debug.html +++ b/templates/panel_debug.html @@ -121,6 +121,24 @@
?
+
Login Logs
+
Reg Logs
+
Mod Logs
+ +
{{.Database.LoginLogs}}
+
{{.Database.RegLogs}}
+
{{.Database.ModLogs}}
+ + +
Admin Logs
+
???
+
???
+ +
{{.Database.AdminLogs}}
+
?
+
?
+ +
Views
Views Agents
Views Forums