From ea74a89078b875b3a1ee4141ac20c57979614e06 Mon Sep 17 00:00:00 2001 From: Adam Piontek Date: Sat, 13 Aug 2022 09:39:08 -0400 Subject: [PATCH] user management new/edit/delete working, with fixed live modal --- lib/shift73k_web/live/modal_component.ex | 10 +-- .../delete_component.html.heex | 20 ++++++ .../delete_component.html.leex | 16 ----- .../user_management/form_component.html.heex | 66 +++++++++++++++++++ .../user_management/form_component.html.leex | 62 ----------------- 5 files changed, 91 insertions(+), 83 deletions(-) create mode 100644 lib/shift73k_web/live/user_management/delete_component.html.heex delete mode 100644 lib/shift73k_web/live/user_management/delete_component.html.leex create mode 100644 lib/shift73k_web/live/user_management/form_component.html.heex delete mode 100644 lib/shift73k_web/live/user_management/form_component.html.leex diff --git a/lib/shift73k_web/live/modal_component.ex b/lib/shift73k_web/live/modal_component.ex index b3f165e3..d5ac4afe 100644 --- a/lib/shift73k_web/live/modal_component.ex +++ b/lib/shift73k_web/live/modal_component.ex @@ -3,12 +3,12 @@ defmodule Shift73kWeb.ModalComponent do @impl true def render(assigns) do - ~L""" - diff --git a/lib/shift73k_web/live/user_management/delete_component.html.heex b/lib/shift73k_web/live/user_management/delete_component.html.heex new file mode 100644 index 00000000..4c53cb94 --- /dev/null +++ b/lib/shift73k_web/live/user_management/delete_component.html.heex @@ -0,0 +1,20 @@ +
+ + + + +
\ No newline at end of file diff --git a/lib/shift73k_web/live/user_management/delete_component.html.leex b/lib/shift73k_web/live/user_management/delete_component.html.leex deleted file mode 100644 index d7614702..00000000 --- a/lib/shift73k_web/live/user_management/delete_component.html.leex +++ /dev/null @@ -1,16 +0,0 @@ - - diff --git a/lib/shift73k_web/live/user_management/form_component.html.heex b/lib/shift73k_web/live/user_management/form_component.html.heex new file mode 100644 index 00000000..68855ac9 --- /dev/null +++ b/lib/shift73k_web/live/user_management/form_component.html.heex @@ -0,0 +1,66 @@ +
+ + <%= form_for @changeset, "#", [ + phx_target: @myself, + phx_change: "validate", + phx_submit: "save" + ], fn f -> %> + + + + + <% end %> + +
\ No newline at end of file diff --git a/lib/shift73k_web/live/user_management/form_component.html.leex b/lib/shift73k_web/live/user_management/form_component.html.leex deleted file mode 100644 index 15f82296..00000000 --- a/lib/shift73k_web/live/user_management/form_component.html.leex +++ /dev/null @@ -1,62 +0,0 @@ -<%= form_for @changeset, "#", [ - phx_target: @myself, - phx_change: "validate", - phx_submit: "save" - ], fn f -> %> - - - - -<% end %>