ash_postgres/test/support/complex_calculations/resources/channel_member.ex
Zach Daniel 37cc01957d
improvement!: 3.0 (#227)
* WIP

* chore: fix mix.lock merge issues

* improvement: upgrade to 3.0

* chore: remove `repo.to_tenant`

* chore: continue removal of unnecessary helper

* chore: use `Ash.ToTenant`
2024-03-27 16:52:28 -04:00

31 lines
808 B
Elixir

defmodule AshPostgres.Test.ComplexCalculations.ChannelMember do
@moduledoc false
use Ash.Resource,
domain: AshPostgres.Test.ComplexCalculations.Domain,
data_layer: AshPostgres.DataLayer,
authorizers: [Ash.Policy.Authorizer]
actions do
default_accept(:*)
defaults([:create, :read, :update, :destroy])
end
attributes do
uuid_primary_key(:id)
create_timestamp(:created_at, public?: true)
update_timestamp(:updated_at, public?: true)
end
postgres do
table "complex_calculations_certifications_channel_members"
repo(AshPostgres.TestRepo)
end
relationships do
belongs_to(:user, AshPostgres.Test.User, domain: AshPostgres.Test.Domain, public?: true)
belongs_to(:channel, AshPostgres.Test.ComplexCalculations.Channel, public?: true)
end
end