aboutsummaryrefslogtreecommitdiffstats
path: root/mediagoblin/templates
diff options
context:
space:
mode:
authorElrond <elrond+mediagoblin.org@samba-tng.org>2013-05-21 18:34:23 +0200
committerElrond <elrond+mediagoblin.org@samba-tng.org>2013-05-21 18:34:23 +0200
commitd5e035e9193cb9c9faff0e8601e2908bf5285f9c (patch)
tree7cdc675b8b8e504f5f0087dd5b275fa596685406 /mediagoblin/templates
parent6c1467d570a4da68ef8b4edac9aecdb9c87a61de (diff)
parent2ba7603469a80ccfc1c07ddebc53ad6c6f0a6f79 (diff)
downloadmediagoblin-d5e035e9193cb9c9faff0e8601e2908bf5285f9c.tar.lz
mediagoblin-d5e035e9193cb9c9faff0e8601e2908bf5285f9c.tar.xz
mediagoblin-d5e035e9193cb9c9faff0e8601e2908bf5285f9c.zip
Merge remote-tracking branch 'rodney757/change_pass'
* rodney757/change_pass: fixed translation, and changed tabs to spaces, and change it so the user can view their password as they're typing. modified change_pass tests moved change pass to a seperate view and fixed issues 709
Diffstat (limited to 'mediagoblin/templates')
-rw-r--r--mediagoblin/templates/mediagoblin/edit/change_pass.html52
-rw-r--r--mediagoblin/templates/mediagoblin/edit/edit_account.html9
2 files changed, 58 insertions, 3 deletions
diff --git a/mediagoblin/templates/mediagoblin/edit/change_pass.html b/mediagoblin/templates/mediagoblin/edit/change_pass.html
new file mode 100644
index 00000000..ff909b07
--- /dev/null
+++ b/mediagoblin/templates/mediagoblin/edit/change_pass.html
@@ -0,0 +1,52 @@
+{#
+# GNU MediaGoblin -- federated, autonomous media hosting
+# Copyright (C) 2011, 2012 MediaGoblin contributors. See AUTHORS.
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Affero General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Affero General Public License for more details.
+#
+# You should have received a copy of the GNU Affero General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+#}
+{% extends "mediagoblin/base.html" %}
+
+{% import "/mediagoblin/utils/wtforms.html" as wtforms_util %}
+
+{% block mediagoblin_head %}
+ <script type="text/javascript"
+ src="{{ request.staticdirect('/js/show_password.js') }}"></script>
+{% endblock mediagoblin_head %}
+
+{% block title -%}
+ {% trans username=user.username -%}
+ Changing {{ username }}'s password
+ {%- endtrans %} &mdash; {{ super() }}
+{%- endblock %}
+
+{% block mediagoblin_content %}
+ <form action="{{ request.urlgen('mediagoblin.edit.pass') }}"
+ method="POST" enctype="multipart/form-data">
+ <div class="form_box edit_box">
+ <h1>
+ {%- trans username=user.username -%}
+ Changing {{ username }}'s password
+ {%- endtrans -%}
+ </h1>
+ {{ wtforms_util.render_divs(form) }}
+ {{ csrf_token }}
+ <div class="form_submit_buttons">
+ <input type="submit" value="{% trans %}Save{% endtrans %}"
+ class="button_form" />
+ </div>
+ </div>
+ </form>
+{% endblock %}
+
+
diff --git a/mediagoblin/templates/mediagoblin/edit/edit_account.html b/mediagoblin/templates/mediagoblin/edit/edit_account.html
index 7fe2c031..4c4aaf95 100644
--- a/mediagoblin/templates/mediagoblin/edit/edit_account.html
+++ b/mediagoblin/templates/mediagoblin/edit/edit_account.html
@@ -41,8 +41,11 @@
Changing {{ username }}'s account settings
{%- endtrans -%}
</h1>
- {{ wtforms_util.render_field_div(form.old_password) }}
- {{ wtforms_util.render_field_div(form.new_password) }}
+ <p>
+ <a href="{{ request.urlgen('mediagoblin.edit.pass') }}">
+ {% trans %}Change your password.{% endtrans %}
+ </a>
+ </p>
<div class="form_field_input">
<p>{{ form.wants_comment_notification }}
{{ wtforms_util.render_label(form.wants_comment_notification) }}</p>
@@ -50,7 +53,7 @@
{{- wtforms_util.render_field_div(form.license_preference) }}
<div class="form_submit_buttons">
<input type="submit" value="{% trans %}Save changes{% endtrans %}" class="button_form" />
- {{ csrf_token }}
+ {{ csrf_token }}
</div>
</div>
</form>