summaryrefslogtreecommitdiffstats
path: root/ogcp/templates/auth
diff options
context:
space:
mode:
authorJavier Sánchez Parra <jsanchez@soleta.eu>2022-04-26 17:16:52 +0200
committerJavier Sánchez Parra <jsanchez@soleta.eu>2022-04-27 17:27:50 +0200
commit661254b76edd51c36090edd0f898bdca16f23277 (patch)
tree7882d0097515358435206a795d4f8b815965f529 /ogcp/templates/auth
parentd8bac16a980634f182e9c753a01e114c3a482af0 (diff)
Add 'Add user' to Users section
Creates "Add user" form with the following inputs: username, password, password confirmation, role (administrator or regular), allowed scopes.
Diffstat (limited to 'ogcp/templates/auth')
-rw-r--r--ogcp/templates/auth/add_user.html26
1 files changed, 26 insertions, 0 deletions
diff --git a/ogcp/templates/auth/add_user.html b/ogcp/templates/auth/add_user.html
new file mode 100644
index 0000000..af44caa
--- /dev/null
+++ b/ogcp/templates/auth/add_user.html
@@ -0,0 +1,26 @@
+{% extends 'users.html' %}
+{% import "bootstrap/wtf.html" as wtf %}
+
+{% set sidebar_state = 'disabled' %}
+{% set btn_back = true %}
+
+{% block nav_user_add %}active{% endblock %}
+{% block content %}
+
+<h1 class="m-5">{{_('Add a user')}}</h1>
+
+{{ wtf.quick_form(form,
+ action=url_for('user_add_post'),
+ method='post',
+ button_map={'submit_btn':'primary'},
+ id='user-form') }}
+
+<script>
+ document.addEventListener('readystatechange', () => {
+ if (document.readyState === 'complete') {
+ digestUserFormPassword()
+ }
+ });
+</script>
+
+{% endblock %}