Added error information to homepage tables
This commit is contained in:
parent
ecd9d0e96f
commit
9dca081fbc
2 changed files with 25 additions and 13 deletions
|
|
@ -24,7 +24,15 @@
|
|||
</:tab_append>
|
||||
|
||||
<:tab title="Media" id="media">
|
||||
<div class="flex flex-col gap-10 dark:text-white">
|
||||
<div class="flex flex-col gap-10 text-white">
|
||||
<section :if={@media_item.last_error} class="mt-6">
|
||||
<div class="flex items-center gap-1 mb-2">
|
||||
<.icon name="hero-exclamation-circle-solid" class="text-red-500" />
|
||||
<h3 class="font-bold text-xl">Last Error</h3>
|
||||
</div>
|
||||
<span>{@media_item.last_error}</span>
|
||||
</section>
|
||||
|
||||
<%= if media_file_exists?(@media_item) do %>
|
||||
<section class="grid grid-cols-1 xl:gap-6 mt-6">
|
||||
<div>
|
||||
|
|
@ -54,14 +62,6 @@
|
|||
</section>
|
||||
<% end %>
|
||||
|
||||
<section :if={@media_item.last_error} class="mt-6">
|
||||
<div class="flex items-center gap-1 mb-2">
|
||||
<.icon name="hero-exclamation-circle-solid" class="text-red-500" />
|
||||
<h3 class="font-bold text-xl">Last Error</h3>
|
||||
</div>
|
||||
<span>{@media_item.last_error}</span>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h3 class="font-bold text-xl mb-2">Raw Attributes</h3>
|
||||
<section>
|
||||
|
|
|
|||
|
|
@ -28,10 +28,22 @@ defmodule Pinchflat.Pages.HistoryTableLive do
|
|||
</span>
|
||||
<div class="max-w-full overflow-x-auto">
|
||||
<.table rows={@records} table_class="text-white">
|
||||
<:col :let={media_item} label="Title" class="truncate max-w-xs">
|
||||
<.subtle_link href={~p"/sources/#{media_item.source_id}/media/#{media_item}"}>
|
||||
{media_item.title}
|
||||
</.subtle_link>
|
||||
<:col :let={media_item} label="Title" class="max-w-xs">
|
||||
<section class="flex items-center space-x-1">
|
||||
<.tooltip
|
||||
:if={media_item.last_error}
|
||||
tooltip={media_item.last_error}
|
||||
position="bottom-right"
|
||||
tooltip_class="w-64"
|
||||
>
|
||||
<.icon name="hero-exclamation-circle-solid" class="text-red-500" />
|
||||
</.tooltip>
|
||||
<span class="truncate">
|
||||
<.subtle_link href={~p"/sources/#{media_item.source_id}/media/#{media_item.id}"}>
|
||||
{media_item.title}
|
||||
</.subtle_link>
|
||||
</span>
|
||||
</section>
|
||||
</:col>
|
||||
<:col :let={media_item} label="Upload Date">
|
||||
{DateTime.to_date(media_item.uploaded_at)}
|
||||
|
|
|
|||
Loading…
Reference in a new issue