//分页查询 func (this *EpisodeController) QueryList(page int) revel.Result { episodes, pagination := models.GetEpisodes(this.q, page, "", "", "created", routes.EpisodeController.QueryList(page)) this.RenderArgs["episodes"] = episodes this.RenderArgs["pagination"] = pagination return this.RenderTemplate("article/episode.html") }
func (this App) Index() revel.Result { episodes, pagination := models.GetEpisodes(this.q, 1, "", "", "created", routes.App.Index()) fmt.Println("") return this.Render(episodes, pagination) }