add shops context, clothes and users-clothes

users-clothes is a many-to-many unique relationship
This commit is contained in:
2021-06-28 16:32:25 +02:00
parent 28823a6972
commit 4f8b87a2d9
14 changed files with 454 additions and 0 deletions
+1
View File
@@ -8,6 +8,7 @@ defmodule PokemonCouture.Accounts.User do
field :password, :string, virtual: true
field :hashed_password, :string
field :confirmed_at, :naive_datetime
many_to_many :clothes, PokemonCouture.Shops.Clothes, join_through: "ownerships", unique: :true
timestamps()
end