Boruta.Ecto.Admin.Users (Boruta core v0.2.1) View Source

TODO Admin Users documentation

Link to this section Summary

Functions

Deletes a User.

Gets a single user.

Returns the list of users.

Updates an user.

Link to this section Functions

Deletes a User.

Examples

iex> delete_user(user)
{:ok, %User{}}

iex> delete_user(user)
{:error, %Ecto.Changeset{}}

Gets a single user.

Raises Ecto.NoResultsError if the User does not exist.

Examples

iex> get_user!(123)
%User{}

iex> get_user!(456)
** (Ecto.NoResultsError)

Returns the list of users.

Examples

iex> list_users()
[%User{}, ...]
Link to this function

update_user(user, attrs)

View Source

Updates an user.

Examples

iex> update_user(user, %{field: new_value})
{:ok, %User{}}

iex> update_user(user, %{field: bad_value})
{:error, %Ecto.Changeset{}}