lib/uof/schemas/api/descriptions/betstop_reasons_descriptions.ex
defmodule UOF.Schemas.API.Descriptions.BetstopReasonsDescriptions do
@moduledoc false
use Ecto.Schema
import Ecto.Changeset
@primary_key false
embedded_schema do
field(:response_code, :string)
field(:location, :string)
embeds_many(:betstop_reason, UOF.Schemas.API.Descriptions.DescBetstopReason)
end
def changeset(struct, params) do
struct
|> cast(params, [:response_code, :location])
|> cast_embed(:betstop_reason)
end
end