diff --git a/lib/pinchflat/media/media_item.ex b/lib/pinchflat/media/media_item.ex index 8eeb97e..ced8e8c 100644 --- a/lib/pinchflat/media/media_item.ex +++ b/lib/pinchflat/media/media_item.ex @@ -40,6 +40,7 @@ defmodule Pinchflat.Media.MediaItem do :thumbnail_filepath, :metadata_filepath, :nfo_filepath, + :last_error, # These are user or system controlled fields :prevent_download, :prevent_culling, @@ -88,6 +89,7 @@ defmodule Pinchflat.Media.MediaItem do # Will very likely revisit because I can't leave well-enough alone. field :subtitle_filepaths, {:array, {:array, :string}}, default: [] + field :last_error, :string field :prevent_download, :boolean, default: false field :prevent_culling, :boolean, default: false field :culled_at, :utc_datetime diff --git a/priv/repo/erd.png b/priv/repo/erd.png index 60d5efd..2acc8aa 100644 Binary files a/priv/repo/erd.png and b/priv/repo/erd.png differ diff --git a/priv/repo/migrations/20250210201413_add_last_error_to_media_item.exs b/priv/repo/migrations/20250210201413_add_last_error_to_media_item.exs new file mode 100644 index 0000000..d8723ba --- /dev/null +++ b/priv/repo/migrations/20250210201413_add_last_error_to_media_item.exs @@ -0,0 +1,9 @@ +defmodule Pinchflat.Repo.Migrations.AddLastErrorToMediaItem do + use Ecto.Migration + + def change do + alter table(:media_items) do + add :last_error, :string + end + end +end