Skip to content
Permalink
Browse files

Schemas

  • Loading branch information...
dnsbty committed Aug 18, 2019
1 parent b0e9b35 commit 7e3e04d486e9b9e6211f9232840c4b906ea6cbb3
Showing with 19 additions and 0 deletions.
  1. +2 −0 lib/user_admin/users.ex
  2. +7 −0 lib/user_admin/users/role.ex
  3. +10 −0 lib/user_admin/users/user.ex
@@ -0,0 +1,2 @@
defmodule UserAdmin.Users do
end
@@ -0,0 +1,7 @@
defmodule UserAdmin.Users.Role do
use Ecto.Schema

schema "roles" do
field :name, :string
end
end
@@ -0,0 +1,10 @@
defmodule UserAdmin.Users.User do
use Ecto.Schema
alias UserAdmin.Users.Role

schema "users" do
field :name, :string

belongs_to :role, Role
end
end

0 comments on commit 7e3e04d

Please sign in to comment.
You can’t perform that action at this time.