-
-
Notifications
You must be signed in to change notification settings - Fork 87
Expand file tree
/
Copy pathdomain.ex
More file actions
76 lines (69 loc) · 2.56 KB
/
domain.ex
File metadata and controls
76 lines (69 loc) · 2.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
# SPDX-FileCopyrightText: 2020 ash_graphql contributors <https://github.com/ash-project/ash_graphql/graphs.contributors>
#
# SPDX-License-Identifier: MIT
defmodule AshGraphql.Test.Domain do
@moduledoc false
use Ash.Domain,
extensions: [
AshGraphql.Domain
],
otp_app: :ash_graphql
graphql do
queries do
get AshGraphql.Test.Comment, :get_comment, :read
list AshGraphql.Test.Post, :post_score, :score
end
subscriptions do
pubsub AshGraphql.Test.PubSub
subscribe AshGraphql.Test.Subscribable, :subscribed_on_domain do
action_types(:create)
end
subscribe AshGraphql.Test.DomainLevelPubsubResource, :domain_pubsub_subscription do
action_types([:create, :update, :destroy])
end
end
end
resources do
resource(AshGraphql.Test.Actor)
resource(AshGraphql.Test.ActorAgent)
resource(AshGraphql.Test.Agent)
resource(AshGraphql.Test.Award)
resource(AshGraphql.Test.Comment)
resource(AshGraphql.Test.CompositePrimaryKey)
resource(AshGraphql.Test.CompositePrimaryKeyNotEncoded)
resource(AshGraphql.Test.DoubleRelRecursive)
resource(AshGraphql.Test.DoubleRelToRecursiveParentOfEmbed)
resource(AshGraphql.Test.MapTypes)
resource(AshGraphql.Test.Movie)
resource(AshGraphql.Test.MovieActor)
resource(AshGraphql.Test.MultitenantPostTag)
resource(AshGraphql.Test.MultitenantTag)
resource(AshGraphql.Test.NoGraphql)
resource(AshGraphql.Test.NoObject)
resource(AshGraphql.Test.NonIdPrimaryKey)
resource(AshGraphql.Test.Post)
resource(AshGraphql.Test.PostTag)
resource(AshGraphql.Test.RelayPostTag)
resource(AshGraphql.Test.RelayTag)
resource(AshGraphql.Test.Review)
resource(AshGraphql.Test.SponsoredComment)
resource(AshGraphql.Test.Tag)
resource(AshGraphql.Test.User)
resource(AshGraphql.Test.Channel)
resource(AshGraphql.Test.ChannelSimple)
resource(AshGraphql.Test.Message)
resource(AshGraphql.Test.MessageViewableUser)
resource(AshGraphql.Test.TextMessage)
resource(AshGraphql.Test.ImageMessage)
resource(AshGraphql.Test.Subscribable)
resource(AshGraphql.Test.DomainLevelPubsubResource)
resource(AshGraphql.Test.ResourceLevelPubsubResource)
resource(AshGraphql.Test.ErrorHandling)
resource(AshGraphql.Test.ResourceWithTypeInsideType)
resource(AshGraphql.Test.Product)
resource(AshGraphql.Test.ResourceWithUnion)
resource(AshGraphql.Test.ResourceWithTypedStruct)
resource(AshGraphql.Test.AfterTransactionEts)
resource(AshGraphql.Test.AfterTransactionMnesia)
end
end