mirror of
https://github.com/astaxie/beego.git
synced 2025-07-15 04:41:01 +00:00
增加了文档和router函数
This commit is contained in:
15
beego.go
15
beego.go
@ -93,6 +93,21 @@ func (app *App) RegisterController(path string, c ControllerInterface) *App {
|
||||
return app
|
||||
}
|
||||
|
||||
func (app *App) Filter(filter http.HandlerFunc) *App {
|
||||
app.Handlers.Filter(filter)
|
||||
return app
|
||||
}
|
||||
|
||||
func (app *App) FilterParam(param string, filter http.HandlerFunc) *App {
|
||||
app.Handlers.FilterParam(param, filter)
|
||||
return app
|
||||
}
|
||||
|
||||
func (app *App) FilterPrefixPath(path string, filter http.HandlerFunc) *App {
|
||||
app.Handlers.FilterParam(path, filter)
|
||||
return app
|
||||
}
|
||||
|
||||
func (app *App) SetViewsPath(path string) *App {
|
||||
ViewsPath = path
|
||||
return app
|
||||
|
Reference in New Issue
Block a user