Skip to content

Commit 0dea5c9

Browse files
committed
api stats
1 parent 1777dfe commit 0dea5c9

File tree

5 files changed

+172
-55
lines changed

5 files changed

+172
-55
lines changed

cookbook/templates/system.html

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,9 @@ <h4 class="mt-3">{% trans 'Debug Mode' %} <span
8282
{% else %}
8383
{% trans 'Everything is fine!' %}
8484
{% endif %}
85-
85+
8686
<h4 class="mt-3">{% trans 'Allowed Hosts' %} <span
87-
class="badge badge-{% if '*' in allowed_hosts %}warning{% else %}success{% endif %}">{% if '*' in allowed_hosts %}
87+
class="badge badge-{% if '*' in allowed_hosts %}warning{% else %}success{% endif %}">{% if '*' in allowed_hosts %}
8888
{% trans 'Warning' %}{% else %}{% trans 'Ok' %}{% endif %}</span></h4>
8989
{% if debug %}
9090
{% blocktrans %}
@@ -176,6 +176,33 @@ <h4 class="mt-3">{% trans 'Migrations' %}
176176
{#{% endfor %}#}
177177
{# </textarea>#}
178178

179+
<h4 class="mt-3">API Stats</h4>
180+
<h6 >User Stats</h6>
181+
<table class="table table-bordered table-striped">
182+
{% for r in api_user_stats %}
183+
<tr>
184+
{% for c in r %}
185+
<td>
186+
{{ c }}
187+
</td>
188+
{% endfor %}
189+
</tr>
190+
{% endfor %}
191+
</table>
192+
193+
<h6 >Endpoint Stats</h6>
194+
<table class="table table-bordered table-striped">
195+
{% for r in api_stats %}
196+
<tr>
197+
{% for c in r %}
198+
<td>
199+
{{ c }}
200+
</td>
201+
{% endfor %}
202+
</tr>
203+
{% endfor %}
204+
</table>
205+
179206
<h4 class="mt-3">Debug</h4>
180207
<textarea class="form-control" rows="20">
181208
Gunicorn Media: {{ gunicorn_media }}

0 commit comments

Comments
 (0)