diff options
author | Unknwon <joe2010xtmf@163.com> | 2014-07-26 00:24:27 -0400 |
---|---|---|
committer | Unknwon <joe2010xtmf@163.com> | 2014-07-26 00:24:27 -0400 |
commit | 8dd07c0ddd99ae626a1ec8c06f75f27fed51269f (patch) | |
tree | 261d3c9911dabc58c1ac54e4e36b3dee24d2032b /routers/admin/admin.go | |
parent | 0a739cf9ac901f54484c34bba8322418dedb09b0 (diff) | |
download | gitea-8dd07c0ddd99ae626a1ec8c06f75f27fed51269f.tar.gz gitea-8dd07c0ddd99ae626a1ec8c06f75f27fed51269f.zip |
New UI merge in progress
Diffstat (limited to 'routers/admin/admin.go')
-rw-r--r-- | routers/admin/admin.go | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/routers/admin/admin.go b/routers/admin/admin.go index eb4123435a..efdc803b95 100644 --- a/routers/admin/admin.go +++ b/routers/admin/admin.go @@ -10,7 +10,8 @@ import ( "strings" "time" - "github.com/go-martini/martini" + "github.com/Unknwon/com" + "github.com/Unknwon/macaron" "github.com/gogits/gogs/models" "github.com/gogits/gogs/modules/base" @@ -126,7 +127,7 @@ func Dashboard(ctx *middleware.Context) { ctx.Data["PageIsDashboard"] = true // Run operation. - op, _ := base.StrTo(ctx.Query("op")).Int() + op, _ := com.StrTo(ctx.Query("op")).Int() if op > 0 { var err error var success string @@ -159,7 +160,7 @@ func Users(ctx *middleware.Context) { ctx.Data["Title"] = "User Management" ctx.Data["PageIsUsers"] = true - p := base.StrTo(ctx.Query("p")).MustInt() + p := com.StrTo(ctx.Query("p")).MustInt() if p < 1 { p = 1 } @@ -188,7 +189,7 @@ func Repositories(ctx *middleware.Context) { ctx.Data["Title"] = "Repository Management" ctx.Data["PageIsRepos"] = true - p := base.StrTo(ctx.Query("p")).MustInt() + p := com.StrTo(ctx.Query("p")).MustInt() if p < 1 { p = 1 } @@ -235,7 +236,7 @@ func Config(ctx *middleware.Context) { ctx.Data["OfflineMode"] = setting.OfflineMode ctx.Data["DisableRouterLog"] = setting.DisableRouterLog ctx.Data["RunUser"] = setting.RunUser - ctx.Data["RunMode"] = strings.Title(martini.Env) + ctx.Data["RunMode"] = strings.Title(macaron.Env) ctx.Data["RepoRootPath"] = setting.RepoRootPath ctx.Data["StaticRootPath"] = setting.StaticRootPath ctx.Data["LogRootPath"] = setting.LogRootPath |