protoc-gen-gorm
protoc-gen-gorm copied to clipboard
panic: Object maORM from package a cannot be user for has-one in mbORM since it does not have FK field maId defined. Manually define the key, or switch to belongs-to.
this error occurred when b.proto has import a.proto.
/model/a/a.proto
package model.a
message ma{
}
/model/b/b.proto
package model.b
import "model/a/a.proto"
message mb{
api.a.ma a = 1;
}
if I move message ma
into b.proto
/model/b/b.proto
package model.b
message ma{
}
message mb{
ma a = 1;
}
that will be ok. does protoc-gen-gorm support for import the message from other package?