Reputation: 543
I am using the slick code generator, I have everything in a trait, but I would like to separate the case classes representing my actual model from all the slick query / table classes.
That would look like
object Models {
case class Foo(bar: String)
}
trait SlickTables {
import Models.Foo
class Foos(tag: Tag) extends Table[Foo](tag, "foo") {
...
}
}
Is there any way to do this by tweaking the code generator ?
Upvotes: 2
Views: 228
Reputation: 526
Just figure a way out.
https://gist.github.com/noru/fd32b03947290176aa36
Around line 80
Upvotes: 0