Closed
Description
My ENV:
go version go1.9.2 windows/amd64
My Code Path:
E:\GOPATH\src\test\models.go
My question :
To excute go generate ./...
got a failure info : can't generate query sets: can't parse file models.go to get structs: can't load types for file models.go in package "./." But in Desktop dictionary path “test/models.go” to excute go generate ./...
was successful !
The code :
import "github.com/jinzhu/gorm"
//go:generate goqueryset -in models.go
// User struct represent user model. Next line (gen:qs) is needed to autogenerate UserQuerySet.
// gen:qs
type User struct {
gorm.Model
Rating int
RatingMarks int
}