Current section

Files

Jump to
ex_shopify_schema lib ex_shopify_schema graphql weight.ex
Raw

lib/ex_shopify_schema/graphql/weight.ex

defmodule ExShopifySchema.Graphql.Weight do
@moduledoc "A weight, which includes a numeric value and a unit of measurement."
use ExShopifySchema.Generator.Graphql.Schema
@primary_key false
typed_embedded_schema do
loadable_field :unit, Ecto.Enum, [values: [kilograms: "KILOGRAMS", grams: "GRAMS", pounds: "POUNDS", ounces: "OUNCES"]]
loadable_field :value, ExShopifySchema.Graphql.Float, []
end
end