aboutsummaryrefslogtreecommitdiff
path: root/app/templates
diff options
context:
space:
mode:
Diffstat (limited to 'app/templates')
-rw-r--r--app/templates/users/set_password.html28
-rw-r--r--app/templates/users/user_profile_page.html12
2 files changed, 40 insertions, 0 deletions
diff --git a/app/templates/users/set_password.html b/app/templates/users/set_password.html
new file mode 100644
index 0000000..6fc12ba
--- /dev/null
+++ b/app/templates/users/set_password.html
@@ -0,0 +1,28 @@
+{% extends "base.html" %}
+
+{% block title %}
+ Set Password
+{% endblock %}
+
+{% block content %}
+<h1>Set Password</h1>
+
+{% from "macros/forms.html" import render_field, render_submit_field %}
+<form action="" method="POST" class="form" role="form">
+ <div class="row">
+ <div class="col-sm-6 col-md-5 col-lg-4">
+ {{ form.hidden_tag() }}
+
+ {% if not current_user.email %}
+ {{ render_field(form.email, tabindex=230) }}
+ {% endif %}
+
+ {{ render_field(form.password, tabindex=230) }}
+ {{ render_field(form.password2, tabindex=240) }}
+
+ {{ render_submit_field(form.submit, tabindex=280) }}
+ </div>
+ </div>
+</form>
+
+{% endblock %}
diff --git a/app/templates/users/user_profile_page.html b/app/templates/users/user_profile_page.html
index 062e9e8..c1cdb00 100644
--- a/app/templates/users/user_profile_page.html
+++ b/app/templates/users/user_profile_page.html
@@ -42,6 +42,18 @@
{% endif %}
</td>
</tr>
+ {% if user == current_user %}
+ <tr>
+ <td>Password:</td>
+ <td>
+ {% if user.password %}
+ Set | <a href="{{ url_for('user.change_password') }}">Change</a>
+ {% else %}
+ Not set | <a href="{{ url_for('set_password_page') }}">Set</a>
+ {% endif %}
+ </td>
+ </tr>
+ {% endif %}
</table>
</div>