add gen
This commit is contained in:
18
providers/query/query.go
Normal file
18
providers/query/query.go
Normal file
@@ -0,0 +1,18 @@
|
||||
package query
|
||||
|
||||
import (
|
||||
"atom/container"
|
||||
"log"
|
||||
|
||||
"gorm.io/gorm"
|
||||
)
|
||||
|
||||
func init() {
|
||||
if err := container.Container.Provide(NewQuery); err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
func NewQuery(db *gorm.DB) *Query {
|
||||
return Use(db)
|
||||
}
|
||||
Reference in New Issue
Block a user