Skip to content

Instantly share code, notes, and snippets.

@hieuwu
Created March 21, 2022 14:53
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save hieuwu/76e7d06908d66fad53b935fc5f4b681f to your computer and use it in GitHub Desktop.
Line Item and Product One to one relationship
data class LineItemAndProduct(
@Embedded val lineItem: LineItem?,
@Relation(
parentColumn = "productId",
entityColumn = "productId",
entity = Product::class
)
val product: Product?
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment