View Source Bonfire.Files.Media (Bonfire v0.9.10-classic-beta.169)

Summary

Types

@type t() :: %Bonfire.Files.Media{
  __meta__: term(),
  controlled: term(),
  creator: term(),
  creator_id: term(),
  deleted_at: term(),
  file: term(),
  id: term(),
  media_type: term(),
  metadata: term(),
  path: term(),
  size: term(),
  url: term()
}

Functions

Link to this function

ap_publish_activity(subject, verb, media)

View Source
Link to this function

ap_receive_activity(creator, activity, ap_object)

View Source

Callback implementation for Bonfire.Common.SchemaModule.context_module/0.

Callback implementation for Bonfire.Federate.ActivityPub.FederationModules.federation_module/0.

Link to this function

get(struct, key, default \\ nil)

View Source
Link to this function

hard_delete(module \\ nil, media)

View Source
@spec hard_delete(atom(), t()) :: :ok | {:error, Ecto.Changeset.t()}

Delete an upload, removing any associated files.

Link to this function

insert(creator, file, file_info, attrs)

View Source
Link to this function

many(filters \\ [], opts \\ [])

View Source
Link to this function

one(filters, opts \\ [])

View Source

Callback implementation for Bonfire.Common.SchemaModule.query_module/0.

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

@spec soft_delete(t()) :: {:ok, t()} | {:error, Ecto.Changeset.t()}

Delete an upload, removing it from indexing, but the files remain available.

Link to this function

update(user \\ nil, media, updates)

View Source
Link to this function

update_by(filters, updates)

View Source