default /
This commit is contained in:
@ -12,12 +12,16 @@ type Index struct {
|
||||
BaseController
|
||||
}
|
||||
|
||||
// leanote展示页, 没有登录的, 或已登录明确要进该页的
|
||||
func (c Index) Index() revel.Result {
|
||||
func (c Index) Default() revel.Result {
|
||||
if configService.HomePageIsAdminsBlog(){
|
||||
blog := Blog{c.BaseController}
|
||||
return blog.Index(configService.GetAdminUsername());
|
||||
}
|
||||
return c.Index()
|
||||
}
|
||||
// leanote展示页, 没有登录的, 或已登录明确要进该页的
|
||||
func (c Index) Index() revel.Result {
|
||||
|
||||
c.SetUserInfo()
|
||||
c.RenderArgs["title"] = "leanote"
|
||||
c.RenderArgs["openRegister"] = configService.GlobalStringConfigs["openRegister"]
|
||||
|
@ -5,7 +5,7 @@
|
||||
module:testrunner
|
||||
|
||||
# Home is My Blog
|
||||
Get / Index.Index
|
||||
Get / Index.Default
|
||||
GET /note Note.Index
|
||||
# leanote home
|
||||
GET /index Index.Index
|
||||
|
Reference in New Issue
Block a user