beego.go 467 字节
package beego

import (
	"github.com/astaxie/beego"
	"github.com/linmadan/egglib-go/web/beego/filters"

	. "github.com/tiptok/godevp/pkg/log"
	_ "github.com/tiptok/godevp/pkg/port/beego/routers"
)

func init() {
	beego.InsertFilter("/*", beego.BeforeExec, filters.CreateRequestBodyFilter())
	beego.InsertFilter("/*", beego.BeforeExec, filters.CreateRequstLogFilter(Logger))
	beego.InsertFilter("/*", beego.AfterExec, filters.CreateResponseLogFilter(Logger), false)
}