Use custom titles for the activity report.

(imported from commit ed991108715d043d5d21d8e9f7573eaedb21fec1)
This commit is contained in:
Steve Howell 2013-10-11 16:29:26 -04:00
parent 0ad4554723
commit 3ca1ef9a0a
3 changed files with 15 additions and 6 deletions

View File

@ -5,6 +5,11 @@
{# User Activity. #}
{% block title %}
<title>{{ title }}</title>
{% endblock %}
{% block customhead %}
{{ block.super }}
{% minified_js 'activity' %}

View File

@ -7,11 +7,13 @@
<head>
<meta charset="UTF-8">
{% if user_profile.realm.domain %}
<title>{{user_profile.realm.domain}} - Zulip</title>
{% else %}
<title>Zulip</title>
{% endif %}
{% block title %}
{% if user_profile.realm.domain %}
<title>{{user_profile.realm.domain}} - Zulip</title>
{% else %}
<title>Zulip</title>
{% endif %}
{% endblock %}
<!-- HTML5 shim, for IE6-8 support of HTML5 elements -->
<!--[if lt IE 9]>
<script src="https://html5shim.googlecode.com/svn/trunk/html5.js"></script>

View File

@ -2058,6 +2058,7 @@ def get_activity(request, realm=REQ(default=None)):
('Counts', counts_content),
('Durations', duration_content),
]
title = 'Activity'
else:
data = [
('Website', ActivityTable(realm, 'website', web_queries)),
@ -2067,10 +2068,11 @@ def get_activity(request, realm=REQ(default=None)):
('Android', ActivityTable(realm, 'Android', api_queries)),
('iPhone', ActivityTable(realm, 'iPhone', api_queries))
]
title = '%s activity' % (realm,)
return render_to_response(
'zerver/activity.html',
dict(data=data, realm=realm),
dict(data=data, realm=realm, title=title),
context_instance=RequestContext(request)
)