package genModel import "github.com/zeromicro/go-zero/core/stores/sqlx" var _ ServerOrderModel = (*customServerOrderModel)(nil) type ( // ServerOrderModel is an interface to be customized, add more methods here, // and implement the added methods in customServerOrderModel. ServerOrderModel interface { serverOrderModel withSession(session sqlx.Session) ServerOrderModel } customServerOrderModel struct { *defaultServerOrderModel } ) // NewServerOrderModel returns a model for the database table. func NewServerOrderModel(conn sqlx.SqlConn) ServerOrderModel { return &customServerOrderModel{ defaultServerOrderModel: newServerOrderModel(conn), } } func (m *customServerOrderModel) withSession(session sqlx.Session) ServerOrderModel { return NewServerOrderModel(sqlx.NewSqlConnFromSession(session)) }