StrawHat.Map v0.3.1 StrawHat.Map.Country View Source

Defines functionality for countries management.

Link to this section Summary

Functions

Destroy a country

Get a country by id

Get the list of countries

Get list of countries

Get a country by id

Get list of states

Link to this section Functions

Create a country.

Destroy a country.

Link to this function find_country(country_id) View Source
find_country(String.t()) ::
  {:ok, StrawHat.Map.Schema.Country.t()} | {:error, StrawHat.Error.t()}

Get a country by id.

Link to this function get_countries(pagination \\ []) View Source
get_countries(Scrivener.Config.t()) :: Scrivener.Page.t()

Get the list of countries.

Link to this function get_countries_by_ids(country_ids) View Source
get_countries_by_ids([integer()]) ::
  [StrawHat.Map.Schema.Country.t()] | no_return()

Get list of countries.

Link to this function get_country(country_id) View Source
get_country(String.t()) :: StrawHat.Map.Schema.Country.t() | nil | no_return()

Get a country by id.

Link to this function get_states(country_ids) View Source
get_states([integer()]) :: [StrawHat.Map.Schema.State.t()] | no_return()

Get list of states.

Update a country.