mirror of https://github.com/zulip/zulip.git
analytics-realm-activity: Add link to realm's stats page.
Adds the pie chart icon stats page link to the realm_activity page header.
This commit is contained in:
parent
c05c25e742
commit
b686e6ce9e
|
@ -13,6 +13,7 @@ from analytics.views.activity_common import (
|
|||
format_date_for_activity_reports,
|
||||
get_user_activity_summary,
|
||||
make_table,
|
||||
realm_stats_link,
|
||||
user_activity_link,
|
||||
)
|
||||
from zerver.decorator import require_server_admin
|
||||
|
@ -252,8 +253,10 @@ def get_realm_activity(request: HttpRequest, realm_str: str) -> HttpResponse:
|
|||
data += [(page_title, content)]
|
||||
|
||||
title = realm_str
|
||||
realm_stats = realm_stats_link(realm_str)
|
||||
|
||||
return render(
|
||||
request,
|
||||
"analytics/activity.html",
|
||||
context=dict(data=data, realm_link=None, title=title),
|
||||
context=dict(data=data, realm_stats_link=realm_stats, title=title),
|
||||
)
|
||||
|
|
|
@ -15,11 +15,8 @@
|
|||
<br />
|
||||
{% endif %}
|
||||
|
||||
<h4>{{ title }}</h4>
|
||||
<h4>{{ title }} {% if realm_stats_link %}{{ realm_stats_link }}{% endif %}</h4>
|
||||
|
||||
{% if realm_link %}
|
||||
<a href="{{ realm_link }}">Graph</a><br />
|
||||
{% endif %}
|
||||
|
||||
<ul class="nav nav-tabs">
|
||||
{% for name, activity in data %}
|
||||
|
|
Loading…
Reference in New Issue