View Source PowInvitation.Ecto.Context (Pow v1.0.38)
Handles invitation context for user.
Summary
Functions
Creates an invited user.
Finds an invited user by the invitation_token
column.
Updates an invited user and accepts invitation.
Functions
@spec create(Pow.Ecto.Context.user(), map(), Pow.Config.t()) :: {:ok, Pow.Ecto.Context.user()} | {:error, Pow.Ecto.Context.changeset()}
Creates an invited user.
@spec get_by_invitation_token(binary(), Pow.Config.t()) :: Pow.Ecto.Context.user() | nil
Finds an invited user by the invitation_token
column.
Ignores users with :invitation_accepted_at
set.
@spec update(Pow.Ecto.Context.user(), map(), Pow.Config.t()) :: {:ok, Pow.Ecto.Context.user()} | {:error, Pow.Ecto.Context.changeset()}
Updates an invited user and accepts invitation.
See PowInvitation.Ecto.Schema.accept_invitation_changeset/2
.