View Source Bonfire.Social.Threads (bonfire_umbrella v0.9.6-classic-beta.12)

Summary

Functions

Handles casting related to the reply and threading. If it's not a reply or the user is not permitted to reply to the thing, a new thread will be created.

Count participants in a thread (depending on user's boundaries)

List participants in a thread (depending on user's boundaries)

Returns {:ok, reply} or {:error, reason}, where reason may be

List participants of an activity or thread (depending on user's boundaries)

re-order distinct threads after DISTINCT ON ordered them by thread_id - Note: does not support pagination

re-order distinct threads after DISTINCT ON ordered them by thread_id - Note: this results in (Ecto.QueryError) cannot preload associations in subquery in query

Functions

Link to this function

arrange_replies(replies, opts \\ [])

View Source
Link to this function

arrange_replies_tree(replies, opts \\ [])

View Source
Link to this function

cast(changeset, attrs, user, preset_or_custom_boundary)

View Source

Handles casting related to the reply and threading. If it's not a reply or the user is not permitted to reply to the thing, a new thread will be created.

Link to this function

changeset(replied \\ %Replied{}, attrs)

View Source
Link to this function

count_participants(thread_id, opts \\ [])

View Source

Count participants in a thread (depending on user's boundaries)

Link to this function

fetch_participants(thread_id, opts \\ [])

View Source

List participants in a thread (depending on user's boundaries)

Link to this function

filter(arg1, thread_id, query)

View Source

Group per-thread

Link to this function

find_reply_to(attrs, user)

View Source

Returns {:ok, reply} or {:error, reason}, where reason may be:

  • :not_found - we could not find the object you are replying to.
  • :not_permitted - you do not have permission to reply to this.
Link to this function

find_thread(attrs, user)

View Source
Link to this function

list_participants(activity_or_object, thread_or_object_id \\ nil, opts \\ [])

View Source

List participants of an activity or thread (depending on user's boundaries)

Link to this function

list_replies(thread, opts \\ [])

View Source
Link to this function

mark_all_seen(filters, opts)

View Source
Link to this function

maybe_re_order_result(result, opts)

View Source

re-order distinct threads after DISTINCT ON ordered them by thread_id - Note: does not support pagination

Link to this function

re_order_using_subquery(query, opts)

View Source

re-order distinct threads after DISTINCT ON ordered them by thread_id - Note: this results in (Ecto.QueryError) cannot preload associations in subquery in query

Link to this function

read(object_id, socket_or_current_user)

View Source

Callback implementation for Bonfire.Common.QueryModule.schema_module/0.

Link to this function

unseen_count(filters, opts)

View Source
Link to this function

unseen_query(filters, opts)

View Source