Files
odinsea-elixir/lib/odinsea/database/schema/cashshop_limit_sell.ex
2026-02-14 23:58:01 -07:00

25 lines
577 B
Elixir

defmodule Odinsea.Database.Schema.CashshopLimitSell do
@moduledoc """
Ecto schema for the cashshop_limit_sell table.
Represents limited sale quantities for cash shop items.
"""
use Ecto.Schema
import Ecto.Changeset
@primary_key {:serial, :integer, autogenerate: false}
schema "cashshop_limit_sell" do
field :amount, :integer, default: 0
end
@doc """
Changeset for cashshop limit sell.
"""
def changeset(cashshop_limit_sell, attrs) do
cashshop_limit_sell
|> cast(attrs, [:serial, :amount])
|> validate_required([:serial])
end
end