Show wishlisted date for wishlisted records
This commit is contained in:
@@ -22,7 +22,9 @@ defmodule MusicLibrary.Records do
|
||||
:release_ids,
|
||||
:included_release_group_ids,
|
||||
:cover_hash,
|
||||
:release_date
|
||||
:release_date,
|
||||
:inserted_at,
|
||||
:updated_at
|
||||
]
|
||||
end
|
||||
|
||||
|
||||
@@ -28,5 +28,7 @@ defmodule MusicLibrary.Records.SearchIndex do
|
||||
field :included_release_group_ids, {:array, :string}, default: []
|
||||
|
||||
embeds_many :artists, Artist
|
||||
|
||||
timestamps(type: :utc_datetime)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -91,6 +91,14 @@ defmodule MusicLibraryWeb.RecordComponents do
|
||||
/>
|
||||
{Records.Record.format_as_date(record.purchased_at)}
|
||||
</span>
|
||||
<span :if={!record.purchased_at}>
|
||||
·
|
||||
<span class="sr-only">
|
||||
{gettext("Wishlisted on")}
|
||||
</span>
|
||||
<.icon name="hero-star" class="-mt-1 h-4 w-4" aria-hidden="true" data-slot="icon" />
|
||||
{Records.Record.format_as_date(record.inserted_at)}
|
||||
</span>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
@@ -106,6 +114,13 @@ defmodule MusicLibraryWeb.RecordComponents do
|
||||
<.icon name="hero-banknotes" class="-mt-1 h-4 w-4" aria-hidden="true" data-slot="icon" />
|
||||
{Records.Record.format_as_date(record.purchased_at)}
|
||||
</p>
|
||||
<p :if={!record.purchased_at} class="text-xs leading-6 text-zinc-900 dark:text-zinc-300">
|
||||
<span class="sr-only">
|
||||
{gettext("Wishlisted on")}
|
||||
</span>
|
||||
<.icon name="hero-star" class="-mt-1 h-4 w-4" aria-hidden="true" data-slot="icon" />
|
||||
{Records.Record.format_as_date(record.inserted_at)}
|
||||
</p>
|
||||
</div>
|
||||
<%!-- TODO: replace with OSS version --%>
|
||||
<.actions_menu id={record.id} background_container_target="#records > li">
|
||||
|
||||
@@ -905,3 +905,8 @@ msgstr ""
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "Last year"
|
||||
msgstr ""
|
||||
|
||||
#: lib/music_library_web/components/record_components.ex
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "Wishlisted on"
|
||||
msgstr ""
|
||||
|
||||
@@ -905,3 +905,8 @@ msgstr ""
|
||||
#, elixir-autogen, elixir-format, fuzzy
|
||||
msgid "Last year"
|
||||
msgstr ""
|
||||
|
||||
#: lib/music_library_web/components/record_components.ex
|
||||
#, elixir-autogen, elixir-format, fuzzy
|
||||
msgid "Wishlisted on"
|
||||
msgstr ""
|
||||
|
||||
Reference in New Issue
Block a user