mirror of
https://framagit.org/framasoft/mobilizon.git
synced 2024-12-23 00:14:48 +00:00
28 lines
702 B
Elixir
28 lines
702 B
Elixir
defmodule Mobilizon.GraphQL.Resolvers.Search do
|
|
@moduledoc """
|
|
Handles the event-related GraphQL calls
|
|
"""
|
|
|
|
alias Mobilizon.GraphQL.API.Search
|
|
|
|
@doc """
|
|
Search persons
|
|
"""
|
|
def search_persons(_parent, %{search: search, page: page, limit: limit}, _resolution) do
|
|
Search.search_actors(search, page, limit, :Person)
|
|
end
|
|
|
|
@doc """
|
|
Search groups
|
|
"""
|
|
def search_groups(_parent, %{search: search, page: page, limit: limit}, _resolution) do
|
|
Search.search_actors(search, page, limit, :Group)
|
|
end
|
|
|
|
@doc """
|
|
Search events
|
|
"""
|
|
def search_events(_parent, %{search: search, page: page, limit: limit}, _resolution) do
|
|
Search.search_events(search, page, limit)
|
|
end
|
|
end
|