Fix comment threads display
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
parent
5f80eecc28
commit
790f333e4a
|
@ -58,11 +58,11 @@ export const COMMENTS_THREADS = gql`
|
||||||
id
|
id
|
||||||
uuid
|
uuid
|
||||||
comments {
|
comments {
|
||||||
...CommentFields
|
...CommentRecursive
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
${COMMENT_FIELDS_FRAGMENT}
|
${COMMENT_RECURSIVE_FRAGMENT}
|
||||||
`;
|
`;
|
||||||
|
|
||||||
export const CREATE_COMMENT_FROM_EVENT = gql`
|
export const CREATE_COMMENT_FROM_EVENT = gql`
|
||||||
|
|
|
@ -8,7 +8,7 @@ defmodule Mobilizon.GraphQL.Schema.EventType do
|
||||||
import Absinthe.Resolution.Helpers, only: [dataloader: 1]
|
import Absinthe.Resolution.Helpers, only: [dataloader: 1]
|
||||||
import Mobilizon.GraphQL.Helpers.Error
|
import Mobilizon.GraphQL.Helpers.Error
|
||||||
|
|
||||||
alias Mobilizon.{Actors, Addresses, Events}
|
alias Mobilizon.{Actors, Addresses, Conversations, Events}
|
||||||
alias Mobilizon.GraphQL.Resolvers.{Event, Picture, Tag}
|
alias Mobilizon.GraphQL.Resolvers.{Event, Picture, Tag}
|
||||||
alias Mobilizon.GraphQL.Schema
|
alias Mobilizon.GraphQL.Schema
|
||||||
|
|
||||||
|
@ -79,7 +79,7 @@ defmodule Mobilizon.GraphQL.Schema.EventType do
|
||||||
)
|
)
|
||||||
|
|
||||||
field(:comments, list_of(:comment), description: "The comments in reply to the event") do
|
field(:comments, list_of(:comment), description: "The comments in reply to the event") do
|
||||||
resolve(dataloader(Events))
|
resolve(dataloader(Conversations))
|
||||||
end
|
end
|
||||||
|
|
||||||
# field(:tracks, list_of(:track))
|
# field(:tracks, list_of(:track))
|
||||||
|
|
Loading…
Reference in a new issue