StrawHat.Map v2.0.0 StrawHat.Map.Cities View Source
Cities management use cases.
Link to this section Summary
Link to this section Functions
Link to this function
create_city(repo, city_attrs)
View Source
create_city(repo, city_attrs)
View Source
create_city(Ecto.Repo.t(), StrawHat.Map.City.city_attrs()) ::
StrawHat.Response.t(StrawHat.Map.City.t(), Ecto.Changeset.t())
create_city(Ecto.Repo.t(), StrawHat.Map.City.city_attrs()) :: StrawHat.Response.t(StrawHat.Map.City.t(), Ecto.Changeset.t())
Link to this function
destroy_city(repo, city)
View Source
destroy_city(repo, city)
View Source
destroy_city(Ecto.Repo.t(), StrawHat.Map.City.t()) ::
StrawHat.Response.t(StrawHat.Map.City.t(), Ecto.Changeset.t())
destroy_city(Ecto.Repo.t(), StrawHat.Map.City.t()) :: StrawHat.Response.t(StrawHat.Map.City.t(), Ecto.Changeset.t())
Link to this function
find_city(repo, city_id)
View Source
find_city(repo, city_id)
View Source
find_city(Ecto.Repo.t(), String.t()) ::
StrawHat.Response.t(StrawHat.Map.City.t(), StrawHat.Error.t())
find_city(Ecto.Repo.t(), String.t()) :: StrawHat.Response.t(StrawHat.Map.City.t(), StrawHat.Error.t())
Link to this function
get_cities(repo, pagination \\ [])
View Source
get_cities(repo, pagination \\ [])
View Source
get_cities(Ecto.Repo.t(), Scrivener.Config.t()) :: Scrivener.Page.t()
get_cities(Ecto.Repo.t(), Scrivener.Config.t()) :: Scrivener.Page.t()
Link to this function
get_cities_by_ids(repo, city_ids)
View Source
get_cities_by_ids(repo, city_ids)
View Source
get_cities_by_ids(Ecto.Repo.t(), [integer()]) ::
[StrawHat.Map.City.t()] | no_return()
get_cities_by_ids(Ecto.Repo.t(), [integer()]) :: [StrawHat.Map.City.t()] | no_return()
Link to this function
get_city(repo, city_id)
View Source
get_city(repo, city_id)
View Source
get_city(Ecto.Repo.t(), String.t()) :: StrawHat.Map.City.t() | nil | no_return()
get_city(Ecto.Repo.t(), String.t()) :: StrawHat.Map.City.t() | nil | no_return()
Link to this function
get_postal_code_rule(repo, city_id)
View Source
get_postal_code_rule(repo, city_id)
View Source
get_postal_code_rule(Ecto.Repo.t(), Integer.t()) :: Regex.t() | nil
get_postal_code_rule(Ecto.Repo.t(), Integer.t()) :: Regex.t() | nil
Link to this function
update_city(repo, city, city_attrs)
View Source
update_city(repo, city, city_attrs)
View Source
update_city(
Ecto.Repo.t(),
StrawHat.Map.City.t(),
StrawHat.Map.City.city_attrs()
) :: StrawHat.Response.t(StrawHat.Map.City.t(), Ecto.Changeset.t())
update_city( Ecto.Repo.t(), StrawHat.Map.City.t(), StrawHat.Map.City.city_attrs() ) :: StrawHat.Response.t(StrawHat.Map.City.t(), Ecto.Changeset.t())