diff --git a/lib/karaokium/events.ex b/lib/karaokium/events.ex index 2c45eef..9673378 100644 --- a/lib/karaokium/events.ex +++ b/lib/karaokium/events.ex @@ -164,7 +164,7 @@ defmodule Karaokium.Events do karaoke |> Karaoke.reset_pin_changeset() |> Repo.update() - |> broadcast(:update) + |> broadcast(:updated) end @doc """ diff --git a/lib/karaokium_web/live/admin/performance_live/show.ex b/lib/karaokium_web/live/admin/performance_live/show.ex index 9be1ab0..f108fac 100644 --- a/lib/karaokium_web/live/admin/performance_live/show.ex +++ b/lib/karaokium_web/live/admin/performance_live/show.ex @@ -17,7 +17,7 @@ defmodule KaraokiumWeb.Admin.PerformanceLive.Show do |> assign(:page_title, page_title(socket.assigns.live_action)) |> assign(:karaoke_id, karaoke_id) |> assign(:id, id) - |> assign(:performancelive, Events.get_karaoke!(karaoke_id).performing_id) + |> assign(:karaoke_performance_id, Events.get_karaoke!(karaoke_id).performing_id) |> reload()} end diff --git a/lib/karaokium_web/live/admin/performance_live/show.html.heex b/lib/karaokium_web/live/admin/performance_live/show.html.heex index 9f806cc..63c2776 100644 --- a/lib/karaokium_web/live/admin/performance_live/show.html.heex +++ b/lib/karaokium_web/live/admin/performance_live/show.html.heex @@ -45,8 +45,7 @@
- <%= if @performance.id == @performancelive do %> - <% else %> + <%= unless @performance.id == @karaoke_performance_id do %> <%= live_patch("Edit", to: Routes.admin_performance_edit_path(@socket, :edit, @karaoke_id, @performance.id), diff --git a/lib/karaokium_web/templates/layout/_header.html.heex b/lib/karaokium_web/templates/layout/_header.html.heex index c4c48f2..e9e7e60 100644 --- a/lib/karaokium_web/templates/layout/_header.html.heex +++ b/lib/karaokium_web/templates/layout/_header.html.heex @@ -1,27 +1,91 @@
<%= render("_user_menu.html", assigns) %> + + diff --git a/lib/karaokium_web/templates/layout/app.html.heex b/lib/karaokium_web/templates/layout/app.html.heex index 4371f2f..4147053 100644 --- a/lib/karaokium_web/templates/layout/app.html.heex +++ b/lib/karaokium_web/templates/layout/app.html.heex @@ -1,4 +1,4 @@ -
+
<%= if get_flash(@conn, :info) do %> <% end %> diff --git a/lib/karaokium_web/templates/layout/live.html.heex b/lib/karaokium_web/templates/layout/live.html.heex index a4f1f04..bd4cddd 100644 --- a/lib/karaokium_web/templates/layout/live.html.heex +++ b/lib/karaokium_web/templates/layout/live.html.heex @@ -1,4 +1,4 @@ -
+
<%= if live_flash(@flash, :info) do %>