templaterender

package
v1.7.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 15, 2025 License: Apache-2.0 Imports: 17 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ProviderSetTemplateRenderController = wire.NewSet(
	NewTemplateRenderController,
)

ProviderSetTemplateRenderController is template render controller providers.

Functions

func Paginator

func Paginator(page, pageSize int, nums int64) *schema.Paginator

Paginator page page : now page pageSize : Number per page nums : Total Returns the contents of the page in the format of 1, 2, 3, 4, and 5. If the contents are less than 5 pages, the page number is returned

Types

type TemplateRenderController

type TemplateRenderController struct {
	// contains filtered or unexported fields
}

func NewTemplateRenderController

func NewTemplateRenderController(
	questionService *content.QuestionService,
	userService *content.UserService,
	tagService *tag.TagService,
	answerService *content.AnswerService,
	commentService *comment.CommentService,
	siteInfoService siteinfo_common.SiteInfoCommonService,
	questionRepo questioncommon.QuestionRepo,
) *TemplateRenderController

func (*TemplateRenderController) AnswerDetail

func (t *TemplateRenderController) AnswerDetail(ctx context.Context, id string) (*schema.AnswerInfo, error)

func (*TemplateRenderController) AnswerList

func (*TemplateRenderController) CommentList

func (t *TemplateRenderController) CommentList(
	ctx context.Context,
	objectIDs []string,
) (
	comments map[string][]*schema.GetCommentResp,
	err error,
)

func (*TemplateRenderController) Index

func (*TemplateRenderController) OpenSearch

func (t *TemplateRenderController) OpenSearch(ctx *gin.Context)

func (*TemplateRenderController) QuestionDetail

func (t *TemplateRenderController) QuestionDetail(ctx *gin.Context, id string) (resp *schema.QuestionInfoResp, err error)

func (*TemplateRenderController) Sitemap

func (t *TemplateRenderController) Sitemap(ctx *gin.Context)

func (*TemplateRenderController) SitemapPage

func (t *TemplateRenderController) SitemapPage(ctx *gin.Context, page int) error

func (*TemplateRenderController) TagInfo

func (q *TemplateRenderController) TagInfo(ctx context.Context, req *schema.GetTamplateTagInfoReq) (resp *schema.GetTagResp, questionList []*schema.QuestionPageResp, questionCount int64, err error)

func (*TemplateRenderController) TagList

func (*TemplateRenderController) UserInfo

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL