summaryrefslogtreecommitdiff
path: root/lib/aggiedit_web/live
diff options
context:
space:
mode:
Diffstat (limited to 'lib/aggiedit_web/live')
-rw-r--r--lib/aggiedit_web/live/post_live/index.ex1
-rw-r--r--lib/aggiedit_web/live/post_live/show.html.heex5
2 files changed, 5 insertions, 1 deletions
diff --git a/lib/aggiedit_web/live/post_live/index.ex b/lib/aggiedit_web/live/post_live/index.ex
index 6b2be56..59ec234 100644
--- a/lib/aggiedit_web/live/post_live/index.ex
+++ b/lib/aggiedit_web/live/post_live/index.ex
@@ -29,7 +29,6 @@ defmodule AggieditWeb.PostLive.Index do
@impl true
def handle_params(params, _url, socket) do
- IO.puts(inspect(params))
{:noreply, apply_action(socket, socket.assigns.live_action, params)}
end
diff --git a/lib/aggiedit_web/live/post_live/show.html.heex b/lib/aggiedit_web/live/post_live/show.html.heex
index ba71c75..107a3a6 100644
--- a/lib/aggiedit_web/live/post_live/show.html.heex
+++ b/lib/aggiedit_web/live/post_live/show.html.heex
@@ -30,3 +30,8 @@
<span><%= live_patch "Edit", to: Routes.post_show_path(@socket, :edit, @room, @post), class: "button" %></span> |
<span><%= live_redirect "Back", to: Routes.post_index_path(@socket, :index, @room) %></span>
+
+<script>
+ window.userSocket.connect();
+ window.RoomChat.init(window.userSocket, <%= @post.id %>)
+</script>