aboutsummaryrefslogtreecommitdiffstats
path: root/account
diff options
context:
space:
mode:
Diffstat (limited to 'account')
-rw-r--r--account/templates/account/login.html4
-rw-r--r--account/templates/account/password_change.html2
-rw-r--r--account/templates/account/password_change_done.html2
-rw-r--r--account/templates/account/profile.html52
4 files changed, 54 insertions, 6 deletions
diff --git a/account/templates/account/login.html b/account/templates/account/login.html
index b41844e..4fee972 100644
--- a/account/templates/account/login.html
+++ b/account/templates/account/login.html
@@ -12,11 +12,11 @@
{% block content %}
<div class="container">
<h2>登录</h2>
- <br />
+ <br>
<form role="form" class="form-horizontal" method="post">
{% csrf_token %}
{% bootstrap_form form layout='horizontal' %}
- {% buttons submit='提交' reset='取消' layout='horizontal' %}{% endbuttons %}
+ {% buttons submit='提交' reset='重置' layout='horizontal' %}{% endbuttons %}
</form>
</div>
{% endblock %}
diff --git a/account/templates/account/password_change.html b/account/templates/account/password_change.html
index 372bb0c..f4e2e90 100644
--- a/account/templates/account/password_change.html
+++ b/account/templates/account/password_change.html
@@ -12,7 +12,7 @@
{% block content %}
<div class="container">
<h2>修改密码</h2>
- <br />
+ <br>
<form role="form" class="form-horizontal" method="post">
{% csrf_token %}
{% bootstrap_form form layout='horizontal' %}
diff --git a/account/templates/account/password_change_done.html b/account/templates/account/password_change_done.html
index e003033..e8770ca 100644
--- a/account/templates/account/password_change_done.html
+++ b/account/templates/account/password_change_done.html
@@ -13,7 +13,7 @@
<div class="container">
<h2>密码修改成功</h2>
<p class="lead">您已成功修改密码。</p>
- <br />
+ <br>
<p><a href="{% url 'profile' %}" class="btn btn-default">返回个人主页</a></p>
</div>
{% endblock %}
diff --git a/account/templates/account/profile.html b/account/templates/account/profile.html
index aac992f..cb08717 100644
--- a/account/templates/account/profile.html
+++ b/account/templates/account/profile.html
@@ -12,9 +12,57 @@
{% block content %}
<div class="container">
<h2>个人主页</h2>
- <p class="lead">TODO ...</p>
+ <br>
- <br />
+ <table class="table table-striped table-bordered table-hover">
+ <tbody>
+ <tr>
+ <th class="profile-name">姓名</th>
+ <td class="profile-name-data">{{ profile.realname }}</td>
+ </tr>
+ <tr>
+ <th class="profile-email">邮箱</th>
+ <td class="profile-email-data">{{ user.email }}</td>
+ </tr>
+ <tr>
+ <th class="profile-institute">单位</th>
+ <td class="profile-institute-data">{{ profile.institute }}</td>
+ </tr>
+ <tr>
+ <th class="profile-approval">是否审定</th>
+ <td class="profile-approval-data">
+ {% if profile.is_approved == 'Y' %}
+ <span class="glyphicon glyphicon-ok"></span> <span class="label label-success">是</span>
+ {% elif profile.is_approved == 'N' %}
+ <span class="glyphicon glyphicon-remove"></span> <span class="label label-warning">否</span>
+ {% elif profile.is_approved == 'C' %}
+ <span class="glyphicon glyphicon-question-sign"></span> <span class="label label-default">审核中</span>
+ {% else %}
+ <span class="glyphicon glyphicon-warning-sign"></span> <span class="label label-danger">错误</span>
+ {% endif %}
+ </td>
+ </tr>
+ <tr>
+ <th class="profile-sponsorship">是否资助</th>
+ <td class="profile-sponsorship-data">
+ {% if profile.is_sponsored == 'Y' %}
+ <span class="glyphicon glyphicon-ok"></span> <span class="label label-success">是</span>
+ {% elif profile.is_sponsored == 'N' %}
+ <span class="glyphicon glyphicon-remove"></span> <span class="label label-warning">否</span>
+ {% elif profile.is_sponsored == 'C' %}
+ <span class="glyphicon glyphicon-question-sign"></span> <span class="label label-default">审核中</span>
+ {% else %}
+ <span class="glyphicon glyphicon-warning-sign"></span> <span class="label label-danger">错误</span>
+ {% endif %}
+ </td>
+ </tr>
+ </table>
+
+ <br>
+ <p>
+ <a href="#" class="btn btn-default">编辑个人信息</a>
+ <a href="{% url 'password_change' %}" class="btn btn-default">修改密码</a>
+ </p>
</div>
{% endblock %}