carv api logic
This commit is contained in:
29
internal/model/nh_game_report_model.go
Executable file
29
internal/model/nh_game_report_model.go
Executable file
@@ -0,0 +1,29 @@
|
||||
package model
|
||||
|
||||
import "github.com/zeromicro/go-zero/core/stores/sqlx"
|
||||
|
||||
var _ NhGameReportModel = (*customNhGameReportModel)(nil)
|
||||
|
||||
type (
|
||||
// NhGameReportModel is an interface to be customized, add more methods here,
|
||||
// and implement the added methods in customNhGameReportModel.
|
||||
NhGameReportModel interface {
|
||||
nhGameReportModel
|
||||
withSession(session sqlx.Session) NhGameReportModel
|
||||
}
|
||||
|
||||
customNhGameReportModel struct {
|
||||
*defaultNhGameReportModel
|
||||
}
|
||||
)
|
||||
|
||||
// NewNhGameReportModel returns a model for the database table.
|
||||
func NewNhGameReportModel(conn sqlx.SqlConn) NhGameReportModel {
|
||||
return &customNhGameReportModel{
|
||||
defaultNhGameReportModel: newNhGameReportModel(conn),
|
||||
}
|
||||
}
|
||||
|
||||
func (m *customNhGameReportModel) withSession(session sqlx.Session) NhGameReportModel {
|
||||
return NewNhGameReportModel(sqlx.NewSqlConnFromSession(session))
|
||||
}
|
||||
Reference in New Issue
Block a user