code_corps v0.0.1 CodeCorps.Messages.ConversationQuery View Source

Holds helpers to query CodeCorps.Conversation records using a map of params.

Link to this section Summary

Functions

Filters CodeCorps.Conversation record queries to return only those considered to be active

Narrows down a CodeCorps.Conversation query by project_id of the parent CodeCorps.Message, if specified in a params map

Filters CodeCorps.Conversation record queries by their status

Narrows down a CodeCorps.Conversation query by user_id, if specified in a params map

Link to this section Functions

Link to this function active_filter(queryable, map) View Source
active_filter(Ecto.Queryable.t(), map()) :: Ecto.Queryable.t()

Filters CodeCorps.Conversation record queries to return only those considered to be active.

Active conversations belong either:

Link to this function project_filter(queryable, map) View Source
project_filter(Ecto.Queryable.t(), map()) :: Ecto.Queryable.t()

Narrows down a CodeCorps.Conversation query by project_id of the parent CodeCorps.Message, if specified in a params map

Link to this function status_filter(queryable, arg2) View Source
status_filter(Ecto.Queryable.t(), map()) :: Ecto.Queryable.t()

Filters CodeCorps.Conversation record queries by their status.

Link to this function user_filter(queryable, map) View Source
user_filter(Ecto.Queryable.t(), map()) :: Ecto.Queryable.t()

Narrows down a CodeCorps.Conversation query by user_id, if specified in a params map