diff options
author | ᴜɴᴋɴᴡᴏɴ <u@gogs.io> | 2020-04-21 18:07:17 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-21 18:07:17 +0800 |
commit | 4e1f38ce28e87ece15a29c1f0fa2d7b5eeef79a6 (patch) | |
tree | 48ee016b18d70bf6c8019e776439225d1a68e190 /internal/route | |
parent | 60273d3d6d97dd6e5220ac77a623d72fbc71e70d (diff) |
lfs: show configs in admin ui (#6128)
* Rename template consts
* Display new DB options
* Display LFS configs
Diffstat (limited to 'internal/route')
-rw-r--r-- | internal/route/admin/admin.go | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/internal/route/admin/admin.go b/internal/route/admin/admin.go index 6b0e8c2c..d1b3bdbf 100644 --- a/internal/route/admin/admin.go +++ b/internal/route/admin/admin.go @@ -22,9 +22,9 @@ import ( ) const ( - DASHBOARD = "admin/dashboard" - CONFIG = "admin/config" - MONITOR = "admin/monitor" + tmplDashboard = "admin/dashboard" + tmplConfig = "admin/config" + tmplMonitor = "admin/monitor" ) // initTime is the time when the application was initialized. @@ -123,7 +123,7 @@ func Dashboard(c *context.Context) { // FIXME: update periodically updateSystemStatus() c.Data["SysStatus"] = sysStatus - c.Success(DASHBOARD) + c.Success(tmplDashboard) } // Operation types. @@ -209,6 +209,7 @@ func Config(c *context.Context) { c.Data["Mirror"] = conf.Mirror c.Data["Webhook"] = conf.Webhook c.Data["Git"] = conf.Git + c.Data["LFS"] = conf.LFS c.Data["LogRootPath"] = conf.Log.RootPath type logger struct { @@ -225,7 +226,7 @@ func Config(c *context.Context) { } c.Data["Loggers"] = loggers - c.Success(CONFIG) + c.Success(tmplConfig) } func Monitor(c *context.Context) { @@ -234,5 +235,5 @@ func Monitor(c *context.Context) { c.Data["PageIsAdminMonitor"] = true c.Data["Processes"] = process.Processes c.Data["Entries"] = cron.ListTasks() - c.Success(MONITOR) + c.Success(tmplMonitor) } |