aboutsummaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2013-05-13 13:26:08 +0100
committerPaul Eggleton <paul.eggleton@linux.intel.com>2013-05-22 17:45:36 +0100
commit4502a3894678addecace8aeea8db543611b5948f (patch)
tree6e17e306de32e9cfc9b92734fa7ea24156d48e0d /templates
parent611ed1decec2d9aa31c6f7f0ff349cb7160a5d83 (diff)
downloadopenembedded-core-contrib-4502a3894678addecace8aeea8db543611b5948f.tar.gz
Add user profile editing form
This form allows the user to change their email address, first and last name. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Diffstat (limited to 'templates')
-rw-r--r--templates/base.html1
-rw-r--r--templates/layerindex/profile.html51
2 files changed, 52 insertions, 0 deletions
diff --git a/templates/base.html b/templates/base.html
index 9d3e9ce4ce..6a8cb84962 100644
--- a/templates/base.html
+++ b/templates/base.html
@@ -72,6 +72,7 @@
<ul class="dropdown-menu">
<li><a href="{% url auth_logout %}">{% trans "Log out" %}</a></li>
<li><a href="{% url auth_password_change %}">{% trans "Change password" %}</a></li>
+ <li><a href="{% url profile %}">{% trans "Edit profile" %}</a></li>
</ul>
</li>
{% else %}
diff --git a/templates/layerindex/profile.html b/templates/layerindex/profile.html
new file mode 100644
index 0000000000..8edc451257
--- /dev/null
+++ b/templates/layerindex/profile.html
@@ -0,0 +1,51 @@
+{% extends "base.html" %}
+{% load i18n %}
+
+{% comment %}
+
+ layerindex-web - profile page template
+
+ Copyright (C) 2013 Intel Corporation
+ Licensed under the MIT license, see COPYING.MIT for details
+
+{% endcomment %}
+
+
+<!--
+{% autoescape on %}
+{% block title_append %} - profile{% endblock %}
+{% endautoescape %}
+-->
+
+{% block content %}
+{% autoescape on %}
+
+<form method="post" action=".">
+ {% for hidden in form.hidden_fields %}
+ {{ hidden }}
+ {% endfor %}
+
+ {% for field in form.visible_fields %}
+ {% if field.errors %}
+ <div class="control-group alert alert-error">
+ {{ field.errors }}
+ {% else %}
+ <div class="control-group">
+ {% endif %}
+ <div class="control-label {% if field.required %}requiredlabel{% endif %}">
+ {{ field.label_tag }}
+ </div>
+ <div class="controls">
+ {{ field }}
+ </div>
+ </div>
+ {% endfor %}
+
+ <input type="submit" class="btn" value="{% trans 'Save' %}" />
+ <a class="btn" href="{% url frontpage %}">{% trans 'Cancel' %}</a>
+ {% csrf_token %}
+</form>
+
+{% endautoescape %}
+
+{% endblock %}