PhoenixKitWeb.Live.Users.MediaStorage (phoenix_kit v2.62.2)

Copy Markdown View Source

How one media file is stored: /admin/media/:file_uuid/storage.

The picture, its title and its comments live in the media view (/admin/media?file=<uuid>); this page is for the backend of the same file: the checksum of its original, every rendition the file's variant set wants and which of them are there, the buckets holding each object, and the actions that put it right (verify the copies against their checksums, make the missing renditions again, restore or drop the unedited original).

The report is PhoenixKit.Modules.Storage.FileReport. Reading and checking copies can take a while (a cloud bucket, a video), so verifying and repairing run as async tasks and the page shows their progress.

Gated by media.manage, like the other storage administration screens. A holder who is not allowed to see the file (someone else's file in a library they are not in, or without media.view_all) gets "not found".

Summary

Functions

"39 frames, 1.8 s" for an animated file; nil for a still picture.

Callback implementation for Phoenix.LiveView.render/1.

Functions

animation_label(_)

"39 frames, 1.8 s" for an animated file; nil for a still picture.

handle_async(arg1, arg, socket)

Callback implementation for Phoenix.LiveView.handle_async/3.

handle_event(event, params, socket)

Callback implementation for Phoenix.LiveView.handle_event/3.

handle_info(arg1, socket)

Callback implementation for Phoenix.LiveView.handle_info/2.

mount(params, session, socket)

Callback implementation for Phoenix.LiveView.mount/3.

render(assigns)

Callback implementation for Phoenix.LiveView.render/1.