View Source GlificWeb.Resolvers.Groups (Glific v5.1.6)
Group Resolver which sits between the GraphQL schema and Glific Group Context API. This layer basically stitches together one or more calls to resolve the incoming queries.
Link to this section Summary
Functions
Get the list of contact_groups filtered by args
Get count of group contacts
Get the count of groups filtered by args
Creates an contact group entry
Creates an group
Creates an user group entry
Deletes an group
Get a specific group by id
Get group info by id
Get the list of groups filtered by args
Get the list of organizations groups filtered by args
Updates an group
Get count of group users
Link to this section Functions
@spec contact_groups(Absinthe.Resolution.t(), map(), %{context: map()}) :: {:ok, any()} | {:error, any()}
Get the list of contact_groups filtered by args
@spec contacts_count(Absinthe.Resolution.t(), map(), %{context: map()}) :: {:ok, integer()}
Get count of group contacts
@spec count_groups(Absinthe.Resolution.t(), map(), %{context: map()}) :: {:ok, integer()}
Get the count of groups filtered by args
@spec create_contact_group(Absinthe.Resolution.t(), %{input: map()}, %{context: map()}) :: {:ok, any()} | {:error, any()}
Creates an contact group entry
@spec create_group(Absinthe.Resolution.t(), %{input: map()}, %{context: map()}) :: {:ok, any()} | {:error, any()}
Creates an group
@spec create_user_group(Absinthe.Resolution.t(), %{input: map()}, %{context: map()}) :: {:ok, any()} | {:error, any()}
Creates an user group entry
@spec delete_group(Absinthe.Resolution.t(), %{id: integer()}, %{context: map()}) :: {:ok, any()} | {:error, any()}
Deletes an group
@spec group(Absinthe.Resolution.t(), %{id: integer()}, %{context: map()}) :: {:ok, any()} | {:error, any()}
Get a specific group by id
@spec group_info(Absinthe.Resolution.t(), %{id: integer()}, %{context: map()}) :: {:ok, any()} | {:error, any()}
Get group info by id
@spec groups(Absinthe.Resolution.t(), map(), %{context: map()}) :: {:ok, [Glific.Groups.Group]}
Get the list of groups filtered by args
@spec organization_groups(Absinthe.Resolution.t(), map(), %{context: map()}) :: {:ok, [Glific.Groups.Group]}
Get the list of organizations groups filtered by args
@spec update_group(Absinthe.Resolution.t(), %{id: integer(), input: map()}, %{ context: map() }) :: {:ok, any()} | {:error, any()}
Updates an group
@spec users_count(Absinthe.Resolution.t(), map(), %{context: map()}) :: {:ok, integer()}
Get count of group users