aboutsummaryrefslogtreecommitdiff
path: root/ui
diff options
context:
space:
mode:
authorAlexander Kavon <hawk@alexkavon.com>2023-11-30 20:10:41 -0500
committerAlexander Kavon <hawk@alexkavon.com>2023-11-30 20:10:50 -0500
commit17af6e1a5017285b680a7d0a1dace1e1a1612ab9 (patch)
treeb33696d408ca10c5b0edd99cad399cc1dd093f52 /ui
parentb3ea95f3d494c10d3f37de7842982138b4ee19a5 (diff)
fixed login/create templates to point to correct endpoints, updated func names to be more idiomatic, reference Session objects to save memory, logout/session.Destroy method
Diffstat (limited to 'ui')
-rw-r--r--ui/pages/user/create.tmpl.html2
-rw-r--r--ui/pages/user/login.tmpl.html4
2 files changed, 3 insertions, 3 deletions
diff --git a/ui/pages/user/create.tmpl.html b/ui/pages/user/create.tmpl.html
index 47143c6..68a9e93 100644
--- a/ui/pages/user/create.tmpl.html
+++ b/ui/pages/user/create.tmpl.html
@@ -2,7 +2,7 @@
{{define "main"}}
<h1>Create User</h1>
- <form action="/user" method="POST">
+ <form action="/u" method="POST">
<label>
Email
<input type="email" placeholder="email" name="email" />
diff --git a/ui/pages/user/login.tmpl.html b/ui/pages/user/login.tmpl.html
index 5c42f97..d56f61a 100644
--- a/ui/pages/user/login.tmpl.html
+++ b/ui/pages/user/login.tmpl.html
@@ -2,7 +2,7 @@
{{define "main"}}
<h1>Login</h1>
- <form hx-post="/user" action="/user/auth" method="POST" hx-target="#messages" hx-swap="outerHTML">
+ <form action="/u/auth" method="POST">
<label>
Username
<input type="text" placeholder="username" name="username" />
@@ -11,6 +11,6 @@
Password
<input type="password" placeholder="password" name="password" />
</label>
- <button type="submit" hx-disabled-elt="this">Login</button>
+ <button type="submit">Login</button>
</form>
{{end}}