Back.AutomatonsComments (CAMI-Back v0.1.0)

View Source

The AutomatonsComments context.

Summary

Functions

Returns an %Ecto.Changeset{} for tracking automaton_comments changes.

Creates a automaton_comments.

Deletes a automaton_comments.

Gets a single automaton_comments.

Returns the list of automaton_comment.

Functions

change_automaton_comments(automaton_comments, attrs \\ %{})

Returns an %Ecto.Changeset{} for tracking automaton_comments changes.

Examples

iex> change_automaton_comments(automaton_comments)
%Ecto.Changeset{data: %AutomatonComments{}}

create_automaton_comments(attrs \\ %{})

Creates a automaton_comments.

Examples

iex> create_automaton_comments(%{field: value})
{:ok, %AutomatonComments{}}

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

delete_automaton_comments(automaton_comments)

Deletes a automaton_comments.

Examples

iex> delete_automaton_comments(automaton_comments)
{:ok, %AutomatonComments{}}

iex> delete_automaton_comments(automaton_comments)
{:error, %Ecto.Changeset{}}

get_automaton_comments!(id)

Gets a single automaton_comments.

Raises Ecto.NoResultsError if the Automaton comments does not exist.

Examples

iex> get_automaton_comments!(123)
%AutomatonComments{}

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

get_by_automaton_id!(id)

list_automaton_comment()

Returns the list of automaton_comment.

Examples

iex> list_automaton_comment()
[%AutomatonComments{}, ...]

update_automaton_comments(automaton_comments, attrs)

Updates a automaton_comments.

Examples

iex> update_automaton_comments(automaton_comments, %{field: new_value})
{:ok, %AutomatonComments{}}

iex> update_automaton_comments(automaton_comments, %{field: bad_value})
{:error, %Ecto.Changeset{}}