Documentation
¶
Index ¶
Constants ¶
View Source
const ( ErrorsDbDriverNotExists = "Database.Type 数据库驱动不被支持,请选择mysql|postgres:" ErrorsDialectorDbInitFail = "数据库驱动初始化失败:" EventDestroyPrefix = "Destroy_Database" )
Variables ¶
This section is empty.
Functions ¶
func GetSqlDriver ¶
获取数据库驱动 ops := &DbOptions wl winner_logger.Logger tracing 是否开启sql日志
func NewMysqlTracingPlugin ¶ added in v1.0.1
func NewMysqlTracingPlugin(logger winner_logger.Logger) gorm.Plugin
Types ¶
type WinnerTracingPlugin ¶ added in v1.0.1
type WinnerTracingPlugin struct{}
func (*WinnerTracingPlugin) Initialize ¶ added in v1.0.1
func (op *WinnerTracingPlugin) Initialize(db *gorm.DB) (err error)
func (*WinnerTracingPlugin) Name ¶ added in v1.0.1
func (op *WinnerTracingPlugin) Name() string
Click to show internal directories.
Click to hide internal directories.