码农笔录博客源码
Não pode escolher mais do que 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

27 linhas
667 B

há 6 anos
package controllers
import (
há 6 anos
"beeblog/service"
há 3 anos
beego "github.com/beego/beego/v2/server/web"
há 6 anos
)
type IndexController struct {
beego.Controller
}
há 6 anos
func (this *IndexController) Get() {
há 5 anos
blogService := service.BlogService{}
timeBlog, _ := blogService.IndexBlogs(27, 0)
há 6 anos
this.Data["TimeBlog"] = timeBlog
browsBlog, _ := blogService.IndexBlogs(27, 1)
há 6 anos
this.Data["BrowsBlog"] = browsBlog
this.Data["UserId"] = this.GetSession("userid")
this.Data["HeadImg"] = this.GetSession("headimg")
this.Data["NickName"] = this.GetSession("nickname")
this.Data["IsLogin"] = this.GetSession("nickname") != nil
this.Data["IsHome"] = true
this.TplName = "index.html"
há 6 anos
return
há 6 anos
}