defmodule Edgehog.BaseImages.BaseImage do
# use Ash.Resource, extensions: [ AshGraphql.Resource ], ...
# ...
# In our specific case we're interested on filtering in the subscriptions,
# But this also happens with normal queries
graphql do
type :base_image
subscriptions do
pubsub EdgehogWeb.Endpoint
# I found no way of specifying to use relay IDs for filtering and sorting in the documentation
subscribe :base_image do
action_types [:create, :update, :destroy]
end
end
end
# ...
attributes do
# The resource has an integer primary key `:id`
integer_primary_key :id
# ...
end
end
defmodule Edgehog.BaseImages.BaseImage do
# use Ash.Resource, extensions: [ AshGraphql.Resource ], ...
# ...
# In our specific case we're interested on filtering in the subscriptions,
# But this also happens with normal queries
graphql do
type :base_image
subscriptions do
pubsub EdgehogWeb.Endpoint
# I found no way of specifying to use relay IDs for filtering and sorting in the documentation
subscribe :base_image do
action_types [:create, :update, :destroy]
end
end
end
# ...
attributes do
# The resource has an integer primary key `:id`
integer_primary_key :id
# ...
end
end