StrawHat.Map v0.3.0 StrawHat.Map.Schema.State View Source

Represents a State Ecto Schema with functionality about the data validation for State.

Link to this section Summary

Types

Check t/0 type for more information about the keys

t()

Link to this section Types

Link to this type state_attrs() View Source
state_attrs() :: %{name: String.t(), code: String.t(), country_id: String.t()}

Check t/0 type for more information about the keys.

Link to this type t() View Source
t() :: %StrawHat.Map.Schema.State{
  __meta__: term(),
  cities: [StrawHat.Map.Schema.City.t()] | Ecto.Association.NotLoaded.t(),
  code: String.t(),
  counties: [StrawHat.Map.Schema.County.t()] | Ecto.Association.NotLoaded.t(),
  country: State.t() | Ecto.Association.NotLoaded.t(),
  country_id: String.t(),
  id: term(),
  name: String.t()
}

Link to this section Functions

Link to this function changeset(state, state_attrs) View Source
changeset(t(), state_attrs()) :: Ecto.Changeset.t()