File tree 2 files changed +3
-3
lines changed
lib/demo_web/live/post_live
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ defmodule DemoWeb.PostLive.FormComponent do
22
22
< . input field = { @ form [ :title ] } type = "text " label = "Title " />
23
23
< . input field = { @ form [ :body ] } type = "text " label = "Body " />
24
24
< . input phx-hook = "Datepicker " field = { @ form [ :date_published ] } type = "text " placeholder = "Select date " label = "Date Published " />
25
-
25
+
26
26
<: actions >
27
27
< . button phx-disable-with = "Saving... " > Save Post</ . button >
28
28
</: actions >
@@ -81,7 +81,6 @@ defmodule DemoWeb.PostLive.FormComponent do
81
81
|> push_patch ( to: socket . assigns . patch ) }
82
82
83
83
{ :error , % Ecto.Changeset { } = changeset } ->
84
- IO . inspect changeset , label: "Changeset"
85
84
{ :noreply , assign_form ( socket , changeset ) }
86
85
end
87
86
end
Original file line number Diff line number Diff line change 14
14
<: item title = "Date published " > <%= @ post . date_published %> </: item >
15
15
</ . list >
16
16
17
- < . back navigate = { ~p" /posts" } > Back to posts</ . back >
17
+ < . back navigate = { ~p" /" } > Back to posts</ . back >
18
+
18
19
19
20
< . modal :if = { @ live_action == :edit } id = "post-modal " show on_cancel = { JS . patch ( ~p" /posts/#{ @ post } " ) } >
20
21
< . live_component
You can’t perform that action at this time.
0 commit comments