ash_postgres/test/support/resources/rating.ex
2021-01-28 19:42:55 -05:00

21 lines
364 B
Elixir

defmodule AshPostgres.Test.Rating do
@moduledoc false
use Ash.Resource,
data_layer: AshPostgres.DataLayer
postgres do
polymorphic?(true)
repo AshPostgres.TestRepo
end
actions do
read(:read)
create(:create)
end
attributes do
uuid_primary_key(:id)
attribute(:score, :integer)
attribute(:resource_id, :uuid)
end
end